mirror of
https://github.com/ddidderr/wuffs.git
synced 2026-11-25 16:55:11 +01:00
Generate inline headers for use declarations
This commit is contained in:
1 parent
c5b5efd7c8
commit
9867cd5e3a
6 files changed
+549
-16
No files matched your search
+3
-1
@@ -27,6 +27,8 @@ import (
|
||||
|
||||
"github.com/google/wuffs/lang/generate"
|
||||
|
||||
cf "github.com/google/wuffs/cmd/commonflags"
|
||||
|
||||
a "github.com/google/wuffs/lang/ast"
|
||||
t "github.com/google/wuffs/lang/token"
|
||||
)
|
||||
@@ -89,7 +91,7 @@ func (h *genHelper) gen(dirname string, recursive bool) error {
|
||||
}
|
||||
h.seen[dirname] = struct{}{}
|
||||
|
||||
if dirname != path.Clean(dirname) || dirname == "" || dirname[0] == '.' || dirname[0] == '/' {
|
||||
if !cf.IsValidUsePath(dirname) {
|
||||
return fmt.Errorf("invalid package path %q", dirname)
|
||||
}
|
||||
|
||||
|
||||
Reference in new issue
Block a user