Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'main' into general_refs/docs
- Loading branch information
Showing
69 changed files
with
2,229 additions
and
652 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,33 @@ | ||
package json | ||
|
||
// Options defines the options for JSON operations, | ||
// currently only marshaling can be configured | ||
type Options struct { | ||
MarshalOptions MarshalOptions | ||
} | ||
|
||
// MarshalOptions defines the options for JSON marshaling, | ||
// currently only toggling the marshaling of location information is supported | ||
type MarshalOptions struct { | ||
// IncludeLocation toggles the marshaling of location information | ||
IncludeLocation NodeToggle | ||
// IncludeLocationText additionally/optionally includes the text of the location | ||
IncludeLocationText bool | ||
} | ||
|
||
// NodeToggle is a generic struct to allow the toggling of | ||
// settings for different ast node types | ||
type NodeToggle struct { | ||
Term bool | ||
Package bool | ||
Comment bool | ||
Import bool | ||
Rule bool | ||
Head bool | ||
Expr bool | ||
SomeDecl bool | ||
Every bool | ||
With bool | ||
Annotations bool | ||
AnnotationsRef bool | ||
} |
Oops, something went wrong.