mirror of
https://github.com/golang/go
synced 2024-11-26 19:41:19 -07:00
fix a couple of inconsequential glitches in regexp code.
R=rsc DELTA=2 (0 added, 1 deleted, 1 changed) OCL=17589 CL=17595
This commit is contained in:
parent
beee6915f8
commit
f0e93e8cc5
@ -14,7 +14,6 @@ import (
|
||||
export var debug = false;
|
||||
|
||||
|
||||
export var ErrUnimplemented = os.NewError("unimplemented");
|
||||
export var ErrInternal = os.NewError("internal error");
|
||||
export var ErrUnmatchedLpar = os.NewError("unmatched '('");
|
||||
export var ErrUnmatchedRpar = os.NewError("unmatched ')'");
|
||||
@ -397,7 +396,7 @@ func (p *Parser) Term() (start, end Inst) {
|
||||
switch c := p.c(); c {
|
||||
case '|', EOF:
|
||||
return NULL, NULL;
|
||||
case '*', '+', '|':
|
||||
case '*', '+':
|
||||
p.re.Error(ErrBareClosure);
|
||||
case ')':
|
||||
if p.nlpar == 0 {
|
||||
|
Loading…
Reference in New Issue
Block a user