Commit Graph

97 Commits

Author SHA1 Message Date
mappu fd59ff9bb4 node: better handling for unquoting heredoc fragments 2020-04-16 18:38:05 +12:00
mappu fe654d70cc node: fix whitespace in generated comments 2020-04-16 18:37:27 +12:00
mappu ae04fa73ef hoist: new hoisting context inside closures and loops; don't hoist loop vars 2020-04-16 18:37:16 +12:00
mappu a9dfd3d6b9 hoist: add experimental support for postincrement too 2020-04-16 18:36:59 +12:00
mappu fc0008a208 gotype: support function types 2020-04-16 18:36:34 +12:00
mappu 3f8377d9fe add hoisting pass for preincrement rvalue expressions 2020-04-15 19:55:31 +12:00
mappu abc031683e cleanup dead imports 2020-04-15 19:14:45 +12:00
mappu 02cbd3997a doc: support transformations on AltFor/Foreach/Switch/While 2020-04-15 19:14:06 +12:00
mappu 4d333fc297 doc: update status in README 2020-04-15 19:09:20 +12:00
mappu e95a5a1162 node: prototype of regularising the parse emission context 2020-04-15 19:09:20 +12:00
mappu 979049ae42 node: implement float literals 2020-04-15 19:09:20 +12:00
mappu 9253058a73 node: add bailout cases for eval() and extract() 2020-04-15 19:09:05 +12:00
mappu 2fdd3a919c move miniwalker to parseutil package 2020-04-15 19:05:55 +12:00
mappu 739db2c444 move MutatingWalker to new subpackage, exhaustively implement all cases 2020-04-12 14:42:01 +12:00
mappu 78bd54ad13 node: implement switch, break, continue (basic) 2020-04-12 14:41:33 +12:00
mappu cbcfb46de7 node: fix node.Identifier appearing outside of resolveName() calls 2020-04-12 14:41:08 +12:00
mappu 8af07570cd node: implement UnaryPlus/UnaryMinus 2020-04-12 14:40:57 +12:00
mappu 3c76a68843 node: convert comments to /* */ format, to fix non-statement contexts 2020-04-12 14:40:46 +12:00
mappu df0061041f node: implement heredocs + string interpolation 2020-04-12 14:40:19 +12:00
mappu 5ba0185bcb node: use multiline quoting logic consistently in all places 2020-04-12 14:39:38 +12:00
mappu 4ed8bfd72d doc: update README status 2020-04-11 13:34:31 +12:00
mappu f6362c4ebf node: implement sprintf, trim, rtrim, ltrim, strtolower, strtoupper, file_put_contents, str_replace 2020-04-11 13:11:39 +12:00
mappu 1188a769ce node: fix panic in explode/implode parameter reordering 2020-04-11 13:11:07 +12:00
mappu b2ef112f50 node: implement shorthand assignment operators, callable rvalues 2020-04-11 12:51:09 +12:00
mappu 86266ae676 gotype: initial commit of Go type abstraction 2020-04-11 12:49:08 +12:00
mappu 71a4efbbda node: elide some more parens in assignment expressions 2020-04-11 12:47:37 +12:00
mappu 5105293ce6 node: basic support for *expr.Closure 2020-04-11 12:46:28 +12:00
mappu 6b8d4d879a node: handle trailing commas in array literals 2020-04-11 12:45:26 +12:00
mappu 48f3014429 node: add more diagnostics for mixed array/map literals 2020-04-11 12:45:05 +12:00
mappu d3d3d34116 node: emit static ::class as class name string literal 2020-04-11 12:44:37 +12:00
mappu 3fba39b562 doc: update current README status 2020-04-10 20:10:09 +12:00
mappu 7461bfe187 node: convert use of strlen/cound/sizeof/explode/implode 2020-04-10 20:08:40 +12:00
mappu 92abcfe5b9 node: implement *expr.Ternary (a hoisting pass would be better) 2020-04-10 20:08:15 +12:00
mappu ce3cd1065d node: implement *expr.BooleanNot 2020-04-10 20:07:57 +12:00
mappu 199654f552 node: make sure transferred comments do not comment out legitimate source lines(!) 2020-04-10 20:07:45 +12:00
mappu 475ddeb13c create an exhaustive switch interface for node.Node 2020-04-10 18:23:42 +12:00
mappu df2fc21324 implement walkMutate(*node); completely transform AltIf->If 2020-04-10 17:37:59 +12:00
mappu 6d9aa8b022 add normalisation pass (WIP) 2020-04-10 17:20:54 +12:00
mappu 94fe16f681 miniwalker: add interface assertion (noop) 2020-04-10 16:30:03 +12:00
mappu 8986937340 node/error: handle the case where no position is available for inner node 2020-04-10 16:20:38 +12:00
mappu 75b13e0842 test: add if/else fixture including AltIf 2020-04-10 11:23:47 +12:00
mappu f1b7f301cc stmt/if: collapse `else if` from else(if( into elseif( 2020-04-10 11:23:37 +12:00
mappu 72b8da5e4a stmt/if: fix generated else on newline causing parse error 2020-04-10 11:23:08 +12:00
mappu e82a4bb1c4 doc: update README status 2020-04-09 19:55:03 +12:00
mappu f86631880b doc: update README status 2020-04-09 19:40:36 +12:00
mappu 91e39e7e2f node: elide some extra parentheses for commutative binary ops (plus/concat) 2020-04-09 19:40:18 +12:00
mappu 314d65a459 node: support magic __FILE__, __LINE__ etc constants 2020-04-09 19:39:23 +12:00
mappu 0dfabadcf2 node: remove outdated FIXME comment 2020-04-09 19:39:06 +12:00
mappu e3295e1368 test: add fixture for global scalars 2020-04-08 20:34:00 +12:00
mappu 4f86ec11e7 node: transform null->nil; normalise case for true/false 2020-04-08 20:33:53 +12:00