MCPcopy Create free account
hub / github.com/google/go-jsonnet / WithCode

Method WithCode

ast/location.go:113–115  ·  view source on GitHub ↗

WithCode returns true iff the LocationRange is linked to code. TODO: This is identical to lr.IsSet(). Is it required at all?

()

Source from the content-addressed store, hash-verified

111// WithCode returns true iff the LocationRange is linked to code.
112// TODO: This is identical to lr.IsSet(). Is it required at all?
113func (lr *LocationRange) WithCode() bool {
114 return lr.Begin.Line != 0
115}
116
117// MakeLocationRangeMessage creates a pseudo-LocationRange with a message but no
118// location information. This is useful for special locations, e.g.

Callers 1

showCodeMethod · 0.80

Calls

no outgoing calls

Tested by

no test coverage detected