aboutsummaryrefslogtreecommitdiffstats
path: root/awkgram.y
diff options
context:
space:
mode:
Diffstat (limited to 'awkgram.y')
-rw-r--r--awkgram.y4
1 files changed, 2 insertions, 2 deletions
diff --git a/awkgram.y b/awkgram.y
index fad2b963..31751e8e 100644
--- a/awkgram.y
+++ b/awkgram.y
@@ -3049,8 +3049,8 @@ yylex(void)
pushback();
break;
case ']':
- if (tok[-1] == '['
- || (tok[-2] == '[' && tok[-1] == '^'))
+ if ((tok[-1] == '[' && tok[-2] != '\\')
+ || (tok[-2] == '[' && tok[-3] != '\\' && tok[-1] == '^'))
/* do nothing */;
else
in_brack--;