-
Notifications
You must be signed in to change notification settings - Fork 3.6k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
wip: adjustments for integrating handlebars rules
- hash-parameters - subexpressions wip: adjustments for integrating handlebars rules - hash-parameters - subexpressions wip: update tests some minor adaptions wip: fix test cases wip: try to honor path expressions correctly wip: fix tests and refactor language definition wip: update keywords, remove debug output wip: {{else}} is a keyword and not a helper call wip: fix test for else-variants - else is not a built-in (except for the keyword {{else}}) wip: fix hashes and number literals, add string literals - the hash-value must start after the equals-sign - number and string modes must be in front of identifiers, because they are a subset wip: make "as" in block-parameters a "keyword"
- Loading branch information
Showing
44 changed files
with
595 additions
and
262 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
17 changes: 9 additions & 8 deletions
17
test/markup/handlebars/block-expression-variants-as-path-segment.expect.txt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,9 +1,10 @@ | ||
<span class="xml">text </span><span class="hljs-template-tag">{{#<span class="hljs-name">abc</span> abcd.[lite"'ral}}segment] }}</span><span class="xml">a</span><span class="hljs-template-tag">{{/<span class="hljs-name">abc</span>}}</span><span class="xml"> | ||
|
||
text </span><span class="hljs-template-tag">{{#<span class="hljs-name">abc</span> abcd."lite]'ral}}segment" }}</span><span class="xml">a</span><span class="hljs-template-tag">{{/<span class="hljs-name">abc</span>}}</span><span class="xml"> | ||
|
||
text </span><span class="hljs-template-tag">{{#<span class="hljs-name">abc</span> abcd.'lite]"ral}}segment' }}</span><span class="xml">a</span><span class="hljs-template-tag">{{/<span class="hljs-name">abc</span>}}</span><span class="xml"> | ||
|
||
text | ||
|
||
<span class="xml">Block expression variants with literal segments in paths: | ||
... | ||
</span><span class="hljs-template-tag">{{#<span class="hljs-name">abc</span> abcd.[lite"'ral}}segment] }}</span><span class="xml">a</span><span class="hljs-template-tag">{{/<span class="hljs-name">abc</span>}}</span><span class="xml"> | ||
... | ||
</span><span class="hljs-template-tag">{{#<span class="hljs-name">abc</span> abcd."lite]'ral}}segment" }}</span><span class="xml">a</span><span class="hljs-template-tag">{{/<span class="hljs-name">abc</span>}}</span><span class="xml"> | ||
... | ||
</span><span class="hljs-template-tag">{{#<span class="hljs-name">abc</span> abcd.'lite]"ral}}segment' }}</span><span class="xml">a</span><span class="hljs-template-tag">{{/<span class="hljs-name">abc</span>}}</span><span class="xml"> | ||
... | ||
Done | ||
</span> |
17 changes: 9 additions & 8 deletions
17
test/markup/handlebars/block-expression-variants-as-path-segment.txt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,8 +1,9 @@ | ||
text {{#abc abcd.[lite"'ral}}segment] }}a{{/abc}} | ||
|
||
text {{#abc abcd."lite]'ral}}segment" }}a{{/abc}} | ||
|
||
text {{#abc abcd.'lite]"ral}}segment' }}a{{/abc}} | ||
|
||
text | ||
|
||
Block expression variants with literal segments in paths: | ||
... | ||
{{#abc abcd.[lite"'ral}}segment] }}a{{/abc}} | ||
... | ||
{{#abc abcd."lite]'ral}}segment" }}a{{/abc}} | ||
... | ||
{{#abc abcd.'lite]"ral}}segment' }}a{{/abc}} | ||
... | ||
Done |
26 changes: 14 additions & 12 deletions
26
test/markup/handlebars/block-expression-variants-in-helper-name.expect.txt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,14 +1,16 @@ | ||
<span class="xml">text </span><span class="hljs-template-tag">{{#<span class="hljs-name">[ab}}c]</span> param }}</span><span class="xml">a</span><span class="hljs-template-tag">{{/<span class="hljs-name">[ab}}c]</span>}}</span><span class="xml"> | ||
<span class="xml">Block expression variants with literal segments in helper name: | ||
|
||
text </span><span class="hljs-template-tag">{{#<span class="hljs-name">'ab}}c'</span> param}}</span><span class="xml">a</span><span class="hljs-template-tag">{{/<span class="hljs-name">'ab}}c'</span>}}</span><span class="xml"> | ||
|
||
text </span><span class="hljs-template-tag">{{#<span class="hljs-name">"ab}}c"</span> param}}</span><span class="xml">a</span><span class="hljs-template-tag">{{/<span class="hljs-name">"ab}}c"</span>}}</span><span class="xml"> | ||
|
||
text </span><span class="hljs-template-tag">{{#<span class="hljs-name">""</span> param}}</span><span class="xml">a</span><span class="hljs-template-tag">{{/<span class="hljs-name">""</span>}}</span><span class="xml"> | ||
|
||
text </span><span class="hljs-template-tag">{{#<span class="hljs-name">''</span> param}}</span><span class="xml">a</span><span class="hljs-template-tag">{{/<span class="hljs-name">''</span>}}</span><span class="xml"> | ||
|
||
text </span><span class="hljs-template-tag">{{#<span class="hljs-name">[]</span> param}}</span><span class="xml">a</span><span class="hljs-template-tag">{{/<span class="hljs-name">[]</span>}}</span><span class="xml"> | ||
|
||
text | ||
</span><span class="hljs-template-tag">{{#<span class="hljs-name">[ab}}c]</span> param }}</span><span class="xml">a</span><span class="hljs-template-tag">{{/<span class="hljs-name">[ab}}c]</span>}}</span><span class="xml"> | ||
... | ||
</span><span class="hljs-template-tag">{{#<span class="hljs-name">'ab}}c'</span> param}}</span><span class="xml">a</span><span class="hljs-template-tag">{{/<span class="hljs-name">'ab}}c'</span>}}</span><span class="xml"> | ||
... | ||
</span><span class="hljs-template-tag">{{#<span class="hljs-name">"ab}}c"</span> param}}</span><span class="xml">a</span><span class="hljs-template-tag">{{/<span class="hljs-name">"ab}}c"</span>}}</span><span class="xml"> | ||
... | ||
</span><span class="hljs-template-tag">{{#<span class="hljs-name">""</span> param}}</span><span class="xml">a</span><span class="hljs-template-tag">{{/<span class="hljs-name">""</span>}}</span><span class="xml"> | ||
... | ||
</span><span class="hljs-template-tag">{{#<span class="hljs-name">''</span> param}}</span><span class="xml">a</span><span class="hljs-template-tag">{{/<span class="hljs-name">''</span>}}</span><span class="xml"> | ||
... | ||
</span><span class="hljs-template-tag">{{#<span class="hljs-name">[]</span> param}}</span><span class="xml">a</span><span class="hljs-template-tag">{{/<span class="hljs-name">[]</span>}}</span><span class="xml"> | ||
... | ||
Done | ||
</span> |
28 changes: 15 additions & 13 deletions
28
test/markup/handlebars/block-expression-variants-in-helper-name.txt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,13 +1,15 @@ | ||
text {{#[ab}}c] param }}a{{/[ab}}c]}} | ||
|
||
text {{#'ab}}c' param}}a{{/'ab}}c'}} | ||
|
||
text {{#"ab}}c" param}}a{{/"ab}}c"}} | ||
|
||
text {{#"" param}}a{{/""}} | ||
|
||
text {{#'' param}}a{{/''}} | ||
|
||
text {{#[] param}}a{{/[]}} | ||
|
||
text | ||
Block expression variants with literal segments in helper name: | ||
|
||
{{#[ab}}c] param }}a{{/[ab}}c]}} | ||
... | ||
{{#'ab}}c' param}}a{{/'ab}}c'}} | ||
... | ||
{{#"ab}}c" param}}a{{/"ab}}c"}} | ||
... | ||
{{#"" param}}a{{/""}} | ||
... | ||
{{#'' param}}a{{/''}} | ||
... | ||
{{#[] param}}a{{/[]}} | ||
... | ||
Done |
10 changes: 4 additions & 6 deletions
10
test/markup/handlebars/block-expression-variants-in-param.expect.txt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,8 +1,6 @@ | ||
<span class="xml">text </span><span class="hljs-template-tag">{{#<span class="hljs-name">abc</span> "lite]'ral}}segment" }}</span><span class="xml">a</span><span class="hljs-template-tag">{{/<span class="hljs-name">abc</span>}}</span><span class="xml"> | ||
<span class="xml">Block expression variants with literal segments in helper param: | ||
|
||
text </span><span class="hljs-template-tag">{{#<span class="hljs-name">abc</span> 'lite]"ral}}segment' }}</span><span class="xml">a</span><span class="hljs-template-tag">{{/<span class="hljs-name">abc</span>}}</span><span class="xml"> | ||
|
||
text </span><span class="hljs-template-tag">{{#<span class="hljs-name">abc</span> [lite"'ral}}segment] }}</span><span class="xml">a</span><span class="hljs-template-tag">{{/<span class="hljs-name">abc</span>}}</span><span class="xml"> | ||
|
||
text | ||
</span><span class="hljs-template-tag">{{#<span class="hljs-name">abc</span> [lite"'ral}}segment] }}</span><span class="xml">a</span><span class="hljs-template-tag">{{/<span class="hljs-name">abc</span>}}</span><span class="xml"> | ||
... | ||
Done | ||
</span> |
Oops, something went wrong.