Commit Graph

201 Commits

Author SHA1 Message Date
Bruce Hill
340714635a Updated gitignore to use .compiled.nom 2017-12-14 16:55:22 -08:00
Bruce Hill
28f5c31299 Switched compiler to do lua> instead of lua files. 2017-12-14 16:41:22 -08:00
Bruce Hill
49adc12952 Minor fix. 2017-12-14 14:26:24 -08:00
Bruce Hill
ce398c255a Rebuild. 2017-12-14 14:08:07 -08:00
Bruce Hill
4ee1a13e52 Changed flags from -f to force nonoptimized to -O to use optimized. 2017-12-14 14:07:03 -08:00
Bruce Hill
1111210047 Updating some more stuff. 2017-12-14 13:57:53 -08:00
Bruce Hill
10659d2f37 Updated how do I. 2017-12-14 13:54:31 -08:00
Bruce Hill
536a3ba649 Got it working. 2017-12-13 16:29:15 -08:00
Bruce Hill
0c1c406ce0 More updates with more functional macros and source code storage. 2017-12-11 17:53:23 -08:00
Bruce Hill
0f0dcaac37 Recompiled. 2017-12-09 16:00:09 -08:00
Bruce Hill
ab9af11ec3 Even cleaner support for __src__ 2017-12-09 15:51:28 -08:00
Bruce Hill
96441251c4 Pretty much everything is working?? 2017-12-09 15:34:52 -08:00
Bruce Hill
28b6bc1883 Simplified parser by removing prev_edge. 2017-12-08 15:39:05 -08:00
Bruce Hill
8da2b1d64c Added unicode support and cleaned up the parser a bit. 2017-12-08 15:37:36 -08:00
Bruce Hill
5903820699 Incremental progress towards working. 2017-12-04 17:54:52 -08:00
Bruce Hill
b3b8c4d731 Some stuff changed to allow escaped args and some other ports from the
two_defs branch.
2017-12-04 17:35:47 -08:00
Bruce Hill
8c0816995a Added empty string check. 2017-11-01 20:11:44 -07:00
Bruce Hill
3ae1f696aa Fixed remove rule rule. 2017-11-01 20:00:52 -07:00
Bruce Hill
87b2cce8e5 Added remove rule rule. 2017-11-01 19:59:44 -07:00
Bruce Hill
fb3936269f Removed broken code. 2017-11-01 16:49:52 -07:00
Bruce Hill
f1a2c936de Fixed some codegen stuff, optimized "say" for the common case of string
literals.
2017-11-01 16:49:11 -07:00
Bruce Hill
cbd876673a Added gsub. 2017-11-01 15:58:19 -07:00
Bruce Hill
8c7915e466 Added try/except. 2017-11-01 15:52:28 -07:00
Bruce Hill
b0072e6dcf Added local var persistence for REPL. 2017-10-31 18:35:40 -07:00
Bruce Hill
6ba79a8ff1 Added support for serializing rules. 2017-10-31 16:19:08 -07:00
Bruce Hill
c1ec00d5fc Changed it so variables can't contain wordbreakers anymore. 2017-10-30 14:08:23 -07:00
Bruce Hill
60a85bbd8b Removed some unnecessary semicolons on keywords. 2017-10-23 16:28:45 -07:00
Bruce Hill
2197da3028 Updated comments. 2017-10-23 14:55:12 -07:00
Bruce Hill
28a6446c66 Added tree_to_nomsu() and improved codegen by compiling \foo to
nomsu:parse("foo") and removing some newlines.
2017-10-22 18:40:49 -07:00
Bruce Hill
3d81837261 Made it so nomsu only runs REPL with -i 2017-10-20 15:17:57 -07:00
Bruce Hill
c6819cf1e9 More callstack fixin 2017-10-20 15:10:04 -07:00
Bruce Hill
b909dce5d1 Fix for callstack. 2017-10-20 15:07:57 -07:00
Bruce Hill
9f61e7f90d Misc. cleanups. 2017-10-19 18:56:42 -07:00
Bruce Hill
09cb00e106 Recompile. 2017-10-19 18:16:48 -07:00
Bruce Hill
ca5896b7bd Finally fixed the bullshit way that string literals were converted to lua. 2017-10-19 18:16:15 -07:00
Bruce Hill
c7994cf720 Added some constants to utils. 2017-10-19 17:28:41 -07:00
Bruce Hill
e42f14dbd1 Recompile. 2017-10-19 17:01:08 -07:00
Bruce Hill
b98059261c Abbreviated "lua code" to "lua>" and "lua expr" to "=lua" and "lua
block" to "lua do>"
2017-10-19 17:00:10 -07:00
Bruce Hill
443f8c73bb Added default dict. 2017-10-19 16:34:38 -07:00
Bruce Hill
e43f60a124 Rebuilt. 2017-10-13 19:44:32 -07:00
Bruce Hill
9dee9dbbd8 Made symbols group with each other, instead of *every* one being alone. 2017-10-13 19:43:55 -07:00
Bruce Hill
bccfe9d8e1 Changed tokenizing to treat symbols as their own things. 2017-10-13 19:41:58 -07:00
Bruce Hill
56f014a488 Improved code generation by changing vars["x"] to vars.x for allowed lua
var names.
2017-10-13 18:14:18 -07:00
Bruce Hill
e82a8286b6 Removed io.write() stuff. 2017-10-13 18:14:03 -07:00
Bruce Hill
a176c7dfb5 Rebuilt. 2017-10-13 18:09:46 -07:00
Bruce Hill
e476bfea52 Improved code generation for "when" statements using elseif, and
improved code generation for loops by omitting goto labels when not used.
2017-10-13 18:09:04 -07:00
Bruce Hill
d13bcde2b9 Renamed repr_if_not_string to "stringify" and added nomsu:stringify for
convenience.
2017-10-13 16:16:07 -07:00
Bruce Hill
7435b61380 Changed generated code to be less verbose for function and macro defs
(using "foo %" syntax instead of {type="FunctionCall", ...} literals).
2017-10-13 16:10:47 -07:00
Bruce Hill
1083273b9f Added -f option to force rebuilds (for when the compiler changes, not
the lib files).
2017-10-13 16:10:23 -07:00
Bruce Hill
1822df2b1a Added *much* better filename and line number error reporting. 2017-10-13 15:42:10 -07:00