this repo has no description
0
fork

Configure Feed

Select the types of activity you want to include in your feed.

cue/load: deduplicate underscore import of ./pkg

Spotted in passing. Harmless, but also unnecessary.
Move it to doc.go near the package documentation, which is the closest
to a top-level file we have for this package.

While here, remove an unnecessary newline in pkg/register.go.

Signed-off-by: Daniel Martí <mvdan@mvdan.cc>
Change-Id: I59bca21889158b231600bd1326752abb8fed0262
Reviewed-on: https://review.gerrithub.io/c/cue-lang/cue/+/1201389
TryBot-Result: CUEcueckoo <cueckoo@cuelang.org>
Reviewed-by: Roger Peppe <rogpeppe@gmail.com>
Unity-Result: CUE porcuepine <cue.porcuepine@gmail.com>

+6 -13
+6
cue/load/doc.go
··· 14 14 15 15 // Package load loads CUE instances. 16 16 package load 17 + 18 + // Trigger the unconditional loading of all core builtin packages if load is used. 19 + // This was deemed the simplest way to avoid having to import this line explicitly, 20 + // and thus breaking existing code, for the majority of cases, 21 + // while not introducing an import cycle. 22 + import _ "cuelang.org/go/pkg"
-6
cue/load/instances.go
··· 30 30 "cuelang.org/go/internal/mod/modpkgload" 31 31 "cuelang.org/go/internal/mod/modrequirements" 32 32 "cuelang.org/go/mod/module" 33 - 34 - // Trigger the unconditional loading of all core builtin packages if load 35 - // is used. This was deemed the simplest way to avoid having to import 36 - // this line explicitly, and thus breaking existing code, for the majority 37 - // of cases, while not introducing an import cycle. 38 - _ "cuelang.org/go/pkg" 39 33 ) 40 34 41 35 // Instances returns the instances named by the command line arguments 'args'.
-6
cue/load/loader.go
··· 26 26 "cuelang.org/go/cue/errors" 27 27 "cuelang.org/go/cue/token" 28 28 "cuelang.org/go/internal/mod/modpkgload" 29 - 30 - // Trigger the unconditional loading of all core builtin packages if load 31 - // is used. This was deemed the simplest way to avoid having to import 32 - // this line explicitly, and thus breaking existing code, for the majority 33 - // of cases, while not introducing an import cycle. 34 - _ "cuelang.org/go/pkg" 35 29 ) 36 30 37 31 type loader struct {
-1
pkg/register.go
··· 27 27 _ "cuelang.org/go/pkg/encoding/json" 28 28 _ "cuelang.org/go/pkg/encoding/yaml" 29 29 _ "cuelang.org/go/pkg/html" 30 - 31 30 _ "cuelang.org/go/pkg/list" 32 31 _ "cuelang.org/go/pkg/math" 33 32 _ "cuelang.org/go/pkg/math/bits"