summary refs log tree commit diff
diff options
context:
space:
mode:
authorHerbert Xu <herbert@gondor.apana.org.au>2007-09-24 21:59:39 +0800
committerHerbert Xu <herbert@gondor.apana.org.au>2007-09-24 22:01:26 +0800
commitcfc3d6a1b401c16f6bb65460ad675154fe622a14 (patch)
treecef2d0b43e911cb91d81bd95cb47bbdb22ec0cdc
parent[PARSER] Remove superfluous arinest test in CENDQUOTE (diff)
downloaddash-cfc3d6a1b401c16f6bb65460ad675154fe622a14.tar.gz
dash-cfc3d6a1b401c16f6bb65460ad675154fe622a14.zip
[PARSER] Remove superfluous arinest test for dqvarnest
dqvarnest is only used to determine whether CENDQUOTE should terminate the
double-quote syntax.  Since CENDQUOTE can never occur while arinest is set,
we don't need to take arinest into account for dqvarnest.
Diffstat (limited to '')
-rw-r--r--ChangeLog1
-rw-r--r--src/parser.c3
2 files changed, 2 insertions, 2 deletions
diff --git a/ChangeLog b/ChangeLog
index 0a35741..b311ad4 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -3,6 +3,7 @@
 	* Do not quote back slashes in parameter expansions outside quotes.
 	* Perform tilde expansion in all parameter expansion words.
 	* Remove superfluous arinest test in CENDQUOTE.
+	* Remove superfluous arinest test for dqvarnest.
 
 2007-09-22  Oleg Verych <olecom@flower.upol.cz>
 
diff --git a/src/parser.c b/src/parser.c
index 26c9046..8fac57a 100644
--- a/src/parser.c
+++ b/src/parser.c
@@ -1232,9 +1232,8 @@ badsub:			synerror("Bad substitution");
 		*((char *)stackblock() + typeloc) = subtype | flags;
 		if (subtype != VSNORMAL) {
 			varnest++;
-			if (dblquote || arinest) {
+			if (dblquote)
 				dqvarnest++;
-			}
 		}
 	}
 	goto parsesub_return;