@@ -742,17 +742,17 @@ func outsideSupportedRange(version string) bool {
742742// or the empty string if we should not attempt to install a version of Go.
743743func getVersionWhenGoModVersionNotFound (v versionInfo ) (msg , version string ) {
744744 if ! v .goEnvVersionFound {
745- // We definitely need to install a version . We have no indication which version was
746- // intended to be used to build this project. Go versions are generally backwards
745+ // There is no Go version installed in the environment . We have no indication which version
746+ // was intended to be used to build this project. Go versions are generally backwards
747747 // compatible, so we install the maximum supported version.
748748 msg = "No version of Go installed and no `go.mod` file found. Writing an environment " +
749749 "file specifying the maximum supported version of Go (" + maxGoVersion + ")."
750750 version = maxGoVersion
751751 diagnostics .EmitNoGoModAndNoGoEnv (msg )
752752 } else if outsideSupportedRange (v .goEnvVersion ) {
753- // We definitely need to install a version . We have no indication which version was
754- // intended to be used to build this project. Go versions are generally backwards
755- // compatible, so we install the maximum supported version.
753+ // The Go version installed in the environment is not supported . We have no indication
754+ // which version was intended to be used to build this project. Go versions are generally
755+ // backwards compatible, so we install the maximum supported version.
756756 msg = "No `go.mod` file found. The version of Go installed in the environment (" +
757757 v .goEnvVersion + ") is outside of the supported range (" + minGoVersion + "-" +
758758 maxGoVersion + "). Writing an environment file specifying the maximum supported " +
@@ -774,7 +774,7 @@ func getVersionWhenGoModVersionNotFound(v versionInfo) (msg, version string) {
774774}
775775
776776// Assuming `v.goModVersion` is above the supported range, emit a diagnostic and return the
777- // version to install, or the empty string if we should not attempt to install a version of Go.
777+ // empty string to indicate that we should not attempt to install a version of Go.
778778func getVersionWhenGoModVersionTooHigh (v versionInfo ) (msg , version string ) {
779779 // The project is intended to be built with a version of Go that is above the supported
780780 // range. We do not install a version of Go.
@@ -787,7 +787,7 @@ func getVersionWhenGoModVersionTooHigh(v versionInfo) (msg, version string) {
787787 return msg , version
788788}
789789
790- // Assuming `v.goModVersion` is above the supported range, emit a diagnostic and return the
790+ // Assuming `v.goModVersion` is below the supported range, emit a diagnostic and return the
791791// version to install, or the empty string if we should not attempt to install a version of Go.
792792func getVersionWhenGoModVersionTooLow (v versionInfo ) (msg , version string ) {
793793 if ! v .goEnvVersionFound {
0 commit comments