This is a clean up task outside of the scope of workspaces, but which would be nice to do:
Before workspaces, when the go command was in module mode, but not in any particular module, it had a fake Target module with the path command-line-arguments and an empty modroot. This was directly translated in workspace mode to a MainModules set with a single entry with that fake module path and empty modroot.
Instead, we should make MainModules.Len() == 0 mean that we're in module mode but not inside any module.