Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(486)

Issue 11155024: If-then-else support for GRIT (Closed)

Created:
8 years, 2 months ago by benrg
Modified:
8 years, 2 months ago
Reviewers:
Jói
CC:
grit-developer_googlegroups.com
Visibility:
Public.

Description

If-then-else support for GRIT This adds a new syntax, <if><then>...</then><else>...</else></if>, with the semantics you'd expect. The <if>...</if> syntax is still supported. BUG=145118 TEST=new unit test Committed: https://code.google.com/p/grit-i18n/source/detail?r=80

Patch Set 1 #

Total comments: 1

Patch Set 2 : rebase #

Patch Set 3 : comments #

Unified diffs Side-by-side diffs Delta from patch set Stats (+78 lines, -12 lines) Patch
M grit/node/empty.py View 1 chunk +6 lines, -6 lines 0 comments Download
M grit/node/mapping.py View 1 chunk +2 lines, -0 lines 0 comments Download
M grit/node/misc.py View 1 2 1 chunk +30 lines, -3 lines 0 comments Download
M grit/node/misc_unittest.py View 2 chunks +40 lines, -2 lines 0 comments Download
M grit/test_suite_all.py View 1 1 chunk +0 lines, -1 line 0 comments Download

Messages

Total messages: 2 (0 generated)
benrg
8 years, 2 months ago (2012-10-16 00:12:19 UTC) #1
Jói
8 years, 2 months ago (2012-10-16 11:21:11 UTC) #2
LGTM, awesome.

https://codereview.chromium.org/11155024/diff/1/grit/node/misc.py
File grit/node/misc.py (right):

https://codereview.chromium.org/11155024/diff/1/grit/node/misc.py#newcode103
grit/node/misc.py:103: if len(self.children) == 2 and
isinstance(self.children[0], ThenNode):
This is slightly hard to follow; I think a comment explaining that it's to
support <then> and <else> when present, or an implicit <then> when not present,
would help readability.

Powered by Google App Engine
This is Rietveld 408576698