Skip to content

Commit d83af90

Browse files
committed
Revert "go/types: enforce Check path restrictions via panics"
This reverts commit b744a11. Reason for revert: Broke trybots. (misc-vetall builder is busted) Change-Id: I651d1c18db2fb3cb6ec12c2ae62024627baf8d77 Reviewed-on: https://go-review.googlesource.com/38332 Reviewed-by: Brad Fitzpatrick <[email protected]>
1 parent da8e939 commit d83af90

1 file changed

Lines changed: 0 additions & 3 deletions

File tree

src/go/types/api.go

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -347,9 +347,6 @@ func (init *Initializer) String() string {
347347
// file set, and the package path the package is identified with.
348348
// The clean path must not be empty or dot (".").
349349
func (conf *Config) Check(path string, fset *token.FileSet, files []*ast.File, info *Info) (*Package, error) {
350-
if path == "" || path == "." {
351-
panic(`path must not be "" or "."`)
352-
}
353350
pkg := NewPackage(path, "")
354351
return pkg, NewChecker(conf, fset, pkg, info).Files(files)
355352
}

0 commit comments

Comments
 (0)