Commit becf6222 authored by Robert Griesemer's avatar Robert Griesemer

allow &^= in assignments

R=r
DELTA=2  (0 added, 0 deleted, 2 changed)
OCL=29889
CL=29889
parent f30fcf32
...@@ -155,7 +155,7 @@ func (p *parser) collectComment() int { ...@@ -155,7 +155,7 @@ func (p *parser) collectComment() int {
// as there may be more whitespace lines after the comment.) // as there may be more whitespace lines after the comment.)
endline := p.pos.Line; endline := p.pos.Line;
if p.lit[1] == '*' { if p.lit[1] == '*' {
for i, b := range p.lit { for _, b := range p.lit {
if b == '\n' { if b == '\n' {
endline++; endline++;
} }
...@@ -1240,7 +1240,7 @@ func (p *parser) parseSimpleStmt(label_ok bool) ast.Stmt { ...@@ -1240,7 +1240,7 @@ func (p *parser) parseSimpleStmt(label_ok bool) ast.Stmt {
token.DEFINE, token.ASSIGN, token.ADD_ASSIGN, token.DEFINE, token.ASSIGN, token.ADD_ASSIGN,
token.SUB_ASSIGN, token.MUL_ASSIGN, token.QUO_ASSIGN, token.SUB_ASSIGN, token.MUL_ASSIGN, token.QUO_ASSIGN,
token.REM_ASSIGN, token.AND_ASSIGN, token.OR_ASSIGN, token.REM_ASSIGN, token.AND_ASSIGN, token.OR_ASSIGN,
token.XOR_ASSIGN, token.SHL_ASSIGN, token.SHR_ASSIGN: token.XOR_ASSIGN, token.SHL_ASSIGN, token.SHR_ASSIGN, token.AND_NOT_ASSIGN:
// assignment statement // assignment statement
pos, tok := p.pos, p.tok; pos, tok := p.pos, p.tok;
p.next(); p.next();
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment