merge token package into scanner package
This commit is contained in:
@@ -8,10 +8,9 @@ import (
|
||||
"github.com/z7zmey/php-parser/node"
|
||||
"github.com/z7zmey/php-parser/position"
|
||||
"github.com/z7zmey/php-parser/scanner"
|
||||
"github.com/z7zmey/php-parser/token"
|
||||
)
|
||||
|
||||
func (lval *yySymType) Token(t token.Token) {
|
||||
func (lval *yySymType) Token(t scanner.Token) {
|
||||
lval.token = t
|
||||
}
|
||||
|
||||
@@ -19,7 +18,7 @@ func (lval *yySymType) Token(t token.Token) {
|
||||
type Parser struct {
|
||||
*scanner.Lexer
|
||||
path string
|
||||
lastToken *token.Token
|
||||
lastToken *scanner.Token
|
||||
positionBuilder *position.Builder
|
||||
errors []*errors.Error
|
||||
rootNode node.Node
|
||||
|
||||
@@ -16,14 +16,14 @@ import (
|
||||
"github.com/z7zmey/php-parser/node/name"
|
||||
"github.com/z7zmey/php-parser/node/scalar"
|
||||
"github.com/z7zmey/php-parser/node/stmt"
|
||||
"github.com/z7zmey/php-parser/token"
|
||||
"github.com/z7zmey/php-parser/scanner"
|
||||
)
|
||||
|
||||
//line php5/php5.y:21
|
||||
type yySymType struct {
|
||||
yys int
|
||||
node node.Node
|
||||
token token.Token
|
||||
token scanner.Token
|
||||
boolWithToken boolWithToken
|
||||
list []node.Node
|
||||
foreachVariable foreachVariable
|
||||
@@ -345,7 +345,6 @@ const yyErrCode = 2
|
||||
const yyInitialStackSize = 16
|
||||
|
||||
//line php5/php5.y:3825
|
||||
|
||||
type foreachVariable struct {
|
||||
node node.Node
|
||||
byRef bool
|
||||
@@ -353,12 +352,12 @@ type foreachVariable struct {
|
||||
|
||||
type nodesWithEndToken struct {
|
||||
nodes []node.Node
|
||||
endToken token.Token
|
||||
endToken scanner.Token
|
||||
}
|
||||
|
||||
type boolWithToken struct {
|
||||
value bool
|
||||
token *token.Token
|
||||
token *scanner.Token
|
||||
}
|
||||
|
||||
type simpleIndirectReference struct {
|
||||
|
||||
@@ -5,7 +5,7 @@ import (
|
||||
"strings"
|
||||
"strconv"
|
||||
|
||||
"github.com/z7zmey/php-parser/token"
|
||||
"github.com/z7zmey/php-parser/scanner"
|
||||
"github.com/z7zmey/php-parser/node"
|
||||
"github.com/z7zmey/php-parser/node/scalar"
|
||||
"github.com/z7zmey/php-parser/node/name"
|
||||
@@ -20,7 +20,7 @@ import (
|
||||
|
||||
%union{
|
||||
node node.Node
|
||||
token token.Token
|
||||
token scanner.Token
|
||||
boolWithToken boolWithToken
|
||||
list []node.Node
|
||||
foreachVariable foreachVariable
|
||||
@@ -3831,12 +3831,12 @@ type foreachVariable struct {
|
||||
|
||||
type nodesWithEndToken struct {
|
||||
nodes []node.Node
|
||||
endToken token.Token
|
||||
endToken scanner.Token
|
||||
}
|
||||
|
||||
type boolWithToken struct {
|
||||
value bool
|
||||
token *token.Token
|
||||
token *scanner.Token
|
||||
}
|
||||
|
||||
type simpleIndirectReference struct {
|
||||
|
||||
Reference in New Issue
Block a user