MCPcopy Create free account
hub / github.com/cogentcore/core / IsGo

Method IsGo

shell/token.go:101–109  ·  view source on GitHub ↗

IsGo returns true if the given token is a Go Keyword or Comment

()

Source from the content-addressed store, hash-verified

99
100// IsGo returns true if the given token is a Go Keyword or Comment
101func (tk *Token) IsGo() bool {
102 if tk.Tok >= token.BREAK && tk.Tok <= token.VAR {
103 return true
104 }
105 if tk.Tok == token.COMMENT {
106 return true
107 }
108 return false
109}
110
111// IsValidExecIdent returns true if the given token is a valid component
112// of an Exec mode identifier

Callers 4

IsWordMethod · 0.95
IsValidExecIdentMethod · 0.95
TranspileLineTokensMethod · 0.80
CodeMethod · 0.80

Calls

no outgoing calls

Tested by

no test coverage detected