Created
May 24, 2022 21:19
-
-
Save hmarcelodn/5f1c94493a7ce2bd440a2c29b563bd7a to your computer and use it in GitHub Desktop.
thl-grammar.pegjs-10
This file contains hidden or 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
| AndCondition = head:ConditionStatement tail:(_ '&&' _ ConditionStatement)+ { | |
| const accum = [{...head}]; | |
| tail.reduce((accumulated, element) => { | |
| accumulated.push(element[3]); | |
| return accumulated; | |
| }, accum); | |
| return { op: '&&', predicates: accum }; | |
| } / ConditionStatement |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment