Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Browse files
Browse the repository at this point in the history
redo syntax in a dry style
- Loading branch information
1 parent
af2cd33
commit 008bfa6
Showing
1 changed file
with
39 additions
and
0 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,39 @@ | ||
%TestML 0.1.0 | ||
|
||
Plan = 7 | ||
|
||
compare(*testml) | ||
|
||
a b, c | ||
|
||
compare = -> | ||
list = testml.SplitByBlankLines | ||
ast = list.shift.compile.yaml | ||
list.each (testml)-> | ||
$Label = '$BlockLabel - ' | ||
+ testml.FirstLine.Chomp | ||
ast == testml.compile.yaml | ||
|
||
=== Optional semi-colons | ||
--- testml | ||
Plan = 123; | ||
*a == *b; | ||
|
||
Plan = 123; *a == *b; | ||
|
||
Plan = 123; *a == *b | ||
|
||
Plan = 123 | ||
*a == *b | ||
|
||
=== Empty Function | ||
--- testml | ||
a = -> | ||
|
||
a = {} | ||
|
||
a = ()-> | ||
|
||
a = () -> | ||
|
||
a = () {} |