aboutsummaryrefslogtreecommitdiff
path: root/nomsu.peg
AgeCommit message (Collapse)Author
2018-07-15Major changes to how versioning and parsing work. This should be aBruce Hill
better path going forward to handling upgrades. Old syntax files will stick around for compatibility purposes. Old syntax can be parsed into valid syntax trees via the old syntax (.peg) files, and then old syntax trees should be valid and can be upgraded via the normal code path. This change has lots of improvements to Nomsu codegen too.
2018-07-14Fixed up some edge cases with parsing and comments.Bruce Hill
2018-07-14Fixed up comment generation to old standardsBruce Hill
2018-07-13Switching to use 'unpack' for indentation grouping.Bruce Hill
2018-07-12All tests passing.Bruce Hill
2018-07-12Initial version of new pegfile. works (ish)Bruce Hill
2018-07-11Fixed nomsu codegen for indented text and improved text parsing. AlsoBruce Hill
moved some more tests inline.
2018-07-10Fixed up line numbers for generated code.Bruce Hill
2018-07-09Adding some compatibility stuff.Bruce Hill
2018-06-28Improvements to nomsu codegen (comments are now retained) and someBruce Hill
improvements to handling of stdin and fixes for error reporting.
2018-06-23Added versioning system.Bruce Hill
2018-06-18Initial working version.Bruce Hill
2018-06-12Lots of optimizations and simplifications, especially towards gettingBruce Hill
better performance on luajit.
2018-06-12Removed dependency on 'immutable' library. This lets LuaJIT do moreBruce Hill
aggressive optimizations and generally helps performance. Some safety is lost, but I think the performance gains, reduced complexity, and reduced dependencies are worth it.
2018-06-12Tidying up exceptions and error reporting. Also simplified the grammar aBruce Hill
tiny bit.
2018-05-30Deleted shebang rule. Comments handle it just fine.Bruce Hill
2018-05-30Better parse error reporting.Bruce Hill
2018-05-30Cleaned up patterns a little.Bruce Hill
2018-05-28Fix for luajit, though I'm not sure why it worked for lua either.Bruce Hill
2018-05-27Trivially added support for `foo(1,2)` as sugar for `foo 1 2`Bruce Hill
2018-05-27Some tweaks/cleanup on the nomsu code as well as adding variableBruce Hill
mangling to 'parse % as %' to make almost hygienic macros.
2018-05-26Cleaned up lpeg matching stuff to use lpeg.Carg(1) instead ofBruce Hill
lpeg.userdata, and switched indent/dedent/nodent to use a number to track indentation instead of a stack.
2018-05-26Moving back to capturing tables in LPEG and everything is a Source, notBruce Hill
string.
2018-05-26Minor tidying.Bruce Hill
2018-05-24Removed the Word tree type and replaced it with raw strings, sinceBruce Hill
they're only used as part of Actions
2018-05-24Misc changes, fixed up Object lib and tests.Bruce Hill
2018-05-16Initial working version.Bruce Hill
2018-05-16Converted DictEntry to be an actual tree, instead of a pseudo-tree, made ↵Bruce Hill
'parse % as %' generate lua code with already-substituted tree literals instead of reparsing and substituting at parse time, and made some general optimizations.
2018-05-15Adding support for coroutines, and cleaning up comment syntax.Bruce Hill
2018-05-10Cleanup: removed "File" type trees (now just Block), overhauledBruce Hill
how_do_i.nom, added "result of %" macro, which allowed comprehensions to be way more concisely defined. Moved len() operator into the nomsu environment.
2018-05-03Better error reporting and codegen.Bruce Hill
2018-04-28Re-added (..), which is necessary for long expressions as first arg toBruce Hill
an action.
2018-04-27Better text interpolation/handling of "\". Also added syntax support forBruce Hill
(statement; statement)
2018-04-25Overhauling parsing of Blocks (can no longer contain only one statement)Bruce Hill
2018-04-25Removing end-of-line ":" and "(..)" for blocks (they just useBruce Hill
indentation now).
2018-04-25Updated block-style text interpolation to have less redundancy.Bruce Hill
2018-04-24Refactor to improve indentation and move as_nomsu() into tree methods.Bruce Hill
2018-04-17Disabled comment transpilation for now.Bruce Hill
2018-04-17Moving tree_to_lua into each of the Nomsu tree types, which are now inBruce Hill
their own file.
2018-04-11Work in progress...Bruce Hill
2018-04-08Cleaned up LHS of "." operator to avoid adding unnecessary parens soBruce Hill
Lua's parser doesn't get confused by (x).y = 1.
2018-04-06Initial working version.Bruce Hill
2018-02-13Initial branch of switching to using immutable types.Bruce Hill
2018-01-30Added back in support for ":" indented blocksBruce Hill
2018-01-30Removed indented interpolations for inline strings.Bruce Hill
2018-01-30Overhaul of indentations. Now strictly requiring exactly 4 spacesBruce Hill
everywhere, and supporting indented string interpolations.
2018-01-26Removed "\.." syntax, and just added support for the literal ".." asBruce Hill
long as it's not followed by an indented region.
2018-01-23Removed dead code.Bruce Hill
2018-01-19Refactored syntax a bit so that ":" isn't necessary for a block, and canBruce Hill
be used for inline expressions instead. Also, dict literals now use ":" instead of "=".
2018-01-15Added support for translating comments instead of dropping them.Bruce Hill