Commit Graph

391 Commits

Author SHA1 Message Date
Stephen Chung
637f47d259 Split AST::set_source into set_source/clear_source. 2021-01-09 15:20:07 +08:00
Stephen Chung
0f1f6c4ad3 Add Engine::compile_to_self_contained. 2021-01-09 00:24:55 +08:00
Stephen Chung
96b1e7777b Update URL links. 2021-01-07 17:30:06 +08:00
Stephen Chung
e2a47b2a65 Disallow duplicated function definitions. 2021-01-03 20:54:08 +08:00
Stephen Chung
ba7f8c6391 Propagate source info. 2020-12-30 21:12:51 +08:00
Stephen Chung
13f5cec291 Fix call stack limits. 2020-12-29 12:29:45 +08:00
Stephen Chung
eca8212f38 More code refinements. 2020-12-29 10:41:20 +08:00
Stephen Chung
5c813ca7c0 Code cleanup. 2020-12-28 09:49:54 +08:00
Stephen Chung
6b8d78d64c Streamline parsing. 2020-12-27 16:50:48 +08:00
Stephen Chung
48af8719e7 Fix closure property access. 2020-12-27 11:50:24 +08:00
Stephen Chung
66d3af256e Enhance custom operators. 2020-12-26 23:21:09 +08:00
Stephen Chung
dc4e52e795 Code enhancements. 2020-12-26 13:05:57 +08:00
Stephen Chung
f55a56c6bc Engine::register_global_module and Engine::register_static_module must be passed shared Module. 2020-12-23 10:08:43 +08:00
Stephen Chung
15fb03218c Rename packages to global modules. 2020-12-22 23:45:14 +08:00
Stephen Chung
2e7ec8f1db IdentX -> Ident. 2020-12-22 16:45:56 +08:00
Stephen Chung
ff67efc6d5 Add source to contexts. 2020-12-21 23:12:45 +08:00
Stephen Chung
5ac83f0f46 Add context source to on_debug. 2020-12-21 22:04:46 +08:00
Stephen Chung
2955a4ab64 Fix unary operators binding. 2020-12-21 17:39:37 +08:00
Stephen Chung
f99703f951 Add Engine::disable_doc_comments and smarter doc-comments treatment. 2020-12-20 20:05:23 +08:00
Stephen Chung
719f0babbf Fix comments parsing. 2020-12-18 16:07:19 +08:00
Stephen Chung
fc54fdc907 Emphasize custom syntax are expressions. 2020-12-17 10:42:20 +08:00
Stephen Chung
95b8dcc623 Update docs. 2020-12-16 14:57:28 +08:00
Stephen Chung
f8c14ba1c4 Add look-ahead to custom syntax parser. 2020-12-15 19:23:30 +08:00
Stephen Chung
17310ef576 Encapsulate structures. 2020-12-14 23:05:13 +08:00
Stephen Chung
ecc08271d9 Include actual tokens in custom syntax node. 2020-12-13 14:31:24 +08:00
Stephen Chung
dbdb8f43b7 Change AST to struct. 2020-12-12 15:57:55 +08:00
Stephen Chung
40b6a014ae Provide Position to debug. 2020-12-12 11:47:18 +08:00
Stephen Chung
4438c358d5 on_progress takes u64. 2020-12-12 10:10:27 +08:00
Stephen Chung
bed29da71a Use ImmutableString. 2020-12-11 12:57:07 +08:00
Stephen Chung
f22a04fc74 Move constancy into Dynamic. 2020-12-08 22:47:38 +08:00
Stephen Chung
8e8069f819 Do not propagate constants if shadowed. 2020-12-08 22:20:29 +08:00
Stephen Chung
bd52333802 Add namespace test. 2020-12-07 21:54:52 +08:00
Stephen Chung
c5babac3da Quote map property names. 2020-11-30 22:02:32 +08:00
Stephen Chung
4c4a209609 Fix tests. 2020-11-30 21:16:59 +08:00
Stephen Chung
1004bca5b5 Print arrays and maps with to_debug. 2020-11-30 11:20:51 +08:00
Stephen Chung
86009c70c8 Allow floating point numbers ending in a period. 2020-11-23 22:51:21 +08:00
Stephen Chung
eb4636f219 Fix LexError::ImproperSymbol. 2020-11-21 15:15:14 +08:00
Stephen Chung
0046fe7e73 Prefer Engine::disable_symbol to disable eval. 2020-11-21 15:08:18 +08:00
Stephen Chung
6c07d5fd73 Fix constant example. 2020-11-21 14:46:05 +08:00
Stephen Chung
2be757fda0 Make shadowing variables in custom syntax work. 2020-11-21 13:05:57 +08:00
Stephen Chung
17cd305af7 Restore previous always_search when exiting block. 2020-11-21 12:25:39 +08:00
Stephen Chung
6069a4cf55 do loop. 2020-11-20 22:23:37 +08:00
Stephen Chung
783803ec46 Update comments with links. 2020-11-20 16:52:28 +08:00
Stephen Chung
21c641d21f Set namespace in Module::set_fn_XXX_mut calls. 2020-11-17 15:11:58 +08:00
Stephen Chung
df72d324ba Fix tests. 2020-11-17 12:40:12 +08:00
Stephen Chung
038e3c2554 Add FnNamespace for module functions. 2020-11-17 12:23:53 +08:00
Stephen Chung
d50d48f26f Move definition of Array and Map to lib.rs. 2020-11-16 21:14:32 +08:00
Stephen Chung
ef02150afd Expose methods for Engine::register_module. 2020-11-16 14:07:48 +08:00
Stephen Chung
b75964e383 Add Dynamic::UNIT. 2020-11-15 23:14:29 +08:00
Stephen Chung
a63f14b59c Expr::Switch -> Stmt::Switch. 2020-11-14 23:43:36 +08:00