[augeas-devel] augeas: master - * src/fa.c (re_needs_parens_in_concat): ITER doesn't need parens in concat
David Lutterkort
lutter at fedoraproject.org
Fri Oct 23 17:15:18 UTC 2009
Gitweb: http://git.fedorahosted.org/git/augeas.git?p=augeas.git;a=commitdiff;h=e96c70cd760b6021ce5206af0b317ddb730a86e5
Commit: e96c70cd760b6021ce5206af0b317ddb730a86e5
Parent: 6330577ea6a301a6c94a2f056e1a2bbcc4f3f4ea
Author: David Lutterkort <lutter at redhat.com>
AuthorDate: Fri Oct 23 14:34:31 2009 +0200
Committer: David Lutterkort <lutter at redhat.com>
CommitterDate: Fri Oct 23 19:04:43 2009 +0200
* src/fa.c (re_needs_parens_in_concat): ITER doesn't need parens in concat
---
src/fa.c | 5 +----
1 files changed, 1 insertions(+), 4 deletions(-)
diff --git a/src/fa.c b/src/fa.c
index 92f915a..a913071 100644
--- a/src/fa.c
+++ b/src/fa.c
@@ -3323,10 +3323,7 @@ static int re_union_as_string(const struct re *re, struct re_str *str) {
ATTRIBUTE_PURE
static int re_needs_parens_in_concat(const struct re *re) {
- if (re->type == ITER)
- re = re->exp;
-
- return (re->type != CHAR && re->type != CSET);
+ return (re->type != CHAR && re->type != CSET && re->type != ITER);
}
static int re_concat_as_string(const struct re *re, struct re_str *str) {
More information about the augeas-devel
mailing list