summaryrefslogtreecommitdiff
path: root/parse.y
diff options
context:
space:
mode:
Diffstat (limited to 'parse.y')
-rw-r--r--parse.y12
1 files changed, 6 insertions, 6 deletions
diff --git a/parse.y b/parse.y
index 14e38347cf..2ca171f332 100644
--- a/parse.y
+++ b/parse.y
@@ -3850,12 +3850,12 @@ yylex()
return c;
case '{':
- if (!IS_ARG()) {
- if (space_seen && lex_state == EXPR_ENDARG)
- c = tLBRACE_ARG;
- if (lex_state != EXPR_END && lex_state != EXPR_ENDARG)
- c = tLBRACE;
- }
+ if (IS_ARG() || lex_state == EXPR_END)
+ c = '{'; /* block (primary) */
+ else if (lex_state == EXPR_ENDARG)
+ c = tLBRACE_ARG; /* block (expr) */
+ else
+ c = tLBRACE; /* hash */
COND_PUSH(0);
CMDARG_PUSH(0);
lex_state = EXPR_BEG;