php-parser/scanner/token.go

20 lines
287 B
Go
Raw Normal View History

package scanner
2017-12-03 20:49:18 +02:00
2018-01-05 17:03:59 +02:00
import (
"github.com/z7zmey/php-parser/meta"
2018-01-05 17:03:59 +02:00
)
2018-01-11 20:49:00 +02:00
// Token value returned by lexer
2017-12-03 20:49:18 +02:00
type Token struct {
2018-06-24 10:19:44 +03:00
Value string
Meta meta.Collection
2018-06-24 10:19:44 +03:00
StartLine int
EndLine int
StartPos int
EndPos int
2017-12-03 20:49:18 +02:00
}
func (t *Token) String() string {
2017-12-03 20:49:18 +02:00
return string(t.Value)
}