Stephen Chung
|
23cc48f937
|
Implement standard traits for Imports.
|
2021-07-04 16:33:26 +08:00 |
|
Stephen Chung
|
ab21ba703f
|
Rename scope_changed to scope_may_be_changed.
|
2021-07-04 16:31:01 +08:00 |
|
Stephen Chung
|
b4da054bab
|
Catch more parse errors.
|
2021-07-04 00:15:27 +08:00 |
|
Stephen Chung
|
69c14e65f3
|
Add ImmutableString::new() to mirror String API.
|
2021-07-02 11:51:13 +08:00 |
|
Stephen Chung
|
88bfe64e35
|
Simplify error display.
|
2021-07-02 11:50:24 +08:00 |
|
Stephen Chung
|
8c802dcd58
|
Fix optimizer bug.
|
2021-07-01 12:27:29 +08:00 |
|
Stephen Chung
|
a0f51a1a39
|
Split calc_qualified_var_hash.
|
2021-06-30 16:28:37 +08:00 |
|
Stephen Chung
|
f033896fec
|
Add From<BTreeSet> and From<HashSet> for Dynamic.
|
2021-06-30 11:08:29 +08:00 |
|
Stephen Chung
|
fc0256aff9
|
Refine ChainArgument.
|
2021-06-30 10:13:45 +08:00 |
|
Stephen Chung
|
c87645ba77
|
Fix unchecked build.
|
2021-06-29 23:29:05 +08:00 |
|
Stephen Chung
|
69352d74c2
|
Optimize Scope layout.
|
2021-06-29 23:22:54 +08:00 |
|
Stephen Chung
|
fc349f67f8
|
Make more functions const.
|
2021-06-29 23:17:31 +08:00 |
|
Stephen Chung
|
bd35999b75
|
Remove unnecessary Box::new().
|
2021-06-29 21:58:05 +08:00 |
|
Stephen Chung
|
8b0299077b
|
Simplify FuncArgs::parse.
|
2021-06-29 21:47:55 +08:00 |
|
Stephen Chung
|
d146de4ff9
|
Make FnPtr::fn_name_raw const.
|
2021-06-29 21:47:27 +08:00 |
|
Stephen Chung
|
0346bb874b
|
Make Expr::position const.
|
2021-06-29 18:41:03 +08:00 |
|
Stephen Chung
|
08828dd8c1
|
Use .into() instead of Box::new()
|
2021-06-29 18:25:20 +08:00 |
|
Stephen Chung
|
4143ef1e3f
|
Simplify Engine creation.
|
2021-06-29 17:47:31 +08:00 |
|
Stephen Chung
|
27c126d2f0
|
Make on_print/on_debug Option.
|
2021-06-29 17:42:03 +08:00 |
|
Stephen Chung
|
8f4a582f88
|
Remove free list of empty function resolution caches.
|
2021-06-28 22:06:46 +08:00 |
|
Stephen Chung
|
a13a724361
|
Fix builds.
|
2021-06-28 18:29:53 +08:00 |
|
Stephen Chung
|
e40e81ac1a
|
Mark simple functions const.
|
2021-06-28 18:06:05 +08:00 |
|
Stephen Chung
|
0c99165007
|
Remove description.
|
2021-06-28 17:24:05 +08:00 |
|
Stephen Chung
|
0888738b75
|
Change AST::clone_source to AST::source_raw.
|
2021-06-28 13:53:30 +08:00 |
|
Stephen Chung
|
7196b017f5
|
Add is_odd, is_even and is_zero.
|
2021-06-27 22:10:52 +08:00 |
|
Stephen Chung
|
1247b89352
|
Deprecate description for errors.
|
2021-06-24 14:55:53 +08:00 |
|
Stephen Chung
|
83297ffa00
|
Bump version to 1.0.
|
2021-06-24 11:50:03 +08:00 |
|
Stephen Chung
|
178fe6b978
|
Remove deprecated API.
|
2021-06-24 09:48:44 +08:00 |
|
Stephen Chung
|
2342777a13
|
Iterator reference parameters.
|
2021-06-21 19:12:28 +08:00 |
|
Stephen Chung
|
3b345acebf
|
Impl returns closures.
|
2021-06-20 21:42:13 +08:00 |
|
Stephen Chung
|
4093727dcb
|
New string functions.
|
2021-06-17 13:31:58 +08:00 |
|
Stephen Chung
|
425e038f4b
|
Split FnPtr into own file.
|
2021-06-17 09:50:32 +08:00 |
|
Stephen Chung
|
40e33fa6f9
|
Add to_hex, to_octal and to_binary.
|
2021-06-16 23:49:18 +08:00 |
|
Stephen Chung
|
a9ed434c73
|
Refine error position for missing indexer.
|
2021-06-16 19:45:45 +08:00 |
|
Stephen Chung
|
0b028dc900
|
Fix decimal build.
|
2021-06-16 19:44:54 +08:00 |
|
Stephen Chung
|
c492fa3234
|
Do not export SmartString.
|
2021-06-16 19:02:37 +08:00 |
|
Stephen Chung
|
204dcf60ac
|
Export Identifier only when internals.
|
2021-06-16 18:58:48 +08:00 |
|
Stephen Chung
|
e684626fc4
|
Remove unnecessary #[must_use].
|
2021-06-16 18:58:32 +08:00 |
|
Stephen Chung
|
42a14ab4cc
|
Make file structures consistent.
|
2021-06-16 18:36:33 +08:00 |
|
Stephen Chung
|
aa2e04bd25
|
Simplify Expr::Export.
|
2021-06-16 16:35:56 +08:00 |
|
Stephen Chung
|
0a857e6944
|
Remove position for catch keyword.
|
2021-06-16 16:15:29 +08:00 |
|
Stephen Chung
|
03cb398edf
|
Better implementation for Expression::get_literal_value.
|
2021-06-16 12:24:36 +08:00 |
|
Stephen Chung
|
b5898f451e
|
Fix no_closure build.
|
2021-06-14 12:09:54 +08:00 |
|
Stephen Chung
|
bbf3d31fbf
|
Code style refactor.
|
2021-06-14 12:02:22 +08:00 |
|
Stephen Chung
|
743d48f44f
|
Code style cleanup.
|
2021-06-13 17:41:34 +08:00 |
|
Stephen Chung
|
8ca24059b1
|
Add #[must_use]
|
2021-06-12 22:47:43 +08:00 |
|
Stephen Chung
|
68ea8c27fd
|
Fix unchecked.
Do not duplicate data size checking.
|
2021-06-12 10:26:50 +08:00 |
|
Stephen Chung
|
f9dcfeb1ad
|
Check data size after assignments.
|
2021-06-11 19:59:50 +08:00 |
|
Stephen Chung
|
79d9977cd5
|
Change take_string and take_immutable_string to as_XXX.
|
2021-06-10 10:45:44 +08:00 |
|
Stephen Chung
|
a5031969ca
|
New custom syntax expression types.
|
2021-06-10 10:16:39 +08:00 |
|
Stephen Chung
|
c3eb6d65f6
|
Refine Target variant names.
|
2021-06-08 23:40:21 +08:00 |
|
Stephen Chung
|
6397ce671e
|
Simplify code.
|
2021-06-08 23:40:10 +08:00 |
|
Stephen Chung
|
bcf82dafcb
|
Fix tests.
|
2021-06-08 19:30:13 +08:00 |
|
Stephen Chung
|
ae9f4b5b71
|
Remove collect() with exact sizes.
|
2021-06-08 15:48:55 +08:00 |
|
Stephen Chung
|
2c21928f67
|
Simplify constant function call arguments.
|
2021-06-08 14:46:49 +08:00 |
|
Stephen Chung
|
3e08160653
|
Simplify variable name parsing.
|
2021-06-07 11:43:00 +08:00 |
|
Stephen Chung
|
411b718a3b
|
Fix test.
|
2021-06-07 11:21:45 +08:00 |
|
Stephen Chung
|
1e66f1963a
|
Add counter variable to for statement.
|
2021-06-07 11:01:16 +08:00 |
|
Stephen Chung
|
989cb702c0
|
Use chars() to iterate strings.
|
2021-06-07 09:47:49 +08:00 |
|
Stephen Chung
|
859a18c6fd
|
Fix Dynamic hashing.
|
2021-06-06 14:47:32 +08:00 |
|
Stephen Chung
|
c02d702081
|
Use StaticVec.
|
2021-06-06 12:17:04 +08:00 |
|
Stephen Chung
|
a530fbf4ff
|
Remove unnecessary raw stirngs.
|
2021-06-05 15:26:43 +08:00 |
|
Stephen Chung
|
3371eed411
|
Use write_str.
|
2021-06-04 14:23:40 +08:00 |
|
Stephen Chung
|
e35122ae5d
|
Disallow registering indexers for integers.
|
2021-06-04 14:23:30 +08:00 |
|
Stephen Chung
|
99e06abd94
|
Fix test.
|
2021-06-02 15:18:09 +08:00 |
|
Stephen Chung
|
4cf6550fc6
|
Fix tests.
|
2021-06-02 15:05:33 +08:00 |
|
Stephen Chung
|
71684f5e2a
|
Implement bit-fields.
|
2021-06-02 14:29:18 +08:00 |
|
Stephen Chung
|
76bd48d0a6
|
Code style refinements.
|
2021-05-29 18:33:29 +08:00 |
|
Stephen Chung
|
5f36f1a28c
|
Remove PluginFunction::is_variadic.
|
2021-05-29 18:32:34 +08:00 |
|
Stephen Chung
|
dfea3ed22a
|
Code style refactor.
|
2021-05-25 10:54:48 +08:00 |
|
Stephen Chung
|
58d6a88bc4
|
Use checked exp for decimal.
|
2021-05-24 12:12:29 +08:00 |
|
Stephen Chung
|
98a232cb8c
|
Prevent exp underflow.
|
2021-05-23 11:54:40 +08:00 |
|
Stephen Chung
|
d07d4d295d
|
Fix tests.
|
2021-05-22 19:34:10 +08:00 |
|
Stephen Chung
|
cc3e2d79a5
|
Replace unwrap with expect.
|
2021-05-22 19:14:24 +08:00 |
|
Stephen Chung
|
1545b602a7
|
Streamline hashing function.
|
2021-05-19 20:26:11 +08:00 |
|
Stephen Chung
|
85a5aa14b3
|
Fix no_index build.
|
2021-05-18 22:03:34 +08:00 |
|
Stephen Chung
|
2ade56fd94
|
Fix no_index build.
|
2021-05-18 21:38:09 +08:00 |
|
Stephen Chung
|
dc9b4d7f4d
|
Indexer as fallback to property.
|
2021-05-18 20:12:30 +08:00 |
|
Stephen Chung
|
e64dad4e9f
|
Optimize scope.
|
2021-05-18 12:40:40 +08:00 |
|
Stephen Chung
|
70f09d1c84
|
Make tag i32 on 64-bit targets.
|
2021-05-18 12:24:23 +08:00 |
|
Stephen Chung
|
3116a39331
|
Minor code refactor.
|
2021-05-18 12:24:11 +08:00 |
|
Stephen Chung
|
d1fc362eec
|
Handle constants propagation.
|
2021-05-16 21:21:13 +08:00 |
|
Stephen Chung
|
cce2e02428
|
Fix feature builds.
|
2021-05-15 11:56:19 +08:00 |
|
Stephen Chung
|
941e09d29d
|
Guard against setters mutating constants, and allow pure setters.
|
2021-05-15 11:41:42 +08:00 |
|
Stephen Chung
|
565134c4da
|
Fix bug in constants propagation.
|
2021-05-15 11:00:25 +08:00 |
|
Stephen Chung
|
4f14fd55f5
|
Small code refinements.
|
2021-05-14 19:21:28 +08:00 |
|
Stephen Chung
|
9585de4ae4
|
Add Dynamic from shared.
|
2021-05-11 21:38:07 +08:00 |
|
Stephen Chung
|
be052b2b26
|
Bump version of rust_decimal and add more functions.
|
2021-05-11 20:31:31 +08:00 |
|
Stephen Chung
|
97c8194d17
|
No need to specify number of variables added/removed for custom syntax.
|
2021-05-11 10:58:28 +08:00 |
|
Stephen Chung
|
fd19d625b0
|
Refine doc comments.
|
2021-05-10 11:07:19 +08:00 |
|
Stephen Chung
|
2cf59e9954
|
Expose DynamicReadLock and DynamicWriteLoc under internals.
|
2021-05-10 09:43:45 +08:00 |
|
Stephen Chung
|
d230f448c0
|
Add no_smartstring to disable using SmartString.
|
2021-05-08 22:59:33 +08:00 |
|
Stephen Chung
|
2c0215ea3f
|
Shrink arrays and use boxed slices.
|
2021-05-05 18:38:52 +08:00 |
|
Stephen Chung
|
13c620de4b
|
Implement Eq and PartialEq for ScriptFnMetadata that sorts on function signature.
|
2021-05-04 10:19:08 +08:00 |
|
Stephen Chung
|
c61b118037
|
Fix decimal build.
|
2021-05-03 13:57:47 +08:00 |
|
Stephen Chung
|
c749bbb653
|
Reduce BTree sizes by boxing values.
|
2021-05-03 13:45:41 +08:00 |
|
Stephen Chung
|
aad842fe50
|
Remove Engine::enable_doc_comments.
|
2021-05-03 13:07:51 +08:00 |
|
Stephen Chung
|
bb5dc7b637
|
Add tag to Dynamic.
|
2021-05-02 23:57:35 +08:00 |
|
Stephen Chung
|
b091113334
|
Eliminate unnecessary data structures.
|
2021-04-27 22:28:01 +08:00 |
|
Stephen Chung
|
a5d4a0abb9
|
Disable on_progress with unchecked.
|
2021-04-25 15:27:58 +08:00 |
|
Stephen Chung
|
f81e3d6ff8
|
Fix unchecked builds.
|
2021-04-24 18:14:48 +08:00 |
|
Stephen Chung
|
41d3709db1
|
Fix decimal build.
|
2021-04-24 15:53:02 +08:00 |
|
Stephen Chung
|
c82a47ac26
|
Unchecked index access.
|
2021-04-24 14:47:20 +08:00 |
|
Stephen Chung
|
ce35f7fa72
|
Fix off by one error in optimizer.
|
2021-04-24 13:42:45 +08:00 |
|
Stephen Chung
|
b5a2937336
|
Do not treat Expr::Index with pure index as pure.
|
2021-04-24 13:42:30 +08:00 |
|
Stephen Chung
|
61b559a58f
|
Refine op-assignment.
|
2021-04-24 11:55:40 +08:00 |
|
Stephen Chung
|
dc3a217b2f
|
ImmutableString += String optimized.
|
2021-04-23 23:37:33 +08:00 |
|
Stephen Chung
|
cc1f941875
|
Optimize op-assignment.
|
2021-04-23 23:37:10 +08:00 |
|
Stephen Chung
|
335ab64a2c
|
Use SmartString inside ImmutableString.
|
2021-04-23 19:10:10 +08:00 |
|
Stephen Chung
|
fc782c5563
|
Refine posistion display.
|
2021-04-23 14:24:53 +08:00 |
|
Stephen Chung
|
1fbbb2a40d
|
Fix doc test.
|
2021-04-22 23:09:10 +08:00 |
|
Stephen Chung
|
a54fbb32ff
|
Add no_position feature.
|
2021-04-22 23:02:25 +08:00 |
|
Stephen Chung
|
fe37edd123
|
Add Stmt::FnCall.
|
2021-04-21 18:16:24 +08:00 |
|
Stephen Chung
|
cc546fcaab
|
Add version to repl.
|
2021-04-21 17:39:45 +08:00 |
|
Stephen Chung
|
956c57e9d6
|
Fix no-std build.
|
2021-04-21 10:05:28 +08:00 |
|
Stephen Chung
|
815f7ba09e
|
Remove Expr::FnPointer.
|
2021-04-20 23:40:52 +08:00 |
|
Stephen Chung
|
ce384d8bb0
|
Change FnPtr to SmartString.
|
2021-04-20 23:28:04 +08:00 |
|
Stephen Chung
|
8f1bff2ded
|
Change hash to hashes.
|
2021-04-20 22:26:08 +08:00 |
|
Stephen Chung
|
61d06183ea
|
Speed up Array/Map Dynamic construction.
|
2021-04-20 22:21:51 +08:00 |
|
Stephen Chung
|
8ff1f57900
|
Remove redundant std.
|
2021-04-20 19:19:35 +08:00 |
|
Stephen Chung
|
0f66c67f82
|
Do not unnecessarily use raw strings.
|
2021-04-20 12:01:35 +08:00 |
|
Stephen Chung
|
a186eb8d97
|
Fix hanging when parsing unterminated statements block.
|
2021-04-20 11:22:38 +08:00 |
|
Stephen Chung
|
46b22ddd96
|
Fix tests.
|
2021-04-19 18:08:29 +08:00 |
|
Stephen Chung
|
e88fb071f7
|
Fix module test.
|
2021-04-19 15:41:24 +08:00 |
|
Stephen Chung
|
c5e716e71f
|
Fix zero position bugs in array methods.
|
2021-04-19 15:11:03 +08:00 |
|
Stephen Chung
|
1145c5a4c0
|
Update rust_decimal.
|
2021-04-18 21:35:55 +08:00 |
|
Stephen Chung
|
bd145bd080
|
Do not unnecessarily reindex module.
|
2021-04-17 22:19:48 +08:00 |
|
Stephen Chung
|
2efe9d08a4
|
Skip eval if statements are empty.
|
2021-04-17 22:19:34 +08:00 |
|
Stephen Chung
|
90198d5440
|
Fix test.
|
2021-04-17 18:59:20 +08:00 |
|
Stephen Chung
|
eefdc09352
|
Allow shadowing of global.
|
2021-04-17 18:40:16 +08:00 |
|
Stephen Chung
|
9a8da93145
|
Delay creation of global module until actually needed.
|
2021-04-17 18:10:57 +08:00 |
|
Stephen Chung
|
1be7e60be2
|
Automatic global module.
|
2021-04-17 17:25:35 +08:00 |
|
Stephen Chung
|
01f0cc028b
|
Use no-std-compat to build no-std.
|
2021-04-17 15:15:54 +08:00 |
|
Stephen Chung
|
2f2b7403cb
|
Streamline as_mut to &mut.
|
2021-04-17 13:54:24 +08:00 |
|
Stephen Chung
|
199df9aa4a
|
Use deref for Target.
|
2021-04-17 13:36:51 +08:00 |
|
Stephen Chung
|
807a14eaa2
|
call_fn always evalutes AST.
|
2021-04-17 13:36:23 +08:00 |
|
Stephen Chung
|
6c92011ea1
|
Hide is_shared and is_locked under feature gates.
|
2021-04-17 12:03:29 +08:00 |
|
Stephen Chung
|
2b10c5c6c1
|
Correct position of negative numbers.
|
2021-04-16 21:59:05 +08:00 |
|
Stephen Chung
|
208e5fdbf4
|
New switch errors.
|
2021-04-16 13:28:36 +08:00 |
|
Stephen Chung
|
1f987ec61a
|
Streamine StmtBlock.
|
2021-04-16 13:15:11 +08:00 |
|
Stephen Chung
|
980a13ca42
|
Add switch case conditions.
|
2021-04-16 12:04:33 +08:00 |
|
Stephen Chung
|
8da4c0c2b2
|
Default switch case must be last.
|
2021-04-16 09:41:02 +08:00 |
|
Stephen Chung
|
187dbe537f
|
Improve debug AST printing.
|
2021-04-13 15:52:45 +08:00 |
|
Stephen Chung
|
5a0199f44f
|
Explanation of parse_string_literal return values.
|
2021-04-13 14:38:04 +08:00 |
|
Stephen Chung
|
44e2e6aeb4
|
Fix string handling at EOF.
|
2021-04-11 21:49:03 +08:00 |
|
Stephen Chung
|
ccbbf3eb34
|
Enhance floating-point display.
|
2021-04-11 11:20:34 +08:00 |
|
Stephen Chung
|
c1c1e5f684
|
Use string start position as error position.
|
2021-04-11 11:19:46 +08:00 |
|
Stephen Chung
|
6b4553ffc8
|
Fix panic with unterminated interpolated string.
|
2021-04-10 17:47:44 +08:00 |
|
Stephen Chung
|
40fda5139d
|
Support negative index counting from end.
|
2021-04-10 15:00:03 +08:00 |
|
Stephen Chung
|
716e9cf779
|
Fix string parsing state.
|
2021-04-10 11:11:42 +08:00 |
|
Stephen Chung
|
42555ac732
|
Unify string continuation parsing.
|
2021-04-10 10:20:17 +08:00 |
|
Stephen Chung
|
4aaf957d73
|
Gate doc-comment tokenizing.
|
2021-04-09 23:13:33 +08:00 |
|
Stephen Chung
|
29d186b361
|
Put doc-comments under metadata flag.
|
2021-04-09 22:49:47 +08:00 |
|
Stephen Chung
|
0f2e7e3825
|
Fix builds and tests.
|
2021-04-06 23:28:22 +08:00 |
|
Stephen Chung
|
f17a826f99
|
Refine debug print-out.
|
2021-04-06 23:18:41 +08:00 |
|
Stephen Chung
|
7ec49a9510
|
Fix f32_feature with serde.
|
2021-04-06 23:18:28 +08:00 |
|
Stephen Chung
|
131147c65d
|
Optimize Fn construct.
|
2021-04-06 12:26:38 +08:00 |
|
Stephen Chung
|
d3cfb3c605
|
Optimize position in variable access.
|
2021-04-05 23:59:15 +08:00 |
|
Stephen Chung
|
94fc5af285
|
Store short index in variable access.
|
2021-04-05 23:06:48 +08:00 |
|
Stephen Chung
|
a3ee0f4245
|
Fix no_index build.
|
2021-04-05 18:32:20 +08:00 |
|
Stephen Chung
|
f5d3a0ef4f
|
Promote expr block.
|
2021-04-05 14:57:07 +08:00 |
|
Stephen Chung
|
00784d39ad
|
PropertyExpected for map literal with interpolated key.
|
2021-04-05 14:51:26 +08:00 |
|
Stephen Chung
|
26bb88974a
|
Add function for string + char.
|
2021-04-05 00:10:08 +08:00 |
|
Stephen Chung
|
e6ea006ac6
|
Fix builds.
|
2021-04-05 00:05:56 +08:00 |
|
Stephen Chung
|
8956a77c8c
|
Add new state in TokenizeState to switch back to text mode.
|
2021-04-04 23:23:10 +08:00 |
|
Stephen Chung
|
0807c474a1
|
Revise using string interpolation.
|
2021-04-04 23:22:45 +08:00 |
|
Stephen Chung
|
bc9c1ab850
|
Add external control interface for tokenizer.
|
2021-04-04 23:08:27 +08:00 |
|
Stephen Chung
|
20aaf1826a
|
Fix builds.
|
2021-04-04 15:06:13 +08:00 |
|
Stephen Chung
|
e6c878edf3
|
Implement string interpolation.
|
2021-04-04 13:13:07 +08:00 |
|
Stephen Chung
|
f7ad1cec39
|
Fix builds.
|
2021-04-03 11:49:16 +08:00 |
|
Stephen Chung
|
b089d5b8f4
|
Fix bug in property setter op-assignment.
|
2021-04-03 11:12:35 +08:00 |
|
Stephen Chung
|
a738f750f9
|
Implement string functions with to_string/to_debug.
|
2021-04-02 19:26:55 +08:00 |
|
Stephen Chung
|
889edbef71
|
Allow cross-loading of relative file paths in FileModuleResolver.
|
2021-04-02 12:34:39 +08:00 |
|
Stephen Chung
|
98afb2e7d6
|
Fix feature builds.
|
2021-03-31 10:16:38 +08:00 |
|
Stephen Chung
|
a049f7b5ba
|
Optimize data structures.
|
2021-03-30 23:55:29 +08:00 |
|
Stephen Chung
|
b14d18934a
|
Add Dynamic::clone_cast.
|
2021-03-30 18:57:16 +08:00 |
|
Stephen Chung
|
e36e490a30
|
Support back-tick at EOL for literal strings.
|
2021-03-30 13:59:27 +08:00 |
|
Stephen Chung
|
d756b7bac6
|
Rename FnWrongDefinition to WrongFnDefinition.
|
2021-03-30 11:39:00 +08:00 |
|
Stephen Chung
|
d2ded7733a
|
Add support for line continuation and multi-line string literals.
|
2021-03-30 00:21:09 +08:00 |
|
Stephen Chung
|
3a6e6848fd
|
Fix serde build.
|
2021-03-29 18:46:32 +08:00 |
|
Stephen Chung
|
e306a92ea0
|
Change Map keys to Identifier.
|
2021-03-29 17:14:22 +08:00 |
|
Stephen Chung
|
41b48d591f
|
Change to no_smartstring feature.
|
2021-03-29 17:13:54 +08:00 |
|
Stephen Chung
|
07efdddba3
|
Add smartstring default feature.
|
2021-03-29 13:40:33 +08:00 |
|
Stephen Chung
|
fc6c5ecd00
|
Fix no_closure builds.
|
2021-03-29 13:07:10 +08:00 |
|
Stephen Chung
|
60f8a7f91c
|
Remove Float trait.
|
2021-03-29 11:36:15 +08:00 |
|
Stephen Chung
|
e5249cc1ae
|
Extract Identifier type.
|
2021-03-29 11:36:02 +08:00 |
|
Stephen Chung
|
241f5abe10
|
Change function call name into ImmutableString from Cow<str>.
|
2021-03-28 23:06:59 +08:00 |
|
Stephen Chung
|
7bdc2e3d20
|
Extract constant arguments from function calls.
|
2021-03-28 19:04:25 +08:00 |
|
Stephen Chung
|
8e8c367034
|
Update deprecated methods with since attribute.
|
2021-03-28 17:04:16 +08:00 |
|
Stephen Chung
|
7825cb1c56
|
Support shebangs in scripts.
|
2021-03-28 16:36:56 +08:00 |
|
Stephen Chung
|
47588f9784
|
Fix codegen tests.
|
2021-03-27 08:12:13 +08:00 |
|
Stephen Chung
|
0afc2a0842
|
Reverse Module::set_plugin_fn.
|
2021-03-26 18:41:28 +08:00 |
|
Stephen Chung
|
33f88dc813
|
Fix sync build.
|
2021-03-26 16:57:28 +08:00 |
|
Stephen Chung
|
c443c3bb48
|
Gate codegen metadata output under metadata feature.
|
2021-03-26 10:59:34 +08:00 |
|
Stephen Chung
|
8ea218f907
|
Metadata pulls in serde.
|
2021-03-25 19:49:30 +08:00 |
|
Stephen Chung
|
adbb5f8eb8
|
Use static array for codegen parameters info.
|
2021-03-25 14:02:50 +08:00 |
|
Stephen Chung
|
1d661f2c8e
|
Fix decimal build.
|
2021-03-24 22:26:07 +08:00 |
|
Stephen Chung
|
ac7f35cacb
|
Move all functions metadata into metadata feature.
|
2021-03-24 19:27:38 +08:00 |
|
Stephen Chung
|
c4fe1782df
|
Streamline string handling.
|
2021-03-24 13:17:52 +08:00 |
|
Stephen Chung
|
3a1e93e324
|
Fix no_std build.
|
2021-03-24 10:38:56 +08:00 |
|
Stephen Chung
|
3d0d5d1708
|
Streamline code.
|
2021-03-24 10:02:50 +08:00 |
|
Stephen Chung
|
6d1700728a
|
Intern module registration strings.
|
2021-03-24 09:56:25 +08:00 |
|
Stephen Chung
|
0d7f2c16cc
|
Reduce indirections.
|
2021-03-23 20:04:54 +08:00 |
|
Stephen Chung
|
f9429c06f9
|
Use template for object map literal.
|
2021-03-23 18:25:40 +08:00 |
|
Stephen Chung
|
f70225ca1d
|
Change HashMap to BTreeMap.
|
2021-03-23 12:13:53 +08:00 |
|
Stephen Chung
|
7a0032fc89
|
Move return type to param_names.
|
2021-03-22 23:11:23 +08:00 |
|
Stephen Chung
|
42d7736d94
|
Add conversions between Decimal and FLOAT.
|
2021-03-22 15:16:01 +08:00 |
|
Stephen Chung
|
22ff68cdc9
|
Fix feature builds.
|
2021-03-22 12:18:13 +08:00 |
|
Stephen Chung
|
a82f0fc738
|
Allow non-Dynamic in return_raw.
|
2021-03-22 11:18:09 +08:00 |
|
Stephen Chung
|
297a539528
|
Flatten function call arguments.
|
2021-03-20 23:57:43 +08:00 |
|
Stephen Chung
|
aa0594210c
|
Use RhaiResult for plugin return.
|
2021-03-19 10:30:30 +08:00 |
|
Stephen Chung
|
1200ffcd2b
|
Add test with &str parameter.
|
2021-03-17 22:32:22 +08:00 |
|
Stephen Chung
|
e2a66e0241
|
Fix doc tests.
|
2021-03-17 14:45:40 +08:00 |
|
Stephen Chung
|
6667a22c0c
|
Code style and docs.
|
2021-03-17 13:30:47 +08:00 |
|
Stephen Chung
|
699131be58
|
New reserved keywords.
|
2021-03-17 10:31:50 +08:00 |
|
Stephen Chung
|
4581943435
|
Remove public_only parameters.
|
2021-03-17 09:58:08 +08:00 |
|
Stephen Chung
|
5172ade179
|
Code style edits.
|
2021-03-16 18:16:40 +08:00 |
|
Stephen Chung
|
082ecaa739
|
Fix feature builds.
|
2021-03-15 23:03:26 +08:00 |
|
Stephen Chung
|
a1549bb377
|
Allow register_result to return any type.
|
2021-03-15 22:37:50 +08:00 |
|
Stephen Chung
|
27953ef745
|
Register parameter type names.
|
2021-03-15 22:19:21 +08:00 |
|
Stephen Chung
|
6cbf771fdd
|
Fix private function signature.
|
2021-03-15 21:30:55 +08:00 |
|
Stephen Chung
|
e9f280f917
|
Deprecate Module::set_fn_XXX API.
|
2021-03-15 12:39:06 +08:00 |
|
Stephen Chung
|
d0922adb5b
|
Deprecate RegisterFn and RegisterResultFn.
|
2021-03-15 11:36:30 +08:00 |
|
Stephen Chung
|
d9df6aabc8
|
Change precedence to own type.
|
2021-03-14 10:47:29 +08:00 |
|
Stephen Chung
|
008ef0a41b
|
Fix feature builds.
|
2021-03-14 10:47:21 +08:00 |
|
Stephen Chung
|
4e3fdf6dab
|
Revamp statement block optimization.
|
2021-03-13 23:43:05 +08:00 |
|
Stephen Chung
|
58d28fb468
|
Fix no-std build.
|
2021-03-13 19:08:49 +08:00 |
|
Stephen Chung
|
558ffeaf3e
|
Add FnResolutionCacheEntry.
|
2021-03-13 18:46:08 +08:00 |
|
Stephen Chung
|
61b0c7b2b3
|
Optimize imports layout.
|
2021-03-12 22:30:08 +08:00 |
|
Stephen Chung
|
81ca86a8d2
|
Fix internals build.
|
2021-03-12 19:33:22 +08:00 |
|
Stephen Chung
|
b74d2ff2b4
|
Fix test.
|
2021-03-12 14:13:19 +08:00 |
|
Stephen Chung
|
85fcb74be9
|
Furtuer optimize data structure sizes.
|
2021-03-12 14:11:08 +08:00 |
|
Stephen Chung
|
4e5d009386
|
Inline scope entries.
|
2021-03-12 13:26:47 +08:00 |
|
Stephen Chung
|
c2a34bd518
|
Fix internals build.
|
2021-03-11 22:27:35 +08:00 |
|
Stephen Chung
|
7b8a4c46e7
|
Add ability to terminate AST walk.
|
2021-03-11 21:55:55 +08:00 |
|
Stephen Chung
|
b2fd0222de
|
Refine statement block optimization.
|
2021-03-11 18:29:22 +08:00 |
|
Stephen Chung
|
99020f3ed1
|
Fix builds.
|
2021-03-10 23:37:04 +08:00 |
|
Stephen Chung
|
9b37d84a9b
|
Enable/disable caching in FileModuleResolver.
|
2021-03-10 23:01:04 +08:00 |
|
Stephen Chung
|
728ed81173
|
Optimize layout.
|
2021-03-10 22:12:48 +08:00 |
|
Stephen Chung
|
874b3fc843
|
Fix metadata build.
|
2021-03-10 14:10:04 +08:00 |
|
Stephen Chung
|
cbad703b00
|
Flatten data structures and more aggressive inlining.
|
2021-03-10 13:32:09 +08:00 |
|
Stephen Chung
|
352408fd36
|
Flatten statement blocks.
|
2021-03-10 12:27:10 +08:00 |
|
Stephen Chung
|
2ff2789326
|
Fix Stmt size.
|
2021-03-09 23:48:40 +08:00 |
|
Stephen Chung
|
b11b8d6d39
|
Reduce redirections in Stmt.
|
2021-03-09 23:30:48 +08:00 |
|
Stephen Chung
|
8853ebf059
|
Remove EvalAltResult::ErrorInExpr.
|
2021-03-09 19:13:26 +08:00 |
|
Stephen Chung
|
9daa894e25
|
Pack method call args more tightly.
|
2021-03-09 18:11:43 +08:00 |
|
Stephen Chung
|
bc2b9bfbfd
|
Fix builds.
|
2021-03-09 14:39:03 +08:00 |
|
Stephen Chung
|
b78c6ddf62
|
Better debug display.
|
2021-03-09 14:00:21 +08:00 |
|
Stephen Chung
|
975bb3d6bf
|
Map in operator to contains function call.
|
2021-03-09 13:44:54 +08:00 |
|
Stephen Chung
|
ff7844893d
|
Add contains for array.
|
2021-03-09 13:16:05 +08:00 |
|
Stephen Chung
|
7805540b7b
|
Improve in statement.
|
2021-03-09 11:55:49 +08:00 |
|
Stephen Chung
|
795a3afa81
|
Use reference for method call parameters, add position info.
|
2021-03-09 00:07:05 +08:00 |
|
Stephen Chung
|
fefa5a7dc7
|
Split has_script_fn and has_native_fn.
|
2021-03-08 18:40:23 +08:00 |
|
Stephen Chung
|
57140cbeeb
|
Fix internals build.
|
2021-03-08 15:55:26 +08:00 |
|
Stephen Chung
|
62928f8613
|
Revise function hashing.
|
2021-03-08 15:30:32 +08:00 |
|
Stephen Chung
|
1c3a07fe86
|
Fix metadata build.
|
2021-03-07 22:37:23 +08:00 |
|
Stephen Chung
|
a7ff9fb24f
|
Add bytes method for strings.
|
2021-03-07 22:33:02 +08:00 |
|
Stephen Chung
|
330d3f87af
|
Use namespace for ScriptFnDef.
|
2021-03-07 22:10:54 +08:00 |
|
Stephen Chung
|
e87f981674
|
Fix sync build.
|
2021-03-06 22:07:20 +08:00 |
|
Stephen Chung
|
4da5af8aae
|
Do not flatten arguments passed by value.
|
2021-03-06 21:25:49 +08:00 |
|
Stephen Chung
|
a126d05c3f
|
Skip evaluate condition for loop statement.
|
2021-03-06 16:05:22 +08:00 |
|
Stephen Chung
|
e14bef4b10
|
Trap &mut String parameters.
|
2021-03-06 14:41:35 +08:00 |
|
Stephen Chung
|
fe633ea7d3
|
Fix bug when passing shared string variable to &str parameter.
|
2021-03-06 10:44:55 +08:00 |
|
Stephen Chung
|
426f841aa2
|
Fix serde build.
|
2021-03-05 23:41:20 +08:00 |
|
Stephen Chung
|
a251219730
|
Remove public Dynamic::as_str.
|
2021-03-05 23:00:27 +08:00 |
|
Stephen Chung
|
ca1ce6b6b8
|
Streamline macros.
|
2021-03-05 22:58:20 +08:00 |
|
Stephen Chung
|
65ef32af19
|
Calculate whether contains global functions during indexing.
|
2021-03-05 20:07:35 +08:00 |
|
Stephen Chung
|
4e5039d4fe
|
Fix bug in built-in string operators.
|
2021-03-05 20:06:49 +08:00 |
|
Stephen Chung
|
8f0830af1c
|
Expose Variant under internals.
|
2021-03-05 14:18:36 +08:00 |
|
Stephen Chung
|
2052942d9d
|
Add Dynamic::as_unit.
|
2021-03-05 13:34:58 +08:00 |
|
Stephen Chung
|
88943915a7
|
Fix decimal build.
|
2021-03-05 12:58:27 +08:00 |
|
Stephen Chung
|
4c5ea8decc
|
Fix switch of non-hashable value.
|
2021-03-05 10:33:48 +08:00 |
|
Stephen Chung
|
0fa3968b74
|
Try not to check slice bounds in straight hasher.
|
2021-03-05 09:31:56 +08:00 |
|
Stephen Chung
|
01664ef7ee
|
Fix range overflow panics.
|
2021-03-04 23:47:52 +08:00 |
|
Stephen Chung
|
8d487906cc
|
Remove unnecessary implementation.
|
2021-03-04 22:57:24 +08:00 |
|
Stephen Chung
|
0f56b56b9c
|
Fix range function.
|
2021-03-04 21:43:00 +08:00 |
|
Stephen Chung
|
0589572d19
|
Refine inlining.
|
2021-03-04 18:13:47 +08:00 |
|
Stephen Chung
|
4e69b1847d
|
Turn Shared into alias.
|
2021-03-04 14:08:11 +08:00 |
|
Stephen Chung
|
399e7b0e28
|
Streamline macros.
|
2021-03-04 13:13:51 +08:00 |
|
Stephen Chung
|
22c392d796
|
Fix no_closure build.
|
2021-03-04 10:50:45 +08:00 |
|
Stephen Chung
|
2707b887c6
|
Fix shared value assignments.
|
2021-03-04 10:24:14 +08:00 |
|
Stephen Chung
|
ade290da7e
|
Simplify lifetimes.
|
2021-03-03 22:49:57 +08:00 |
|
Stephen Chung
|
ed568a9395
|
Make RhaiResult internal.
|
2021-03-03 22:49:29 +08:00 |
|
Stephen Chung
|
dfc1ea692f
|
Implement built-in operators with macros.
|
2021-03-03 21:46:48 +08:00 |
|
Stephen Chung
|
41c39a2060
|
Remove Dynamic::as_locked_immutable_string.
|
2021-03-03 18:13:41 +08:00 |
|
Stephen Chung
|
58df3ca141
|
Fix decimal and no_std builds.
|
2021-03-03 13:34:29 +08:00 |
|
Stephen Chung
|
77277ebf37
|
Use as_xxx() API.
|
2021-03-03 13:16:53 +08:00 |
|
Stephen Chung
|
2c8b15c740
|
Private global functions are still exposed.
|
2021-03-03 11:40:27 +08:00 |
|
Stephen Chung
|
ce6e6ceaaa
|
Fix serde build.
|
2021-03-02 23:19:35 +08:00 |
|
Stephen Chung
|
7262d63909
|
Move default comparisons into builtin.
|
2021-03-02 23:08:54 +08:00 |
|
Stephen Chung
|
5b1f80f5ce
|
Store negative result from has_override to function resolution cache.
|
2021-03-02 22:31:07 +08:00 |
|
Stephen Chung
|
6fd2262ace
|
Remove unnecessary is_def_fn function.
|
2021-03-02 22:27:53 +08:00 |
|
Stephen Chung
|
e3e53bd399
|
Introduce RhaiResult.
|
2021-03-02 15:02:28 +08:00 |
|
Stephen Chung
|
521c8fad27
|
Streamline ref object backup.
|
2021-03-02 14:44:21 +08:00 |
|
Stephen Chung
|
b76e8da5ee
|
Cache built-in functions to improve resolution speed.
|
2021-03-02 13:48:41 +08:00 |
|
Stephen Chung
|
67d277aa21
|
Disallow overriding keywords.
|
2021-03-01 22:44:56 +08:00 |
|
Stephen Chung
|
fc10df7d63
|
Keyword can no longer be overloaded.
|
2021-03-01 17:17:13 +08:00 |
|
Stephen Chung
|
b7e864bb78
|
Extract function resolution code.
|
2021-03-01 16:53:03 +08:00 |
|
Stephen Chung
|
b466d58192
|
Remove unnecessary AsRef and impl IntoIterator.
|
2021-03-01 15:58:11 +08:00 |
|
Stephen Chung
|
061fce1f02
|
No more pub_only.
|
2021-03-01 15:39:49 +08:00 |
|
Stephen Chung
|
1300ad8677
|
No need to copy sub-modules.
|
2021-03-01 14:54:20 +08:00 |
|
Stephen Chung
|
733f4af8b3
|
Fix no_std build.
|
2021-03-01 09:30:23 +08:00 |
|
Stephen Chung
|
8eee21ff38
|
Use object map as catch error value.
|
2021-02-28 14:38:34 +08:00 |
|
Stephen Chung
|
66b557692b
|
Allow negative range step.
|
2021-02-27 15:27:40 +08:00 |
|
Stephen Chung
|
082111074e
|
Encapsulate gen_call_signature.
|
2021-02-27 15:07:16 +08:00 |
|
Stephen Chung
|
c8addb45ac
|
Set position for errors in native function call.
|
2021-02-27 15:06:57 +08:00 |
|
Stephen Chung
|
d935401b03
|
Allow evaluating AST in Engine::call_fn_dynamic.
|
2021-02-26 11:21:23 +08:00 |
|
Stephen Chung
|
3f4dba9dbc
|
Build in operators between string and char.
|
2021-02-25 13:29:49 +08:00 |
|
Stephen Chung
|
f03983a9ca
|
Expose Engine::map_type_name.
|
2021-02-25 11:04:01 +08:00 |
|
Stephen Chung
|
1c1dfc701f
|
Fix Decimal.
|
2021-02-25 11:03:54 +08:00 |
|
Stephen Chung
|
9495d3f733
|
Separate op-assignment with other function calls.
|
2021-02-25 10:59:22 +08:00 |
|
Stephen Chung
|
49e5382ab0
|
Do not return default for comparisons between same types.
|
2021-02-25 10:59:11 +08:00 |
|
Stephen Chung
|
02057ef1d2
|
Avoid double checking of builtin's.
|
2021-02-24 23:23:32 +08:00 |
|
Stephen Chung
|
baaa0461bf
|
Limit Dynamic parameters to 16.
|
2021-02-24 22:40:18 +08:00 |
|
Stephen Chung
|
37540fda12
|
Fix bug with op-assignment.
|
2021-02-24 16:17:04 +08:00 |
|
Stephen Chung
|
9d6ad2092c
|
Fix decimal build.
|
2021-02-24 15:56:29 +08:00 |
|
Stephen Chung
|
4ac05aee8b
|
Disallow implicit comparisons between different numeric types.
|
2021-02-24 15:45:29 +08:00 |
|
Stephen Chung
|
0d933d865a
|
Do not test for built-in's when operands are not built-in.
|
2021-02-24 13:53:11 +08:00 |
|
Stephen Chung
|
c501b34191
|
Implement strings concat via Dynamic wildcards.
|
2021-02-24 11:28:21 +08:00 |
|
Stephen Chung
|
c739e54e5b
|
Refine strings package.
|
2021-02-24 11:05:39 +08:00 |
|
Stephen Chung
|
8b67a9a9bc
|
Do not test for op-assignment when not ending with '='.
|
2021-02-24 11:05:16 +08:00 |
|
Stephen Chung
|
71680e3c77
|
Extract op assignment into function.
|
2021-02-24 11:04:54 +08:00 |
|
Stephen Chung
|
6f876e85cc
|
Always call native for op-assignment operators.
|
2021-02-23 20:32:50 +08:00 |
|
Stephen Chung
|
123e9d6901
|
Short-circuits op-assignment for indexing and dotting.
|
2021-02-23 20:03:28 +08:00 |
|
Stephen Chung
|
36420f0b99
|
Implement print/debug functions via Dynamic parameters.
|
2021-02-23 19:08:05 +08:00 |
|
Stephen Chung
|
ba2b0630f7
|
Add support for Dynamic wildcard arguments.
|
2021-02-23 16:06:36 +08:00 |
|
Stephen Chung
|
8248c9999d
|
Add split version for chars.
|
2021-02-23 12:52:47 +08:00 |
|
Stephen Chung
|
e88713611c
|
Add split for arrays.
|
2021-02-23 11:57:50 +08:00 |
|
Stephen Chung
|
ac3d8e35d4
|
Add splitn, rsplit and rsplitn equivalents to strings.
|
2021-02-23 11:56:04 +08:00 |
|
Stephen Chung
|
0b49865f29
|
Fix no_std build.
|
2021-02-21 14:41:20 +08:00 |
|
Stephen Chung
|
4120e3c88e
|
Include decimal in generated docs.
|
2021-02-21 14:26:31 +08:00 |
|
Stephen Chung
|
54e26059dc
|
Set correct position for system errors inside function calls.
|
2021-02-20 14:32:37 +08:00 |
|
Stephen Chung
|
72334f0c42
|
Lower release stack overflow protection limit.
|
2021-02-20 14:05:47 +08:00 |
|
Stephen Chung
|
5285dad1a8
|
Fix feature build.
|
2021-02-19 23:48:11 +08:00 |
|
Stephen Chung
|
182fc2c3d1
|
Check for constant values passed to methods.
|
2021-02-19 23:13:53 +08:00 |
|
Stephen Chung
|
724ad05916
|
Add wasm64 as potential target.
|
2021-02-19 15:50:48 +08:00 |
|
Stephen Chung
|
4e3ab7fa6a
|
Add compiler guards for mutually-exclusive features.
|
2021-02-19 15:49:51 +08:00 |
|
Stephen Chung
|
b789c319e7
|
Rename serde_impl to serde.
|
2021-02-19 15:17:14 +08:00 |
|
Stephen Chung
|
bd5ff457d2
|
Built-in interop between FLOAT/Decimal and INT.
|
2021-02-19 11:47:26 +08:00 |
|
Stephen Chung
|
7b8322b6e1
|
Scope implements IntoIterator.
|
2021-02-18 23:35:22 +08:00 |
|
Stephen Chung
|
d2121e2183
|
Add operators between FLOAT/Decimal and INT.
|
2021-02-18 14:33:27 +08:00 |
|
Stephen Chung
|
9a9adbefcc
|
Wrap eval errors in ErrorInFunctionCall.
|
2021-02-18 14:33:12 +08:00 |
|
Stephen Chung
|
f8a7ada2a2
|
Implement Add and AddAssign to Position, fix bug in Position::is_beginning_of_line
|
2021-02-18 10:47:57 +08:00 |
|
Stephen Chung
|
cc90b5ffab
|
Remove unnecessary lifetimes.
|
2021-02-17 19:28:07 +08:00 |
|
Stephen Chung
|
678d0f5e33
|
Fix f32_float build.
|
2021-02-17 14:05:35 +08:00 |
|
Stephen Chung
|
a2277d07f3
|
Add arithmetic operators between FLOAT and INT.
|
2021-02-17 13:06:47 +08:00 |
|
Stephen Chung
|
b2ca8c34d1
|
Add atan2 and hypot functions.
|
2021-02-17 12:27:27 +08:00 |
|
Stephen Chung
|
909d48caed
|
Provide short-cuts to Decimal calculations.
|
2021-02-15 17:42:33 +08:00 |
|
Stephen Chung
|
f5c2903071
|
Refine Decimal rounding.
|
2021-02-15 12:07:45 +08:00 |
|
Stephen Chung
|
40e4a92401
|
Support scientific notation for Decimal parsing.
|
2021-02-14 17:34:53 +08:00 |
|
Stephen Chung
|
fc21756785
|
Add rounding functions to Decimal numbers.
|
2021-02-13 23:25:22 +08:00 |
|
Stephen Chung
|
224d93f167
|
Add comparison operators for Decimals.
|
2021-02-13 23:01:34 +08:00 |
|
Stephen Chung
|
61a01ea957
|
Add comments to Union.
|
2021-02-13 23:01:26 +08:00 |
|
Stephen Chung
|
f498dc81a3
|
Fix codegen test.
|
2021-02-13 22:19:46 +08:00 |
|
Stephen Chung
|
3650b04c38
|
Add Decimal number type.
|
2021-02-13 20:57:56 +08:00 |
|
Stephen Chung
|
4fdd58f220
|
Change AST filters to Fn from FnMut.
|
2021-02-13 10:56:09 +08:00 |
|
Stephen Chung
|
2846d1b63f
|
Change token to use FloatWrapper.
|
2021-02-12 23:07:28 +08:00 |
|
Stephen Chung
|
aea5ec50c9
|
Fix no-std build.
|
2021-02-11 21:46:11 +08:00 |
|
Stephen Chung
|
6f71367c15
|
Use scneitific notation when printing large or small floating-point numbers.
|
2021-02-11 21:28:07 +08:00 |
|
Stephen Chung
|
8ffb6c03b5
|
Add scientific notation to floats.
|
2021-02-11 19:20:30 +08:00 |
|
Stephen Chung
|
d49581356d
|
Remove duplicated functions lookup for script function call.
|
2021-02-11 12:13:30 +08:00 |
|
Stephen Chung
|
645e1fe583
|
Add missing cases to Expr::walk.
|
2021-02-11 01:47:09 +08:00 |
|
Stephen Chung
|
61638d6566
|
Use ** for power/exponentiation.
|
2021-02-10 12:41:27 +08:00 |
|
Stephen Chung
|
8c26b49a39
|
Change trig functions to take/return radians.
|
2021-02-10 12:10:50 +08:00 |
|
Stephen Chung
|
8f47f7c9e2
|
Add new floating-point functions.
|
2021-02-09 15:57:38 +08:00 |
|
Stephen Chung
|
88b01d6aba
|
Refine docs.
|
2021-02-09 14:22:55 +08:00 |
|
Stephen Chung
|
2dd5aceb1d
|
Fix panic of continue/break/return in try-catch block.
|
2021-02-09 14:22:21 +08:00 |
|
Stephen Chung
|
e88e65f36e
|
Fix bug with parsing empty statements.
|
2021-02-09 14:08:17 +08:00 |
|
Stephen Chung
|
58528db45c
|
Encapsulate functions resolution cache into State API.
|
2021-02-07 17:56:29 +08:00 |
|
Stephen Chung
|
a76bed2f46
|
Use eval_statements_block when at global.
|
2021-02-07 17:06:33 +08:00 |
|
Stephen Chung
|
f388d22c0f
|
Fix no_module build.,
|
2021-02-07 15:52:06 +08:00 |
|
Stephen Chung
|
aafff4fb93
|
Use stacked functions resolution caches to further improve performance.
|
2021-02-07 15:41:40 +08:00 |
|
Stephen Chung
|
7b87f81850
|
Add has_override and script calls to function resolution cache.
|
2021-02-07 15:09:27 +08:00 |
|
Stephen Chung
|
a54b88a8b0
|
Dynamic::into_shared not available under no_closure.
|
2021-02-06 22:16:44 +08:00 |
|
Stephen Chung
|
dff124b242
|
Save functions resolution cache during script call.
|
2021-02-06 22:16:05 +08:00 |
|
Stephen Chung
|
c5e2620d0f
|
Minor code refactors.
|
2021-02-03 19:14:26 +08:00 |
|
Stephen Chung
|
42058836ba
|
Fix panic in property access parsing error.
|
2021-01-31 18:44:50 +08:00 |
|
Stephen Chung
|
7fc38d4cd2
|
Change rhaiscript.github.io to rhai.rs
|
2021-01-30 07:19:54 +08:00 |
|
Stephen Chung
|
bb925a697c
|
Fix bug in Array::insert.
|
2021-01-29 22:29:36 +08:00 |
|
Stephen Chung
|
903b6d6795
|
Rename set_doc_comments to enable_doc_comments.
|
2021-01-28 16:59:19 +08:00 |
|
Stephen Chung
|
cef61bc924
|
Fix no_function build.
|
2021-01-28 16:48:56 +08:00 |
|
Stephen Chung
|
f76daadcba
|
Refine FuncArgs trait.
|
2021-01-28 15:29:55 +08:00 |
|
Stephen Chung
|
d14168a419
|
Refine Dynamic::take_immutable_string when shared.
|
2021-01-27 18:34:32 +08:00 |
|
Stephen Chung
|
e902c74073
|
Add threading example.
|
2021-01-25 11:31:54 +08:00 |
|
Stephen Chung
|
c245fe88fd
|
Allow stacking ! operators.
|
2021-01-24 21:21:15 +08:00 |
|
Stephen Chung
|
049f472ac9
|
Fix bug in internals.
|
2021-01-23 10:34:38 +08:00 |
|
Stephen Chung
|
3b42cc5bb2
|
Fix bug where plugin module parameters are consumed.
|
2021-01-23 09:37:27 +08:00 |
|
Stephen Chung
|
8aae3ac46c
|
Add function name to NativeCallContext.
|
2021-01-21 21:49:25 +08:00 |
|
Stephen Chung
|
f6553c1426
|
Fix feature builds.
|
2021-01-21 10:32:05 +08:00 |
|
Stephen Chung
|
0f7b390881
|
Serialize Timestamp with type name instead of panic.
|
2021-01-19 14:22:55 +08:00 |
|
Stephen Chung
|
4a8debb5ed
|
Fix builds.
|
2021-01-18 10:56:42 +08:00 |
|
Stephen Chung
|
ec272cf9b9
|
Add Serialize/Deserialize for Dynamic and ImmutableString.
|
2021-01-18 10:30:58 +08:00 |
|
Stephen Chung
|
6b5a14ee88
|
Fix compilation bug.
|
2021-01-18 10:23:41 +08:00 |
|
Stephen Chung
|
65621b79b1
|
Fix volatile warnings.
|
2021-01-16 14:46:03 +08:00 |
|
Ilya Lakhin
|
421baebbc1
|
Exposing AST functions shared module under internals feature
|
2021-01-16 01:38:50 +07:00 |
|
Stephen Chung
|
c4b6c31bf0
|
Use ahash as default hasher.
|
2021-01-15 23:52:56 +08:00 |
|
Stephen Chung
|
1c7884f0d8
|
Switch to fxhash for fast hashing.
|
2021-01-15 23:30:45 +08:00 |
|
Stephen Chung
|
92c7fd9e5b
|
Better error messages.
|
2021-01-15 17:13:04 +08:00 |
|
Stephen Chung
|
3f44e2893c
|
Wrap up 0.19.10.
|
2021-01-14 19:07:03 +08:00 |
|
Stephen Chung
|
fe65bf6137
|
Fix bug in optimizer.
|
2021-01-12 23:52:50 +08:00 |
|
Stephen Chung
|
8c47d61456
|
Refine documentation and comments.
|
2021-01-11 23:09:33 +08:00 |
|
Stephen Chung
|
5b9a18f5b8
|
Fix FileModuleResolver::clear_cache_for_path.
|
2021-01-10 19:34:26 +08:00 |
|
Stephen Chung
|
14fe4f9f1b
|
Change resolve_ast return type.
|
2021-01-09 23:26:50 +08:00 |
|
Stephen Chung
|
0b6657d1b1
|
Fix clippy.
|
2021-01-09 17:13:34 +08:00 |
|
Stephen Chung
|
e5b345bca4
|
Fix feature builds.
|
2021-01-09 17:06:01 +08:00 |
|
Stephen Chung
|
ad250fc973
|
Recursive self-contained AST.
|
2021-01-09 16:52:22 +08:00 |
|
Stephen Chung
|
637f47d259
|
Split AST::set_source into set_source/clear_source.
|
2021-01-09 15:20:07 +08:00 |
|
Stephen Chung
|
1513e6ab6a
|
Fix internals build.
|
2021-01-09 00:49:50 +08:00 |
|
Stephen Chung
|
bfe9ac2188
|
Fix feature builds.
|
2021-01-09 00:40:44 +08:00 |
|
Stephen Chung
|
0f1f6c4ad3
|
Add Engine::compile_to_self_contained.
|
2021-01-09 00:24:55 +08:00 |
|
Stephen Chung
|
b96c832141
|
Add EvalAltResult::clear_position().
|
2021-01-08 14:29:57 +08:00 |
|
Stephen Chung
|
ec18bd26a2
|
Handle no-std without sync.
|
2021-01-07 22:52:20 +08:00 |
|
Stephen Chung
|
96b1e7777b
|
Update URL links.
|
2021-01-07 17:30:06 +08:00 |
|
Stephen Chung
|
e059ca009c
|
Fix feature builds.
|
2021-01-06 18:22:45 +08:00 |
|
Stephen Chung
|
a5d6392107
|
Use NonZero for limits.
|
2021-01-06 13:46:53 +08:00 |
|
Stephen Chung
|
3fbcefe0ed
|
Move HashableHashMap to utils.
|
2021-01-05 18:37:07 +08:00 |
|
Stephen Chung
|
d5891d4802
|
Remove eval_expr_as_target.
|
2021-01-05 18:01:42 +08:00 |
|
Stephen Chung
|
cf9d35166d
|
Remove hashing of the entire script by making Expr and Stmt Hash.
|
2021-01-04 11:58:24 +08:00 |
|
Stephen Chung
|
e2a47b2a65
|
Disallow duplicated function definitions.
|
2021-01-03 20:54:08 +08:00 |
|
Stephen Chung
|
103af43f68
|
Fix typo in sync.
|
2021-01-03 13:46:08 +08:00 |
|
Stephen Chung
|
33f7c8557c
|
Put source into AST.
|
2021-01-03 13:30:01 +08:00 |
|
Stephen Chung
|
d3894e8aef
|
Add #[inline]
|
2021-01-03 13:29:42 +08:00 |
|
Stephen Chung
|
70a0d6ce58
|
Make id_raw return Option<&ImmutableString>
|
2021-01-03 11:25:25 +08:00 |
|
Stephen Chung
|
e3b7aa47a0
|
Merge branch 'master' of https://github.com/schungx/rhai
|
2021-01-03 11:15:57 +08:00 |
|
Ilya Lakhin
|
85ec781a35
|
Module::id_raw became crate-public
|
2021-01-03 09:29:50 +07:00 |
|
Ilya Lakhin
|
acbf5d8723
|
AST::set_source affects internal module id
|
2021-01-03 09:29:50 +07:00 |
|
Stephen Chung
|
1bbf473ec7
|
Add source info to native calls.
|
2021-01-03 00:20:13 +08:00 |
|
Stephen Chung
|
ef48f47b74
|
Refine docs and comments etc.
|
2021-01-02 23:30:10 +08:00 |
|
Stephen Chung
|
5a3bbaa322
|
Reduce size of FnPtr.
|
2021-01-02 13:37:40 +08:00 |
|
Stephen Chung
|
05fa8460a3
|
Remove unnecessary err.fill_position()
|
2021-01-02 13:29:16 +08:00 |
|
Stephen Chung
|
0a69caaf6d
|
Refine API for contexts.
|
2021-01-01 17:05:06 +08:00 |
|
Stephen Chung
|
8f7a588ac3
|
Fix no_std.
|
2020-12-30 22:37:22 +08:00 |
|
Stephen Chung
|
ba7f8c6391
|
Propagate source info.
|
2020-12-30 21:12:51 +08:00 |
|
Stephen Chung
|
386e34aacd
|
Fix no_module feature.
|
2020-12-30 15:37:39 +08:00 |
|
Stephen Chung
|
db5b855dea
|
Replace - with –
|
2020-12-29 23:01:34 +08:00 |
|
Stephen Chung
|
a45876856d
|
Enhance rhai-repl.
|
2020-12-29 22:04:31 +08:00 |
|
Stephen Chung
|
049ad3b6fd
|
Move rhai-repl and rhai-doc to bin.
|
2020-12-29 15:36:42 +08:00 |
|
Stephen Chung
|
2858aa3b2f
|
Avoid calling token mapper if none is specified.
|
2020-12-29 13:12:11 +08:00 |
|
Stephen Chung
|
13f5cec291
|
Fix call stack limits.
|
2020-12-29 12:29:45 +08:00 |
|
Stephen Chung
|
41c6f985f5
|
Fix bug with tokenizing identifiers.
|
2020-12-29 11:37:15 +08:00 |
|
Stephen Chung
|
eca8212f38
|
More code refinements.
|
2020-12-29 10:41:20 +08:00 |
|
Stephen Chung
|
e481a8019d
|
Simplify code and better error messages.
|
2020-12-28 14:21:13 +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
|
88f63fa24b
|
Refine docs.
|
2020-12-26 23:21:16 +08:00 |
|
Stephen Chung
|
66d3af256e
|
Enhance custom operators.
|
2020-12-26 23:21:09 +08:00 |
|
Stephen Chung
|
0a35c4cb41
|
Change custom precedence to Option<NonZeroU8>.
|
2020-12-26 17:42:19 +08:00 |
|
Stephen Chung
|
dc4e52e795
|
Code enhancements.
|
2020-12-26 13:05:57 +08:00 |
|
Stephen Chung
|
822fe80105
|
Reduce redirections.
|
2020-12-25 11:02:29 +08:00 |
|
Stephen Chung
|
8f969b1ab5
|
Reduce indirections.
|
2020-12-24 23:22:50 +08:00 |
|
Stephen Chung
|
363085efc3
|
Map actual 0 hash to 42.
|
2020-12-24 18:43:04 +08:00 |
|
Stephen Chung
|
8506640073
|
Use NonZeroU64 for function hashes.
|
2020-12-24 16:32:43 +08:00 |
|
Stephen Chung
|
c81a59435b
|
Make Scope Clone + Hash.
|
2020-12-24 09:42:03 +08:00 |
|
Stephen Chung
|
9fd7e01197
|
Simplify code.
|
2020-12-23 23:29:19 +08:00 |
|
Stephen Chung
|
08e7ad8c09
|
Add deprecated packages API.
|
2020-12-23 15:30:35 +08:00 |
|
Stephen Chung
|
cebbc2b607
|
Fix duplicate Ident export.
|
2020-12-23 12:11:53 +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
|
eb46ec8296
|
Simplify Imports.
|
2020-12-22 22:36:36 +08:00 |
|
Stephen Chung
|
0157f912e0
|
Remove PackageLibrary and PackagesCollection.
|
2020-12-22 22:36:30 +08:00 |
|
Stephen Chung
|
2a7e6c0884
|
Fixup docs.
|
2020-12-22 22:35:25 +08:00 |
|
Stephen Chung
|
2e7ec8f1db
|
IdentX -> Ident.
|
2020-12-22 16:45:56 +08:00 |
|
Stephen Chung
|
206400b187
|
Fix serde feature.
|
2020-12-22 15:27:27 +08:00 |
|
Stephen Chung
|
10da4d8976
|
LexError directly to ParseError.
|
2020-12-22 11:55:51 +08:00 |
|
Stephen Chung
|
8c41e549f7
|
Add Engine::gen_fn_metadata_with_ast_to_json.
|
2020-12-22 11:13:13 +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
|
730a7320d6
|
Run eval with new State.
|
2020-12-20 23:46:46 +08:00 |
|
Stephen Chung
|
cec27846ea
|
Simplify code.
|
2020-12-20 23:25:11 +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
|
22039b24b3
|
Add export to JSON.
|
2020-12-20 12:27:47 +08:00 |
|
Stephen Chung
|
c6a3ce2cd5
|
Add metadata export to JSON.
|
2020-12-19 19:42:18 +08:00 |
|
Stephen Chung
|
0182b2d3f4
|
Correct speed claim and others in docs.
|
2020-12-19 17:46:34 +08:00 |
|
Stephen Chung
|
d73f3a1d60
|
Add functions lookup cache.
|
2020-12-18 23:47:17 +08:00 |
|
Stephen Chung
|
db7b9cb0f9
|
Native only if function call is not a valid identifier.
|
2020-12-18 23:03:56 +08:00 |
|
Stephen Chung
|
882b26d2a1
|
Change ScriptFnMetadata to hold references.
|
2020-12-18 16:31:44 +08:00 |
|
Stephen Chung
|
719f0babbf
|
Fix comments parsing.
|
2020-12-18 16:07:19 +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
|
6f2fecb76b
|
Add type iterator docs.
|
2020-12-14 15:15:05 +08:00 |
|
Stephen Chung
|
ecc08271d9
|
Include actual tokens in custom syntax node.
|
2020-12-13 14:31:24 +08:00 |
|
Stephen Chung
|
87174de051
|
Add doc-comment to function metadata.
|
2020-12-12 20:09:29 +08:00 |
|
Stephen Chung
|
26449a9f1c
|
Add ScriptFnMetadata.
|
2020-12-12 18:44:28 +08:00 |
|
Stephen Chung
|
1087c338bd
|
Change output of AST::iter_functions.
|
2020-12-12 16:31:13 +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
|
5443368359
|
Pass Position into function calls.
|
2020-12-12 11:15:09 +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
|
99dd7a6481
|
Share constant variables for closures.
|
2020-12-09 21:06:36 +08:00 |
|
Stephen Chung
|
dbee0eb0f5
|
Rename AccessType to ReadWrite and ReadOnly.
|
2020-12-09 18:37:52 +08:00 |
|
Stephen Chung
|
7598ec136f
|
Fix feature builds.
|
2020-12-08 23:09:12 +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
|
aff207d4f4
|
Bump version.
|
2020-12-07 22:21:02 +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
|
b098160262
|
New CI test.
|
2020-11-28 16:58:02 +08:00 |
|
Stephen Chung
|
36546c7325
|
Fix builds
|
2020-11-27 23:37:59 +08:00 |
|
Stephen Chung
|
a0979d0c35
|
Code cleanup
|
2020-11-25 09:36:06 +08:00 |
|
Stephen Chung
|
86009c70c8
|
Allow floating point numbers ending in a period.
|
2020-11-23 22:51:21 +08:00 |
|
Stephen Chung
|
36aa827e15
|
Simply interned strings dict.
|
2020-11-23 21:12:57 +08:00 |
|
Stephen Chung
|
2d73468723
|
Add doc on Engine::gen_fn_signatures.
|
2020-11-23 20:27:20 +08:00 |
|
Stephen Chung
|
9abd397276
|
Fix no_function build.
|
2020-11-23 20:26:28 +08:00 |
|
Stephen Chung
|
b43223a94f
|
Add get_fn_metadata_list.
|
2020-11-23 19:11:32 +08:00 |
|
Stephen Chung
|
8d410dfc71
|
Add return type to function metadata.
|
2020-11-22 22:15:17 +08:00 |
|
Stephen Chung
|
6222f14fcb
|
Fix no-std build.
|
2020-11-22 17:49:00 +08:00 |
|
Stephen Chung
|
9edd494000
|
Fix builds.
|
2020-11-22 17:32:10 +08:00 |
|
Stephen Chung
|
07fe132e1a
|
Add gen_fn_siguatures API.
|
2020-11-22 17:21:34 +08:00 |
|
Stephen Chung
|
739dce72e3
|
Move if_def_fn into CorePackage.
|
2020-11-22 15:41:55 +08:00 |
|
Stephen Chung
|
e5c9ca23b5
|
Build index when creating a module.
|
2020-11-21 22:18:32 +08:00 |
|
Stephen Chung
|
254fd16e62
|
Fix type sizes test.
|
2020-11-21 17:39:43 +08:00 |
|
Stephen Chung
|
97368da762
|
Reserve begin/end.
|
2020-11-21 15:44:17 +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
|
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
|
b34e7840b0
|
Fix serde build
|
2020-11-20 21:07:31 +08:00 |
|
Stephen Chung
|
783803ec46
|
Update comments with links.
|
2020-11-20 16:52:28 +08:00 |
|
Stephen Chung
|
15afd83da5
|
Merge Expr::True/False into BoolConstant.
|
2020-11-19 22:29:50 +08:00 |
|
Stephen Chung
|
b87fa87a75
|
Fix internals.
|
2020-11-19 14:08:58 +08:00 |
|
Stephen Chung
|
5e4ede6f07
|
global_module -> global_namespace.
|
2020-11-19 13:56:03 +08:00 |
|
Stephen Chung
|
a00d6ba99e
|
Optimize IndexChainValue usage.
|
2020-11-19 13:51:59 +08:00 |
|
Stephen Chung
|
0e4743e7c7
|
Share environment when making module from AST.
|
2020-11-19 10:52:45 +08:00 |
|
Stephen Chung
|
1de85d749d
|
Optimize AST.
|
2020-11-19 10:41:08 +08:00 |
|
Stephen Chung
|
d35a7eeaa8
|
Optimize PackagesCollection.
|
2020-11-19 10:24:43 +08:00 |
|
Stephen Chung
|
a8cdb661f8
|
Optimize Imports.
|
2020-11-19 10:14:43 +08:00 |
|
Stephen Chung
|
21c641d21f
|
Set namespace in Module::set_fn_XXX_mut calls.
|
2020-11-17 15:11:58 +08:00 |
|
Stephen Chung
|
038e3c2554
|
Add FnNamespace for module functions.
|
2020-11-17 12:23:53 +08:00 |
|
Stephen Chung
|
999a87f86e
|
Fix no_optimize build.
|
2020-11-16 23:32:44 +08:00 |
|
Stephen Chung
|
7ef3bd6b20
|
Fix no_function build.
|
2020-11-16 23:25:19 +08:00 |
|
Stephen Chung
|
699220057f
|
Fix bug.
|
2020-11-16 23:17:34 +08:00 |
|
Stephen Chung
|
272c8505b8
|
Refactor use.
|
2020-11-16 23:10:14 +08:00 |
|
Stephen Chung
|
d50d48f26f
|
Move definition of Array and Map to lib.rs.
|
2020-11-16 21:14:32 +08:00 |
|
Stephen Chung
|
adb902326e
|
Reduce feature gates on imports.
|
2020-11-16 16:28:04 +08:00 |
|
Stephen Chung
|
ef02150afd
|
Expose methods for Engine::register_module.
|
2020-11-16 14:07:48 +08:00 |
|
Stephen Chung
|
cd62104296
|
More Dynamic constants.
|
2020-11-16 13:56:07 +08:00 |
|
Stephen Chung
|
b6d35ab310
|
Fix no_module build.
|
2020-11-16 09:30:17 +08:00 |
|
Stephen Chung
|
b75964e383
|
Add Dynamic::UNIT.
|
2020-11-15 23:14:29 +08:00 |
|
Stephen Chung
|
937b45a187
|
Add Engine::load_module.
|
2020-11-15 23:14:16 +08:00 |
|
Stephen Chung
|
fbe9425794
|
Add discriminant to Dynamic::hash.
|
2020-11-15 18:39:23 +08:00 |
|
Stephen Chung
|
c919ee4e46
|
Fine tune hash map sizes.
|
2020-11-15 13:49:54 +08:00 |
|
Stephen Chung
|
bde8917ed4
|
Set capacity of hash maps.
|
2020-11-15 12:07:35 +08:00 |
|
Stephen Chung
|
a63f14b59c
|
Expr::Switch -> Stmt::Switch.
|
2020-11-14 23:43:36 +08:00 |
|
Stephen Chung
|
0182117759
|
Change Stmt Variant names.
|
2020-11-14 22:55:23 +08:00 |
|
Stephen Chung
|
fce2c62f02
|
Reformat code files.
|
2020-11-14 22:43:56 +08:00 |
|
Stephen Chung
|
28de155f08
|
Add Expr::DynamicConstant.
|
2020-11-14 19:04:49 +08:00 |
|
Stephen Chung
|
89254a04c4
|
Fix tests.
|
2020-11-14 17:22:01 +08:00 |
|
Stephen Chung
|
56fbe39b7b
|
Use references for switch expressions, if possible.
|
2020-11-14 16:08:48 +08:00 |
|
Stephen Chung
|
b0c66eb5e5
|
Add benchmarks for switch statement.
|
2020-11-13 19:35:51 +08:00 |
|
Stephen Chung
|
bc07b4fa84
|
Fix builds.
|
2020-11-13 18:49:23 +08:00 |
|
Stephen Chung
|
55b4907f19
|
Add switch expression.
|
2020-11-13 18:32:18 +08:00 |
|
Stephen Chung
|
7d1b971b39
|
More interned strings.
|
2020-11-13 10:43:54 +08:00 |
|
Stephen Chung
|
27619b86db
|
Fix builds.
|
2020-11-12 23:09:27 +08:00 |
|
Stephen Chung
|
69a0f044f4
|
Use interned strings to prepare for match statement.
|
2020-11-12 22:36:13 +08:00 |
|
Stephen Chung
|
8e5a53bc0d
|
Implement Hash for Dynamic.
|
2020-11-12 21:53:26 +08:00 |
|
Stephen Chung
|
41c815f355
|
Optimize in-place.
|
2020-11-12 12:37:42 +08:00 |
|
Stephen Chung
|
7b27dcdd62
|
Fix error messages.
|
2020-11-11 13:25:45 +08:00 |
|
Stephen Chung
|
958762079e
|
Change modules to namespace.
|
2020-11-10 23:26:50 +08:00 |
|
Stephen Chung
|
c41f5aefcb
|
Change sub-modules to shared.
|
2020-11-09 22:44:20 +08:00 |
|
Stephen Chung
|
e69444293c
|
Encapsulate imported modules into AST.
|
2020-11-09 21:52:23 +08:00 |
|
Stephen Chung
|
821e64adc4
|
Allow multiple exports.
|
2020-11-09 14:38:33 +08:00 |
|
Stephen Chung
|
173f8474d6
|
Fix no_module build.
|
2020-11-09 12:50:18 +08:00 |
|
Stephen Chung
|
4b622a8830
|
Enable export let/export const short-hand.
|
2020-11-09 12:21:11 +08:00 |
|
Stephen Chung
|
48886eacc8
|
Add == and != to arrays and maps.
|
2020-11-08 23:00:37 +08:00 |
|
Stephen Chung
|
487a073caf
|
Fix recursive file import bug.
|
2020-11-08 23:00:03 +08:00 |
|
Stephen Chung
|
232ba27548
|
Add NativeCallContext::new.
|
2020-11-08 18:15:23 +08:00 |
|
Stephen Chung
|
b926eba501
|
Fix doc test.
|
2020-11-08 16:49:59 +08:00 |
|
Stephen Chung
|
1e07e4356e
|
Re-index imported modules if they are not yet indexed.
|
2020-11-08 14:29:54 +08:00 |
|
Stephen Chung
|
760f6c3678
|
Fix no_function build.
|
2020-11-08 10:56:33 +08:00 |
|
Stephen Chung
|
b3d318ef7f
|
Module resolver returns shared module.
|
2020-11-07 23:33:21 +08:00 |
|
Stephen Chung
|
d5d70367fa
|
Fix no-std buld.
|
2020-11-06 19:22:00 +08:00 |
|
Stephen Chung
|
6bc5ba6668
|
Enable functions to use global imports.
|
2020-11-06 19:17:07 +08:00 |
|
Stephen Chung
|
07a8a43298
|
Optimize data structures.
|
2020-11-06 16:27:40 +08:00 |
|
Stephen Chung
|
3f6db1d9d4
|
Remove extra export of LexError.
|
2020-11-04 20:20:55 +08:00 |
|
Stephen Chung
|
a5d22ddd45
|
Make FuncInfo a struct.
|
2020-11-04 14:37:46 +08:00 |
|
Stephen Chung
|
b390586bcc
|
Fix optimization of Stmt::Expr.
|
2020-11-04 13:11:37 +08:00 |
|
Stephen Chung
|
c287a61b93
|
Streamline ScriptFnDef.
|
2020-11-04 12:34:54 +08:00 |
|
Stephen Chung
|
f75942715d
|
Remove clippy warnings.
|
2020-11-04 12:34:34 +08:00 |
|
Stephen Chung
|
2168fd5361
|
Expr::Stmt takes a statements block.
|
2020-11-04 11:49:02 +08:00 |
|
Stephen Chung
|
32f41c69bd
|
Refine code and docs.
|
2020-11-03 21:50:14 +08:00 |
|
Stephen Chung
|
f74d947c6b
|
Fix constant assignment.
|
2020-11-03 13:08:19 +08:00 |
|
Stephen Chung
|
b9de8eaa7f
|
Minor code refactor.
|
2020-11-02 23:54:19 +08:00 |
|
Stephen Chung
|
cc304ba513
|
Fix serde build.
|
2020-11-02 13:18:37 +08:00 |
|
Stephen Chung
|
d7d6f74dfd
|
Add constant NO_POS.
|
2020-11-02 12:50:27 +08:00 |
|
Stephen Chung
|
6f3ce96d9d
|
Enable termination token.
|
2020-11-02 11:04:45 +08:00 |
|
Stephen Chung
|
b07a2aa79c
|
Pack Imports.
|
2020-11-01 23:42:00 +08:00 |
|
Stephen Chung
|
717e8e7eee
|
Remove unnecessary clone.
|
2020-11-01 22:55:19 +08:00 |
|
Stephen Chung
|
c55fc5a9a5
|
Optimize Scope.
|
2020-11-01 22:46:46 +08:00 |
|
Stephen Chung
|
a2e2b5e2ef
|
Add f32_float feature.
|
2020-11-01 15:48:48 +08:00 |
|
Stephen Chung
|
629e02f9da
|
Use Ident.
|
2020-11-01 00:04:02 +08:00 |
|
Stephen Chung
|
abbee80e5d
|
Do not box ModuleRef.
|
2020-10-31 23:51:59 +08:00 |
|
Stephen Chung
|
42eac410b7
|
Optimize Expr.
|
2020-10-31 23:26:21 +08:00 |
|
Stephen Chung
|
89811c8dfc
|
Pack Stmt and Expr some more.
|
2020-10-31 14:13:45 +08:00 |
|
Stephen Chung
|
3e23cf943e
|
Add to_float from f32 to f64.
|
2020-10-30 14:19:19 +08:00 |
|
Stephen Chung
|
a73584cd36
|
Fix no_std.
|
2020-10-29 12:00:02 +08:00 |
|
Stephen Chung
|
4e115d2bc2
|
Code structure refactor.
|
2020-10-29 11:37:51 +08:00 |
|
Stephen Chung
|
cbd7ed2ca7
|
Fix test.
|
2020-10-28 22:30:35 +08:00 |
|
Stephen Chung
|
bed6364dcb
|
Simplify hash calculation.
|
2020-10-28 22:30:29 +08:00 |
|
Stephen Chung
|
f5ffbfbe06
|
Code structure cleanup.
|
2020-10-28 22:18:44 +08:00 |
|
Stephen Chung
|
53adc58f63
|
Fix no_closure build.
|
2020-10-28 19:21:45 +08:00 |
|
Stephen Chung
|
f56c3fe9cb
|
Add Ident/IdentX to AST.
|
2020-10-28 19:11:17 +08:00 |
|
Stephen Chung
|
00b1051732
|
Optimize Stmt/Expr reflections.
|
2020-10-28 14:10:48 +08:00 |
|
Stephen Chung
|
427af14f1b
|
Don't wrap system errors from function calls.
|
2020-10-28 14:10:46 +08:00 |
|
Stephen Chung
|
30e11f137b
|
Move ErrorAssignmentToUnknownLHS to ParseError.
|
2020-10-28 10:26:36 +08:00 |
|
Stephen Chung
|
4b087d0e69
|
Fix test.
|
2020-10-27 23:45:04 +08:00 |
|
Stephen Chung
|
51fca1e757
|
Move Assignment to Stmt.
|
2020-10-27 23:21:20 +08:00 |
|
Stephen Chung
|
fd2ba54b49
|
Introduce BinaryExpr.
|
2020-10-27 23:00:05 +08:00 |
|
Stephen Chung
|
f62f7908ab
|
Pack Stmt tighter.
|
2020-10-27 19:23:43 +08:00 |
|
Stephen Chung
|
93b5df6b3c
|
Pack Stmt structure.
|
2020-10-27 18:18:19 +08:00 |
|
Stephen Chung
|
01663a6581
|
Refine docs.
|
2020-10-27 11:30:38 +08:00 |
|
Stephen Chung
|
4add90b215
|
Change parser output to String.
|
2020-10-27 09:56:37 +08:00 |
|
Stephen Chung
|
54d68c1061
|
Fix bug.
|
2020-10-26 21:49:49 +08:00 |
|
Stephen Chung
|
7496c77ac9
|
Custom syntax parser function takes &[String].
|
2020-10-26 19:46:58 +08:00 |
|
Stephen Chung
|
b467b18722
|
Fix no_std build.
|
2020-10-25 22:08:02 +08:00 |
|
Stephen Chung
|
b607a3a9ba
|
Add raw API for custom syntax.
|
2020-10-25 21:57:18 +08:00 |
|
Stephen Chung
|
f670d55871
|
Fix Send+Sync for EvalAltResult.
|
2020-10-25 21:48:18 +08:00 |
|
Stephen Chung
|
65432330c4
|
Add Module::fill_with.
|
2020-10-25 00:39:47 +08:00 |
|
Stephen Chung
|
2c7c719cd5
|
Minor cleanup before release.
|
2020-10-22 12:26:44 +08:00 |
|
Stephen Chung
|
e89d12c42f
|
Reserve thread keyword.
|
2020-10-21 14:45:20 +08:00 |
|
Stephen Chung
|
3660e42b96
|
Refactor try/catch code.
|
2020-10-21 14:45:10 +08:00 |
|
Stephen Chung
|
ad60db5bae
|
Reduce max fn call level.
|
2020-10-21 10:10:46 +08:00 |
|
Stephen Chung
|
44dc5f95c3
|
Fix serde feature.
|
2020-10-20 23:29:56 +08:00 |
|
Stephen Chung
|
07bdb824fe
|
Add try-catch.
|
2020-10-20 23:16:03 +08:00 |
|
Stephen Chung
|
5ee9dfc5cd
|
1) Change namespaces to iter_namespaces
2) throw can throw any value
|
2020-10-20 18:09:26 +08:00 |
|
Stephen Chung
|
92ba7b42d5
|
Implement namespaces chain.
|
2020-10-20 10:54:32 +08:00 |
|
Stephen Chung
|
13f1ae577b
|
Use plugins to define functions.
|
2020-10-19 23:49:01 +08:00 |
|
Stephen Chung
|
ccba5f2188
|
Move custom syntax into separate function.
|
2020-10-19 19:21:40 +08:00 |
|
Stephen Chung
|
a9fd0ff4de
|
Encapsulate scope into EvalContext;
Fix bug with custom syntax delta.
|
2020-10-19 19:11:55 +08:00 |
|
Stephen Chung
|
d1f9f4096d
|
Update badges
|
2020-10-19 17:26:47 +08:00 |
|
Stephen Chung
|
c8c4ca21ad
|
Update docs.
|
2020-10-19 14:26:15 +08:00 |
|
Stephen Chung
|
d68c951795
|
Pad string to exact length even when padding string is not multiple.
|
2020-10-18 22:47:58 +08:00 |
|
Stephen Chung
|
25f820f5bf
|
Reimplement pad for string.
|
2020-10-18 22:36:58 +08:00 |
|
Stephen Chung
|
6e5c903241
|
Fix no_module build.
|
2020-10-18 22:10:08 +08:00 |
|
Stephen Chung
|
46b92c9d1f
|
Allow NativeCallContext in function arguments.
|
2020-10-18 21:47:34 +08:00 |
|
Stephen Chung
|
dc4c47e008
|
Fix no_function and no_module builds.
|
2020-10-18 17:29:11 +08:00 |
|
Stephen Chung
|
232ff91957
|
Fix doc test.
|
2020-10-18 17:08:57 +08:00 |
|
Stephen Chung
|
82e6dd446a
|
Encapsulate register_fn_raw parameters into NativeCallContext.
|
2020-10-18 17:02:17 +08:00 |
|
Stephen Chung
|
58c820785b
|
Add drain and retain for arrays.
|
2020-10-18 13:18:12 +08:00 |
|
Stephen Chung
|
aa6d00f253
|
Fix bug.
|
2020-10-17 20:01:31 +08:00 |
|
Stephen Chung
|
f903eda8ab
|
Catch Fn and eval in method call at parse time.
|
2020-10-17 18:18:29 +08:00 |
|
Stephen Chung
|
7a4905209c
|
Introduce EvalAltResult::ErrorSystem.
|
2020-10-17 16:34:07 +08:00 |
|
Stephen Chung
|
8eb6c821d4
|
Fix tests.
|
2020-10-17 14:08:59 +08:00 |
|
Stephen Chung
|
39474d6420
|
Streamline function pointers and currying.
|
2020-10-17 13:49:16 +08:00 |
|
Stephen Chung
|
a16fc71935
|
Encapsulate RwLock and RefCell into Locked.
|
2020-10-16 23:41:56 +08:00 |
|
Stephen Chung
|
f995d09d8b
|
Fix bug with calling scripted function.
|
2020-10-16 21:16:06 +08:00 |
|
Stephen Chung
|
e62df6cbed
|
Remove none for array.
|
2020-10-16 21:02:16 +08:00 |
|
Stephen Chung
|
54d5b29390
|
Remove clone.
|
2020-10-15 23:44:05 +08:00 |
|
Stephen Chung
|
1e21a7f7e7
|
Introduce IndexChainValue.
|
2020-10-15 23:30:30 +08:00 |
|
Stephen Chung
|
fb05e811b7
|
Map::keys and Map::values can be used method-call style.
|
2020-10-15 22:11:40 +08:00 |
|
Stephen Chung
|
3b99b8f166
|
Simplify iterator registration.
|
2020-10-15 22:11:18 +08:00 |
|
Stephen Chung
|
707ece7e80
|
Refactor iterators API.
|
2020-10-14 23:22:10 +08:00 |
|
Stephen Chung
|
e0c39edff4
|
Enhance array functions.
|
2020-10-14 21:27:31 +08:00 |
|
Stephen Chung
|
3df8d6c398
|
Fix typo.
|
2020-10-13 17:16:19 +08:00 |
|
Stephen Chung
|
13c4d0bbb3
|
Adjust precedence of in.
|
2020-10-13 16:01:42 +08:00 |
|
Stephen Chung
|
9dceeaf114
|
Reserve ** operator.
|
2020-10-13 15:51:59 +08:00 |
|
Stephen Chung
|
037e8334d4
|
Reset modulo precedence.
|
2020-10-13 15:49:09 +08:00 |
|
Stephen Chung
|
28697e0380
|
Remove support for script-line native functions.
|
2020-10-13 14:40:02 +08:00 |
|
Stephen Chung
|
6db412815b
|
Add chop and extract for arrays.
|
2020-10-13 14:39:49 +08:00 |
|
Stephen Chung
|
1c86c66f1a
|
Add more functions to arrays.
|
2020-10-13 10:57:29 +08:00 |
|
Stephen Chung
|
3c7805d514
|
Encapsulate environment in ScriptFnDef.
|
2020-10-13 09:38:14 +08:00 |
|
Stephen Chung
|
0b4129fb98
|
Raise precedence of ~ and %.
|
2020-10-13 09:33:16 +08:00 |
|
Stephen Chung
|
a0d5249c4d
|
Fix unchecked build.
|
2020-10-12 23:17:16 +08:00 |
|
Stephen Chung
|
747fda1ec7
|
Add filter, map, reduce to Array.
|
2020-10-12 22:49:51 +08:00 |
|
Stephen Chung
|
6d0851de44
|
Reverse function call parameter change.
|
2020-10-12 19:36:34 +08:00 |
|
Stephen Chung
|
21b989afd5
|
Refine function call parameters size.
|
2020-10-12 17:00:58 +08:00 |
|
Stephen Chung
|
c4f00afbee
|
Disallow ! in module function calls.
|
2020-10-12 16:59:59 +08:00 |
|
Stephen Chung
|
e343bcfa8f
|
Change Option<usize> to usize for variable resolver index.
|
2020-10-11 22:41:26 +08:00 |
|
Stephen Chung
|
fd5a932611
|
Implement variable resolver.
|
2020-10-11 21:58:11 +08:00 |
|
Stephen Chung
|
9d93dac8e7
|
Reserve some more symbols.
|
2020-10-10 22:14:10 +08:00 |
|
Stephen Chung
|
994e5a4251
|
Move some concat functions to builtin.
|
2020-10-10 22:13:55 +08:00 |
|
Stephen Chung
|
dd9f58f323
|
Merge ser/de modules.
|
2020-10-10 13:43:14 +08:00 |
|
Stephen Chung
|
612ecc4ebc
|
Move StaticVec definition to lib.rs.
|
2020-10-10 13:41:55 +08:00 |
|
Stephen Chung
|
95c4ac4180
|
Fix no_float bug in time.
|
2020-10-09 13:47:35 +08:00 |
|
Stephen Chung
|
59b380b130
|
Allow propagation for pushed scope constants.
|
2020-10-09 13:26:32 +08:00 |
|
Stephen Chung
|
630ec51624
|
Simplify let/const statement.
|
2020-10-09 13:25:53 +08:00 |
|
Stephen Chung
|
1f74b36496
|
Add EntryType::is_constant.
|
2020-10-09 13:23:44 +08:00 |
|
Stephen Chung
|
a4b674d015
|
Trap elapsed error when timestamp is later than now.
|
2020-10-09 12:51:26 +08:00 |
|
Stephen Chung
|
7ede299aae
|
Allow expressions in constants.
|
2020-10-09 11:15:25 +08:00 |
|
Stephen Chung
|
d511aac7a4
|
Reduce max call stack size for debug.
|
2020-10-08 23:00:01 +08:00 |
|
Stephen Chung
|
1272eeb81a
|
Add/remove #[inline] attributes.
|
2020-10-08 22:25:50 +08:00 |
|
Stephen Chung
|
b2d603ec06
|
Refine Add/AddAssign for AST and Module.
|
2020-10-07 23:25:08 +08:00 |
|
Stephen Chung
|
ec19103478
|
Fix serde typo.
|
2020-10-07 15:51:00 +08:00 |
|
Stephen Chung
|
d7bfe13b3e
|
Add convenient functions and operators for Module and module resolvers.
|
2020-10-07 15:40:36 +08:00 |
|
Stephen Chung
|
1523981e4e
|
Add AST::combine and AST::combine_filtered.
|
2020-10-07 12:11:25 +08:00 |
|
Stephen Chung
|
3340760b35
|
Fix no_std build.
|
2020-10-07 11:44:06 +08:00 |
|
Stephen Chung
|
ae1157a140
|
Remove Expr::get_constant_str and change Expr::get_constant_value not to panic.
|
2020-10-06 22:09:26 +08:00 |
|
Stephen Chung
|
8809d25d3c
|
Add Dynamic::from(&str)
|
2020-10-06 21:25:05 +08:00 |
|
Stephen Chung
|
1de44c7ecd
|
Reserve $ symbol.
|
2020-10-05 23:02:50 +08:00 |
|
Stephen Chung
|
44f8d9e429
|
Refine Module::iter_script_fn_info.
|
2020-10-05 21:52:39 +08:00 |
|
Stephen Chung
|
2f6bb643aa
|
Remove Module::get_script_function_by_signature.
|
2020-10-05 18:07:40 +08:00 |
|
Stephen Chung
|
82d48df734
|
Merge data type mismatch errors.
|
2020-10-05 13:45:57 +08:00 |
|
Stephen Chung
|
b67a743306
|
Do not eagerly evaluate is_def_fn and is_def_var.
|
2020-10-05 12:14:34 +08:00 |
|
Stephen Chung
|
29bf790286
|
Fix no_function build.
|
2020-10-05 12:09:45 +08:00 |
|
Stephen Chung
|
4356d02828
|
Fix no_object builds.
|
2020-10-05 12:05:46 +08:00 |
|
Stephen Chung
|
0d0affd5e9
|
Eagerly evaluate built-in operators for OptimizationLevel::Simple.
|
2020-10-05 10:27:31 +08:00 |
|
Stephen Chung
|
a962debf0d
|
Simplify target back propagation.
|
2020-10-04 10:40:44 +08:00 |
|
Stephen Chung
|
23d0f52284
|
Better error messages.
|
2020-10-03 23:27:30 +08:00 |
|
Stephen Chung
|
1e13e6be5f
|
Doc formatting.
|
2020-10-03 18:49:11 +08:00 |
|
Stephen Chung
|
fbfb7677c1
|
Add is_def_var and is_def_fn.
|
2020-10-03 16:25:58 +08:00 |
|
Stephen Chung
|
eec3f4e1bf
|
Module:;eval_ast_as_new defaults to merging namespaces.
|
2020-10-03 11:42:54 +08:00 |
|
Stephen Chung
|
a72f70846f
|
Make merged namespace more efficient.
|
2020-10-02 23:14:33 +08:00 |
|
Stephen Chung
|
08ca90a136
|
Use ImmutableString for import alias.
|
2020-10-02 18:52:18 +08:00 |
|
Stephen Chung
|
038b058e63
|
Use shared AST module.
|
2020-10-02 16:21:18 +08:00 |
|
Stephen Chung
|
d2c94ba07c
|
Add more module tests.
|
2020-10-02 14:55:02 +08:00 |
|
Stephen Chung
|
e8d5f78f88
|
Simplify code.
|
2020-10-01 23:31:27 +08:00 |
|
Stephen Chung
|
2290c72de1
|
Fix tests.
|
2020-09-30 23:27:41 +08:00 |
|
Stephen Chung
|
a04ed02b54
|
Simplify macro system and update doc comments.
|
2020-09-30 22:55:40 +08:00 |
|
Stephen Chung
|
e526b53b42
|
No need to merge module if empty.
|
2020-09-30 09:57:21 +08:00 |
|
Stephen Chung
|
c7dfbd48a6
|
Restore call_fn_dynamic.
|
2020-09-29 18:37:00 +08:00 |
|
Stephen Chung
|
69054f1b69
|
Change lib to &Module.
|
2020-09-29 18:17:41 +08:00 |
|
Stephen Chung
|
ea78fa2b27
|
Change SharedPluginFunction to Shared<FnPlugin>
|
2020-09-29 13:06:48 +08:00 |
|
Stephen Chung
|
2123b0a279
|
Module::eval_ast_as_new will merge global and module namespaces if private_namespace is true.
|
2020-09-28 18:53:03 +08:00 |
|
Stephen Chung
|
5e43f2e5a4
|
Better error handling messages.
|
2020-09-28 11:19:49 +08:00 |
|
Stephen Chung
|
a1cf852bb9
|
Merge in function pointer arguments.
|
2020-09-28 11:01:25 +08:00 |
|
Stephen Chung
|
f92d992165
|
Handle timestamps in serde.
|
2020-09-27 22:34:07 +08:00 |
|
Stephen Chung
|
e1ce67adc2
|
Add TimeStamp variant.
|
2020-09-27 22:15:35 +08:00 |
|
Stephen Chung
|
516f7b60d9
|
Fix no_std build.
|
2020-09-27 18:47:20 +08:00 |
|
Stephen Chung
|
a2694114d1
|
Better panic messages.
|
2020-09-27 11:14:50 +08:00 |
|
Stephen Chung
|
726b030616
|
Implement +/- operators for timestamp.
|
2020-09-26 19:45:33 +08:00 |
|
Stephen Chung
|
e0483f2a50
|
Implement Dynamic::From<Instant>
|
2020-09-26 19:41:04 +08:00 |
|
Stephen Chung
|
03dce86328
|
Support Dynamic as function default return value.
|
2020-09-26 16:27:38 +08:00 |
|
Stephen Chung
|
e62d1cd3ff
|
Better error message for setter.
|
2020-09-26 12:34:06 +08:00 |
|
Stephen Chung
|
4efe6b90e7
|
Add string::split().
|
2020-09-25 23:02:49 +08:00 |
|
Stephen Chung
|
da9aa60256
|
Wrap file module functions in ErrorInModule.
|
2020-09-25 20:24:03 +08:00 |
|
Stephen Chung
|
39bbff878c
|
Fix doc test.
|
2020-09-25 20:00:49 +08:00 |
|
Stephen Chung
|
f406fc0ac0
|
Fix function calls.
|
2020-09-25 19:07:24 +08:00 |
|
Stephen Chung
|
599fe846cb
|
Add complete_namespace to Module::eval_ast_as_new.
|
2020-09-25 18:07:39 +08:00 |
|
Stephen Chung
|
93f53fa417
|
Refactor module.rs into files structure.
|
2020-09-25 10:59:21 +08:00 |
|
Stephen Chung
|
e637bfa51d
|
Change pure to independent.
|
2020-09-25 09:39:18 +08:00 |
|
Stephen Chung
|
6a53c446d3
|
Fix no_function build.
|
2020-09-24 23:32:54 +08:00 |
|
Stephen Chung
|
c4ec93080e
|
New FileModuleResolver.
|
2020-09-24 22:50:28 +08:00 |
|
Stephen Chung
|
b8aeaa84de
|
Add functions to iterate script function definitions.
|
2020-09-24 16:10:25 +08:00 |
|
Stephen Chung
|
9fcbda1ba4
|
Add reverse function to arrays.
|
2020-09-24 10:51:21 +08:00 |
|
Stephen Chung
|
d91d983c74
|
Enable dots on numbers to parse as method calls.
|
2020-09-23 22:48:28 +08:00 |
|
Stephen Chung
|
39433164f2
|
Fix no_float build.
|
2020-09-23 12:06:17 +08:00 |
|
Stephen Chung
|
4e0f887025
|
Merge branch 'master' into plugins
|
2020-09-23 12:00:15 +08:00 |
|
Stephen Chung
|
ed38b50490
|
Add parse_int and parse_float.
|
2020-09-23 12:00:03 +08:00 |
|
Stephen Chung
|
5718f454c4
|
Merge pull request #60 from jhwgh1968/plugins
Remove redundant clones in codegen
|
2020-09-23 11:54:57 +08:00 |
|
J Henry Waugh
|
d65042088e
|
Remove redundant clones in codegen
|
2020-09-22 21:38:59 -05:00 |
|
Stephen Chung
|
035b9cb839
|
Avoid &mut ImmutableString.
|
2020-09-22 22:45:11 +08:00 |
|
Stephen Chung
|
5a37497a22
|
Flatten type groups and types in parentheses.
|
2020-09-22 21:29:44 +08:00 |
|
Stephen Chung
|
3224c5baf5
|
Avoid &mut ImmutableString.
|
2020-09-22 19:42:44 +08:00 |
|
Stephen Chung
|
02f37870e5
|
Better position of string literal errors.
|
2020-09-22 19:18:06 +08:00 |
|
Stephen Chung
|
41a16c9cf7
|
Use modules.
|
2020-09-22 19:17:50 +08:00 |
|
Stephen Chung
|
e7566da7d2
|
Fix no_std build.
|
2020-09-22 18:06:36 +08:00 |
|
Stephen Chung
|
594dcc3a06
|
Disallow registering indexers for arrays, maps and strings.
|
2020-09-22 17:57:56 +08:00 |
|
Stephen Chung
|
283495a02f
|
Setters should have no return value.
|
2020-09-22 12:14:26 +08:00 |
|
Stephen Chung
|
8095ebc9e4
|
Remove unused imports.
|
2020-09-21 18:00:46 +08:00 |
|
Stephen Chung
|
83f9df2852
|
Fix op-assignment overrides.
|
2020-09-21 16:15:52 +08:00 |
|
J Henry Waugh
|
c8dffff515
|
Fix clippy::perf lint errors
|
2020-09-20 13:07:46 -05:00 |
|
J Henry Waugh
|
788a22108b
|
Hide clippy errors from exported modules
|
2020-09-20 13:03:35 -05:00 |
|
Stephen Chung
|
a49b58002a
|
Fix doc tests.
|
2020-09-20 15:55:11 +08:00 |
|
Stephen Chung
|
c7a675e18a
|
Fix no_object builds.
|
2020-09-20 14:52:38 +08:00 |
|
Stephen Chung
|
1ae6af5289
|
Merge branch 'plugins_dev' of https://github.com/schungx/rhai into plugins
|
2020-09-20 14:32:44 +08:00 |
|
Stephen Chung
|
2ba875a177
|
Use take_string for &str and String parameters.
|
2020-09-20 14:23:14 +08:00 |
|
Stephen Chung
|
5a7a0f11ae
|
Fix doc test.
|
2020-09-20 10:51:37 +08:00 |
|
Stephen Chung
|
cfe28c9282
|
Remove Position parameter from plugin call function.
|
2020-09-20 10:51:37 +08:00 |
|
Stephen Chung
|
3341f40fd2
|
Refine docs.
|
2020-09-20 10:50:58 +08:00 |
|
Stephen Chung
|
39546b7053
|
Enable &str and String parameters in module functions.
|
2020-09-19 18:12:23 +08:00 |
|
Stephen Chung
|
848bdf3f01
|
Add combine_with_exported_module.
|
2020-09-16 21:50:44 -05:00 |
|
Ilya Lakhin
|
4bb1a34abb
|
Fixes bug in Module::set_fn_4_mut
|
2020-09-15 10:14:34 +07:00 |
|
Stephen Chung
|
db59aed14e
|
Fix bug in optimizer for if statements with empty true blocks.
|
2020-09-14 22:24:55 +08:00 |
|
Stephen Chung
|
6c69a40083
|
Allow scripted functions in packages.
|
2020-09-11 22:32:59 +08:00 |
|
Stephen Chung
|
a75aba8a85
|
Rename calc_fn_spec to calc_fn_hash.
|
2020-09-11 22:24:44 +08:00 |
|
Stephen Chung
|
d1ab9a2848
|
Fix bug on unary function hashes.
|
2020-09-11 22:09:09 +08:00 |
|
Stephen Chung
|
fed65676a2
|
cargo fmt.
|
2020-09-10 17:42:34 +08:00 |
|
Stephen Chung
|
d41fde9c31
|
Use multiple renames to simplify plugins.
|
2020-09-08 18:01:34 +08:00 |
|
Stephen Chung
|
91b4f8a6bc
|
Fix no-std build.
|
2020-08-31 12:09:52 +08:00 |
|
Stephen Chung
|
ee3781e86e
|
Simplify error handling code.
|
2020-08-31 11:46:32 +08:00 |
|
Stephen Chung
|
32985c9480
|
Fix string package for no_std.
|
2020-08-30 23:18:47 +08:00 |
|
Stephen Chung
|
75ca495199
|
Nicer formatting/less indentation of module plugin blocks.
|
2020-08-30 17:28:53 +08:00 |
|
Stephen Chung
|
9ab3d87cfc
|
Refactor.
|
2020-08-24 22:37:44 +08:00 |
|
Stephen Chung
|
2fbc1b7910
|
Add missing pub to functions.
|
2020-08-24 10:38:15 +08:00 |
|
Stephen Chung
|
03237c9852
|
Merge branch 'plugins' into plugins_dev
|
2020-08-24 08:36:15 +08:00 |
|
J Henry Waugh
|
9fe3672514
|
string_more: add missing pub from crop_string
|
2020-08-23 17:49:50 -05:00 |
|
Stephen Chung
|
1dacf21a84
|
Fix no_std builds by pulling in num-traits.
|
2020-08-23 18:28:55 +08:00 |
|
Stephen Chung
|
3902e49a7d
|
Fix bug in right-shifts.
|
2020-08-23 18:04:19 +08:00 |
|
Stephen Chung
|
a72f797da1
|
Merge branch 'plugins' into plugins_dev
|
2020-08-23 17:54:37 +08:00 |
|
Stephen Chung
|
4fff90d19b
|
Merge branch 'master' into plugins
|
2020-08-23 17:54:02 +08:00 |
|
Stephen Chung
|
7cd345b128
|
Fix bug in closure capture for no_object.
|
2020-08-23 17:46:39 +08:00 |
|
Stephen Chung
|
57acd618de
|
Merge branch 'master' into plugins
|
2020-08-23 17:24:27 +08:00 |
|
Stephen Chung
|
e2f271644a
|
Expand packages and raw Engine write-up.
|
2020-08-23 17:22:39 +08:00 |
|
Stephen Chung
|
196e145c96
|
Derive standard traits for Limits.
|
2020-08-23 16:29:32 +08:00 |
|
Stephen Chung
|
c62914b91a
|
Merge branch 'master' into plugins_dev
|
2020-08-22 23:04:34 +08:00 |
|
Stephen Chung
|
86c7862ac4
|
Merge branch 'master' into plugins
|
2020-08-22 23:03:32 +08:00 |
|
Stephen Chung
|
177a0de23c
|
Fix closure test.
|
2020-08-22 23:01:25 +08:00 |
|
Stephen Chung
|
3042e3d9db
|
Merge branch 'master' into plugins_dev
|
2020-08-22 22:51:41 +08:00 |
|
Stephen Chung
|
0ece75aba3
|
Allow module access in closures.
|
2020-08-22 22:44:24 +08:00 |
|
Stephen Chung
|
211ce54973
|
Move most packages to modules.
|
2020-08-22 22:26:49 +08:00 |
|
Stephen Chung
|
5d6fdba24d
|
Merge branch 'plugins' into plugins_dev
|
2020-08-22 16:20:53 +08:00 |
|
J Henry Waugh
|
15a8f528ae
|
Avoid export_fn+cfg attributes in Rhai packages
|
2020-08-21 23:26:24 -05:00 |
|
Stephen Chung
|
0b04d05afe
|
Do not parse closures when allow_anonymous_fn is false.
|
2020-08-22 11:08:27 +08:00 |
|
Stephen Chung
|
08977e2a62
|
Use combine_flatten for plugin modules.
|
2020-08-21 21:48:45 +08:00 |
|
Stephen Chung
|
3c0d431fd2
|
Merge branch 'plugins' into plugins_dev
|
2020-08-20 22:14:56 +08:00 |
|
Stephen Chung
|
729ab99ec3
|
Refine packages.
|
2020-08-20 22:11:41 +08:00 |
|
Stephen Chung
|
6e54b22b31
|
Merge branch 'master' into plugins_dev
|
2020-08-20 17:02:57 +08:00 |
|
Stephen Chung
|
24610688d3
|
Fix no_std build.
|
2020-08-20 17:02:25 +08:00 |
|
Stephen Chung
|
7c1d4efeb7
|
Merge branch 'master' into plugins_dev
|
2020-08-20 16:54:00 +08:00 |
|
Stephen Chung
|
ac6d519d28
|
Fix bug that consumes first argument in module-qualified call.
|
2020-08-20 16:26:10 +08:00 |
|
Stephen Chung
|
980aba77a9
|
Use &mut.
|
2020-08-19 12:53:33 +08:00 |
|
Stephen Chung
|
c55b0d7883
|
Fix bug with plugin method call detection.
|
2020-08-19 12:50:23 +08:00 |
|
Stephen Chung
|
6a3e123306
|
Use split_first_mut instead of split_at_mut.
|
2020-08-18 23:19:26 +08:00 |
|
Stephen Chung
|
c5360db185
|
Handle #{ in Engine::parse_json, restrict to object hashes only.
|
2020-08-18 23:07:17 +08:00 |
|
Stephen Chung
|
d024f912e0
|
Merge branch 'master' into plugins_dev
|
2020-08-18 22:02:44 +08:00 |
|
Stephen Chung
|
e3f2157c6a
|
Treat leading #{ in Engine::parse_json.
|
2020-08-18 22:01:13 +08:00 |
|
Stephen Chung
|
09b75ed1a3
|
Fix bug in strings package.
|
2020-08-17 10:00:50 +08:00 |
|
Stephen Chung
|
810514dd31
|
Add get/set/index_get/index_set parameters to rhai_fn.
|
2020-08-17 00:13:52 +08:00 |
|
Stephen Chung
|
e75d91e9bf
|
Bring more functions into modules in plugins via rhai_fn(name) attribute.
|
2020-08-16 23:41:59 +08:00 |
|
Stephen Chung
|
db9d8b81cf
|
Move BasicStringsPackage to plugins.
|
2020-08-15 12:57:47 +08:00 |
|
J Henry Waugh
|
e4045256fe
|
Fix type resolution issue with no_float enabled
|
2020-08-14 19:39:28 -05:00 |
|
J Henry Waugh
|
89de2fe6b2
|
Feature gate make_getter imports
|
2020-08-14 19:37:34 -05:00 |
|
J Henry Waugh
|
eabf9db263
|
Add missing num_traits import
|
2020-08-14 19:37:25 -05:00 |
|
J Henry Waugh
|
7fcbfcc7fd
|
codegen: explicit import of format! macro
|
2020-08-14 19:37:25 -05:00 |
|
J Henry Waugh
|
1051a3f108
|
Add missing import of String and ToString
|
2020-08-14 19:37:25 -05:00 |
|
J Henry Waugh
|
e6a1b88b4c
|
Fully feature gate array string functions
|
2020-08-14 19:37:25 -05:00 |
|
J Henry Waugh
|
4de02c2bd7
|
Remove extra import
|
2020-08-14 16:30:00 -05:00 |
|
Stephen Chung
|
489b1ca00e
|
Add Module::combine.
|
2020-08-15 00:08:00 +08:00 |
|
Stephen Chung
|
209d1a174c
|
Yet more packages into plugins.
|
2020-08-15 00:04:10 +08:00 |
|
Stephen Chung
|
ceb1a26733
|
Move more packages to plugins.
|
2020-08-14 18:58:34 +08:00 |
|
Stephen Chung
|
c0dc47c9db
|
Convert some packages into plugins.
|
2020-08-14 13:43:26 +08:00 |
|
Stephen Chung
|
2495b367e5
|
Merge branch 'plugins' of https://github.com/schungx/rhai into plugins
|
2020-08-14 13:40:33 +08:00 |
|
J Henry Waugh
|
b27ebb318d
|
Rearrange imports to support no_std
|
2020-08-13 23:04:30 -05:00 |
|
Stephen Chung
|
d2ea981fac
|
Merge branch 'master' into plugins
|
2020-08-14 11:45:52 +08:00 |
|
Stephen Chung
|
b956639c2a
|
Move some math functions into plugins.
|
2020-08-13 14:57:46 +08:00 |
|
J Henry Waugh
|
fdcaa90cd9
|
Clean up plugin module for no_module macro support
|
2020-08-12 23:57:57 -05:00 |
|
J Henry Waugh
|
28572544d8
|
Split register export macro, add Engine support
|
2020-08-12 23:36:35 -05:00 |
|
J Henry Waugh
|
59e3ca0e79
|
Remove Dynamic::downcast_clone
|
2020-08-11 19:09:49 -05:00 |
|
Stephen Chung
|
a5b4d61dff
|
Fix docs.
|
2020-08-11 13:46:09 +08:00 |
|
Stephen Chung
|
564d3bc339
|
Add more closure tests.
|
2020-08-09 22:12:50 +08:00 |
|
Ilya Lakhin
|
39ee74112c
|
no-closure feature issue fixed
|
2020-08-09 18:42:33 +07:00 |
|
Ilya Lakhin
|
20cff87e14
|
False-positive capturing prevention bug fix
|
2020-08-09 18:35:29 +07:00 |
|
Stephen Chung
|
0e344ff3eb
|
Merge branch 'master' into plugins
|
2020-08-08 23:01:48 +08:00 |
|
Stephen Chung
|
da3cce58d3
|
Minor refactor.
|
2020-08-08 22:59:05 +08:00 |
|
Stephen Chung
|
e66873bb83
|
Merge pull request #27 from Eliah-Lakhin/capturing-bug
Function names capturing as external variables bug
|
2020-08-08 22:52:20 +08:00 |
|
Ilya Lakhin
|
45d021c7ef
|
Function names capturing as external variables bug
|
2020-08-08 17:55:58 +07:00 |
|
Stephen Chung
|
f68c5a699d
|
Fix sync feature.
|
2020-08-08 17:04:21 +08:00 |
|
Stephen Chung
|
fbad20eb0d
|
Merge branch 'master' into plugins
|
2020-08-08 16:26:52 +08:00 |
|
Stephen Chung
|
5a1a141ce3
|
Improve shared value treatment.
|
2020-08-08 16:24:10 +08:00 |
|
Stephen Chung
|
7b258ac410
|
Add more inlining.
|
2020-08-08 11:46:30 +08:00 |
|
Stephen Chung
|
5e6d5e8e80
|
Expand getter/setter/indexer API.
|
2020-08-07 11:10:38 +08:00 |
|
J Henry Waugh
|
75bcbb74eb
|
Fix unrelated CI failure for features
|
2020-08-06 19:41:19 -05:00 |
|
J Henry Waugh
|
be315aebaf
|
Fix breakage due to write_lock()
|
2020-08-06 18:36:19 -05:00 |
|
Stephen Chung
|
6475e4e20e
|
Merge branch 'master' into plugins
|
2020-08-06 23:17:20 +08:00 |
|
Stephen Chung
|
b604ea3e93
|
Fix serde doc test.
|
2020-08-06 22:47:10 +08:00 |
|
Stephen Chung
|
130bcfe293
|
Fix serde.
|
2020-08-06 21:19:54 +08:00 |
|
Stephen Chung
|
4465a44673
|
Fix typos.
|
2020-08-06 10:31:32 +08:00 |
|
Stephen Chung
|
26c5b10ef7
|
Merge branch 'master' into plugins
|
2020-08-06 10:31:15 +08:00 |
|
Stephen Chung
|
2f395492de
|
Simply error code.
|
2020-08-06 10:17:32 +08:00 |
|
Stephen Chung
|
ffe52bf437
|
Allow omitting the alias in import statement.
|
2020-08-05 23:23:53 +08:00 |
|
Stephen Chung
|
ae11dbbefe
|
Fix feature flags.
|
2020-08-05 22:53:01 +08:00 |
|
Stephen Chung
|
5ea08d2b50
|
Bump version.
|
2020-08-05 17:55:36 +08:00 |
|
Stephen Chung
|
8a0d0e3e20
|
Unbox error return for Engine::register_custom_syntax.
|
2020-08-05 10:00:20 +08:00 |
|
Stephen Chung
|
9f302d4ef5
|
Update docs and tests.
|
2020-08-04 18:39:24 +08:00 |
|
Stephen Chung
|
b0ab6e95f5
|
Fix currying in map closure calls.
|
2020-08-04 18:38:33 +08:00 |
|
Stephen Chung
|
24346b9728
|
Merge branch 'master' into plugins
|
2020-08-04 16:51:22 +08:00 |
|
Stephen Chung
|
4878a69503
|
Add docs for closures.
|
2020-08-04 16:27:55 +08:00 |
|
Stephen Chung
|
3d6c83c6d8
|
Fix serde builds.
|
2020-08-04 09:47:48 +08:00 |
|
Stephen Chung
|
4a7bf893e6
|
Refine flatten clone for scope.
|
2020-08-03 23:13:09 +08:00 |
|
Stephen Chung
|
2aa08c0dd9
|
get_constant_value for FnPointer.
|
2020-08-03 23:12:42 +08:00 |
|
Stephen Chung
|
3b6d35368f
|
Handle shared for loop variable.
|
2020-08-03 23:11:38 +08:00 |
|
Stephen Chung
|
abe74e7f44
|
Handle Dynamic::from(FnPtr).
|
2020-08-03 23:11:24 +08:00 |
|
Stephen Chung
|
e1a70fe958
|
Add FnPtr to standard packages.
|
2020-08-03 23:11:08 +08:00 |
|
Stephen Chung
|
3fc35c4f87
|
Merge from master.
|
2020-08-03 13:28:29 +08:00 |
|
Stephen Chung
|
dddd8133df
|
Set unshared value in let/const statement.
|
2020-08-03 12:38:56 +08:00 |
|
Stephen Chung
|
4079164bfd
|
Implement closures.
|
2020-08-03 12:10:20 +08:00 |
|
J Henry Waugh
|
3136188801
|
Improve proc macro hygiene
|
2020-08-02 19:27:35 -05:00 |
|
Stephen Chung
|
096eb4493e
|
Engine::load_package API change.
|
2020-08-02 18:55:22 +08:00 |
|
Stephen Chung
|
5eed5fe6a3
|
Add plugins test.
|
2020-08-02 18:53:25 +08:00 |
|
Stephen Chung
|
747c0345f2
|
Do not convert a function call into a method call if the object is shared.
|
2020-08-02 13:51:07 +08:00 |
|
Stephen Chung
|
b86c87253b
|
Prevent data races.
|
2020-08-02 13:33:51 +08:00 |
|
J Henry Waugh
|
d01203cb5d
|
New Procedural Macros Crate v0.1
|
2020-08-01 11:52:32 -05:00 |
|
Stephen Chung
|
1daf91df30
|
Avoid storing shared value inside shared value.
|
2020-08-01 22:28:17 +08:00 |
|
Stephen Chung
|
cc53b21731
|
Avoid hard-coding variable type for shared.
|
2020-08-01 22:28:13 +08:00 |
|
Stephen Chung
|
af2f8acb5d
|
Refine indexer set.
|
2020-08-01 12:21:15 +08:00 |
|
Stephen Chung
|
a2858e0fd3
|
Refine feature gates
|
2020-08-01 12:19:27 +08:00 |
|
Stephen Chung
|
5873bccd50
|
Fix no_index and no_object.
|
2020-07-31 23:37:30 +08:00 |
|
Stephen Chung
|
60891e694f
|
Streamline code and feature gates.
|
2020-07-31 22:30:23 +08:00 |
|
Stephen Chung
|
8d0623d07f
|
Add is_shared function.
|
2020-07-31 18:43:34 +08:00 |
|
Stephen Chung
|
0295e109ad
|
Fix features
|
2020-07-31 18:06:01 +08:00 |
|
Stephen Chung
|
d563b878aa
|
Fix no_std builds.
|
2020-07-31 17:26:49 +08:00 |
|
Stephen Chung
|
df8587ac91
|
Make sure both shared and take can be called in both styles.
|
2020-07-31 17:06:40 +08:00 |
|
Stephen Chung
|
e70e0ff4e2
|
Fixup.
|
2020-07-31 16:39:38 +08:00 |
|
Stephen Chung
|
871fcb38be
|
Minor style changes and make sure no_shared works on all.
|
2020-07-31 16:03:08 +08:00 |
|
Ilya Lakhin
|
5d1f5cc2b4
|
Dynamic::read renamed to Dynamic::clone_inner_data
|
2020-07-31 13:10:05 +07:00 |
|
Ilya Lakhin
|
89f75bbf0c
|
Merge remote-tracking branch 'schungx/closures' into closures
|
2020-07-31 13:05:16 +07:00 |
|
Ilya Lakhin
|
4f771d904a
|
Code cleanup
|
2020-07-31 12:09:32 +07:00 |
|
Ilya Lakhin
|
ca64668e58
|
take() keyword; shared test with registered functions with callbacks
|
2020-07-31 11:41:22 +07:00 |
|
Stephen Chung
|
49392d57d7
|
Fix no_std feature.
|
2020-07-31 12:40:16 +08:00 |
|
Stephen Chung
|
cb005506e2
|
Simplify function calling.
|
2020-07-31 12:11:16 +08:00 |
|
Ilya Lakhin
|
060dd33046
|
Shared Dynamic tests and fixes in Engine; Also fixed a bug in Parser variable capturing
|
2020-07-31 10:47:22 +07:00 |
|
Ilya Lakhin
|
aa87a7f5ef
|
Fixes in Engine to properly interpret Shared Dynamic
|
2020-07-31 10:47:22 +07:00 |
|
Ilya Lakhin
|
e5fe222de3
|
Shared variant of Dynamic type; All read/write access operations in Dynamic backed by Read/Write lock guards; new shared() script function
|
2020-07-31 10:47:14 +07:00 |
|
Stephen Chung
|
a7ff207636
|
Use Scope::flatten_clone for capturing.
|
2020-07-30 23:29:30 +08:00 |
|
Stephen Chung
|
7d4620d0d9
|
Unbounded -> unbound.
|
2020-07-30 23:29:11 +08:00 |
|
Stephen Chung
|
98b294c699
|
Implement capturing.
|
2020-07-30 18:18:28 +08:00 |
|
Stephen Chung
|
e505a06839
|
Add comparison operators to ImmutableString.
|
2020-07-30 13:28:25 +08:00 |
|
Stephen Chung
|
691e04292f
|
Put externals in ScriptFnDef.
|
2020-07-30 13:28:06 +08:00 |
|
J Henry Waugh
|
5785fa6b74
|
Fix Plugins API for no_std
|
2020-07-29 16:57:13 -05:00 |
|
Stephen Chung
|
6e663eecb4
|
Fix fn_call.
|
2020-07-29 23:39:32 +08:00 |
|
Stephen Chung
|
d63f926701
|
Merge branch 'master' into plugins
|
2020-07-29 23:37:51 +08:00 |
|
Stephen Chung
|
721c578407
|
Use HashMap for externals.
|
2020-07-29 23:34:48 +08:00 |
|
Stephen Chung
|
1465ba2315
|
Refactor auto-currying.
|
2020-07-29 22:43:50 +08:00 |
|
Stephen Chung
|
a5a3bbd399
|
Merge pull request #19 from Eliah-Lakhin/closures
Autocurry feature
|
2020-07-29 21:24:43 +08:00 |
|
Ilya Lakhin
|
8fc16b40e6
|
Code style issues fixed
|
2020-07-29 20:17:18 +07:00 |
|
Ilya Lakhin
|
a856a8bbcb
|
max_expr_depth bug fix
|
2020-07-29 19:04:33 +07:00 |
|
Ilya Lakhin
|
48356abc83
|
Autocurry fixes and test
|
2020-07-29 18:52:54 +07:00 |
|
Ilya Lakhin
|
8e51988b66
|
A prototype of a new feature to automatically curry of external scope variables
|
2020-07-29 16:56:32 +07:00 |
|
Stephen Chung
|
afbcd0fc0b
|
Replace StaticVec with SmallVec.
|
2020-07-29 16:10:06 +08:00 |
|
Stephen Chung
|
4510d3a659
|
Merge branch 'master' into plugins
|
2020-07-29 14:17:40 +08:00 |
|
Stephen Chung
|
e2daba55d7
|
Refine unicode-xid-ident feature writeup.
|
2020-07-29 13:57:17 +08:00 |
|
Stephen Chung
|
eeb86f5efb
|
Merge branch 'master' of https://github.com/jonathandturner/rhai
|
2020-07-29 11:43:48 +08:00 |
|
ekicyou
|
288e0a4d14
|
add unicode_xid, test
|
2020-07-29 08:25:37 +09:00 |
|
ekicyou
|
9b0375b870
|
add unicode-xid
|
2020-07-29 07:03:21 +09:00 |
|
ekicyou
|
79022b1858
|
refactoring
|
2020-07-29 06:54:23 +09:00 |
|
ekicyou
|
c6d5bd000d
|
move is_valid_identifier
|
2020-07-29 06:24:41 +09:00 |
|
ekicyou
|
56a8120d75
|
add get_identifier
|
2020-07-29 05:26:57 +09:00 |
|
Stephen Chung
|
411539f3be
|
Minimize usage of downcast_ref.
|
2020-07-28 19:11:46 +08:00 |
|
Stephen Chung
|
37ea24afe9
|
Improve docs.
|
2020-07-28 19:11:37 +08:00 |
|
Stephen Chung
|
0c703c0361
|
Merge branch 'master' into plugins
|
2020-07-28 11:08:57 +08:00 |
|
Stephen Chung
|
b63ff56e09
|
Make sure we keep the starting position of each statement (for future uses).
|
2020-07-28 10:26:20 +08:00 |
|
Stephen Chung
|
b70fd35f4a
|
Revise docs.
|
2020-07-28 10:25:57 +08:00 |
|
Stephen Chung
|
f05cd1fdf3
|
Add shared and sync to reserved keywords.
|
2020-07-28 10:25:26 +08:00 |
|
Stephen Chung
|
057f6435a4
|
Add public_only parameter to module function methods.
|
2020-07-27 18:10:45 +08:00 |
|
Stephen Chung
|
a3a167424b
|
Allow Rust functions in FnPtr::call_dynamic.
|
2020-07-27 12:52:32 +08:00 |
|
Stephen Chung
|
4bda306815
|
Merge branch 'master' into plugins
|
2020-07-26 22:38:35 +08:00 |
|
Stephen Chung
|
2dd4d9bcf9
|
Avoid warnings with only_i32.
|
2020-07-26 22:37:33 +08:00 |
|
Stephen Chung
|
ec5082c328
|
Better handling of reserved keywords.
|
2020-07-26 22:25:30 +08:00 |
|
Stephen Chung
|
ce20248792
|
Add more reserved keywords.
|
2020-07-26 21:57:30 +08:00 |
|
Stephen Chung
|
878ba0b794
|
Remove register_raw_fn_XXX API's.
|
2020-07-26 18:17:55 +08:00 |
|
Stephen Chung
|
3d36a25c90
|
Add back PluginFunction.
|
2020-07-26 16:10:38 +08:00 |
|
Stephen Chung
|
4691f7860c
|
Merge branch 'master' into plugins
|
2020-07-26 16:09:27 +08:00 |
|
Stephen Chung
|
6b600704a3
|
Avoid warnings.
|
2020-07-26 15:53:22 +08:00 |
|
Stephen Chung
|
25ee4b4f82
|
Merge branch 'master' into plugins
|
2020-07-26 14:07:29 +08:00 |
|
Stephen Chung
|
e7af008d74
|
Avoid warnings.
|
2020-07-26 13:51:09 +08:00 |
|
Stephen Chung
|
8e33cbfe34
|
Merge branch 'master' into plugins
|
2020-07-26 10:05:56 +08:00 |
|
Stephen Chung
|
353df6bea1
|
Avoid warnings in standard build.
|
2020-07-26 10:03:59 +08:00 |
|
Stephen Chung
|
d278f3725c
|
Merge branch 'master' into plugins
|
2020-07-25 16:16:09 +08:00 |
|
Stephen Chung
|
9d900a6722
|
Remove _Private.
|
2020-07-25 16:09:13 +08:00 |
|
Stephen Chung
|
94c2f64473
|
Merge branch 'master' of https://github.com/jonathandturner/rhai
|
2020-07-25 16:05:11 +08:00 |
|
Stephen Chung
|
c825de6f77
|
Mark internal data structures with [INTERNALS].
|
2020-07-25 16:05:08 +08:00 |
|
Stephen Chung
|
22169582bb
|
Merge pull request #196 from udoprog/tokenize-numeric-literal
Avoid scanning over slices to validate numerical literals
|
2020-07-25 16:03:17 +08:00 |
|
Stephen Chung
|
6a96be3382
|
Merge branch 'master' of https://github.com/jonathandturner/rhai
|
2020-07-25 15:58:37 +08:00 |
|
John-John Tedro
|
1aab77df1c
|
Avoid scanning over slices to validate numerical literals
|
2020-07-25 09:52:54 +02:00 |
|
Stephen Chung
|
284e58e8a1
|
Improve documentation on internal types.
|
2020-07-25 15:52:27 +08:00 |
|
Stephen Chung
|
252b6cb8f3
|
Merge pull request #197 from udoprog/seal-variant
Seal Variant trait to prevent downstream implementations
|
2020-07-25 15:50:51 +08:00 |
|
Stephen Chung
|
8109e26538
|
Merge pull request #198 from udoprog/unbreak-no-std
Unbreak no std
|
2020-07-25 15:39:25 +08:00 |
|
John-John Tedro
|
261273bac3
|
Unbreak no_std
|
2020-07-25 09:21:30 +02:00 |
|
John-John Tedro
|
e7aaec8e3a
|
Seal Variant trait to prevent downstream implementations
|
2020-07-25 09:20:19 +02:00 |
|
John-John Tedro
|
d920613d57
|
Avoid shadowing call errors in get_indexed_mut
|
2020-07-25 08:13:11 +02:00 |
|
Stephen Chung
|
a58207aaa9
|
Change ScriptFnDef to use ImmutableString.
|
2020-07-25 14:06:13 +08:00 |
|
Stephen Chung
|
463d669ab5
|
Avoid shadowing indexer errors.
|
2020-07-25 09:55:33 +08:00 |
|
Stephen Chung
|
af41850da0
|
Merge branch 'master' of https://github.com/jonathandturner/rhai
|
2020-07-25 09:39:31 +08:00 |
|
John-John Tedro
|
ea22591e36
|
Support u128/i128 types during serialization
|
2020-07-24 19:08:59 +02:00 |
|
Stephen Chung
|
2b0aacde23
|
Fix Module::set_indexer_set_fn.
|
2020-07-24 23:16:54 +08:00 |
|
John-John Tedro
|
96aa5ed39e
|
set_indexer_set_fn to support setting generic value
|
2020-07-24 16:20:47 +02:00 |
|
Stephen Chung
|
1c58bdb2a1
|
Merge branch 'master' into plugins
|
2020-07-23 18:46:25 +08:00 |
|
Stephen Chung
|
bff266d4e1
|
Move function calling to separate source file.
|
2020-07-23 18:40:42 +08:00 |
|
Stephen Chung
|
a2ddd2175e
|
Merge branch 'master' into plugins
|
2020-07-23 16:12:09 +08:00 |
|
Stephen Chung
|
1a48a2d8ba
|
Refine currying docs.
|
2020-07-23 15:49:09 +08:00 |
|
Stephen Chung
|
dc7f847a8e
|
Merge branch 'master' of https://github.com/schungx/rhai
|
2020-07-23 10:13:10 +08:00 |
|
Stephen Chung
|
b913b521dc
|
Improve currying.
|
2020-07-23 10:12:51 +08:00 |
|
Ilya Lakhin
|
82685b7df2
|
FnPtr::call_dynamic shortcut function that enriches call arguments with curry-ed data automatically
|
2020-07-23 04:53:40 +07:00 |
|
Stephen Chung
|
6d551f1596
|
Add currying support.
|
2020-07-22 23:12:09 +08:00 |
|
Stephen Chung
|
e103c8e66c
|
Refine string docs.
|
2020-07-22 21:32:56 +08:00 |
|
Stephen Chung
|
abf66850f6
|
Enable custom syntax without internals.
|
2020-07-22 17:05:13 +08:00 |
|
Stephen Chung
|
d7d9f42802
|
Merge branch 'master' into plugins
|
2020-07-22 13:33:24 +08:00 |
|
Stephen Chung
|
35374f5b3b
|
Simplify custom syntax.
|
2020-07-22 13:08:51 +08:00 |
|
Stephen Chung
|
187824e684
|
Improve inlining of Dynamic methods.
|
2020-07-22 13:05:24 +08:00 |
|
Stephen Chung
|
61a1355c59
|
Add no-std example.
|
2020-07-21 22:32:24 +08:00 |
|
Stephen Chung
|
c36e459feb
|
Merge branch 'master' into plugins
|
2020-07-21 21:09:04 +08:00 |
|
Stephen Chung
|
e6c3f8134d
|
Avoid copying property name for map property access.
|
2020-07-21 20:59:12 +08:00 |
|
Stephen Chung
|
ec3074106e
|
Display type name when printing Dynamic values that have no built-in format.
|
2020-07-21 20:58:53 +08:00 |
|
Stephen Chung
|
e8b6d0143d
|
Small fixups.
|
2020-07-20 23:23:12 +08:00 |
|
Stephen Chung
|
a5fa8322e9
|
Avoid pulling in std for no-std.
|
2020-07-20 20:23:35 +08:00 |
|
Stephen Chung
|
cf36dc5a57
|
Support for anonymous functions.
|
2020-07-19 17:14:55 +08:00 |
|
Stephen Chung
|
2f33edb762
|
FIx no_std.
|
2020-07-19 09:10:22 +08:00 |
|
Stephen Chung
|
3ae7cf4018
|
Improve treatment of disabled symbols and custom symbols.
|
2020-07-17 14:50:23 +08:00 |
|
Stephen Chung
|
a7f564fe37
|
Merge branch 'master' into plugins
|
2020-07-17 11:44:23 +08:00 |
|
Stephen Chung
|
d119e13b79
|
Allow binding of this pointer in FnPtr calls.
|
2020-07-17 10:18:07 +08:00 |
|
Stephen Chung
|
16fbfbb606
|
Enable call in function-call style.
|
2020-07-16 12:09:31 +08:00 |
|
Stephen Chung
|
adc96e24bd
|
Fix all features.
|
2020-07-13 19:38:50 +08:00 |
|
Stephen Chung
|
e8d78bdfde
|
Add support for String in function parameters.
|
2020-07-13 13:40:51 +08:00 |
|
Stephen Chung
|
67f8dcf032
|
Merge branch 'master' into plugins
|
2020-07-12 11:48:55 +08:00 |
|
Stephen Chung
|
8449f8c55e
|
Make API chainable.
|
2020-07-12 11:46:53 +08:00 |
|
Stephen Chung
|
e57c15c3e2
|
Merge branch 'master' into plugins
|
2020-07-11 15:11:20 +08:00 |
|
Stephen Chung
|
2a8d63fd5f
|
Refine custom syntax.
|
2020-07-11 15:09:17 +08:00 |
|
Stephen Chung
|
d95761d064
|
Merge branch 'master' into plugins
|
2020-07-10 22:06:02 +08:00 |
|
Stephen Chung
|
ebffbf0f98
|
Refine docs and add custom syntax.
|
2020-07-10 22:01:47 +08:00 |
|
Stephen Chung
|
7436fc1c05
|
Fix bug in tokenizing reserved symbols.
|
2020-07-10 11:41:56 +08:00 |
|
Stephen Chung
|
f36b4a69ae
|
FIXED - method calls inside dot chain.
|
2020-07-09 22:21:07 +08:00 |
|
Stephen Chung
|
99164ebceb
|
Add custom syntax.
|
2020-07-09 19:54:28 +08:00 |
|
Stephen Chung
|
e33760a7d4
|
Fix bug in StaticVec.
|
2020-07-09 13:27:21 +08:00 |
|
Stephen Chung
|
72c034ccd1
|
Merge branch 'master' into plugins
|
2020-07-08 13:50:15 +08:00 |
|
Stephen Chung
|
703cc414b8
|
Allow mutating a module-qualified function's first argument if it is a variable.
|
2020-07-08 13:06:00 +08:00 |
|
Stephen Chung
|
d92a514f48
|
Add reserved symbols.
|
2020-07-08 12:09:18 +08:00 |
|
Stephen Chung
|
236ba40784
|
Add ModuleResolversCollection.
|
2020-07-07 23:44:23 +08:00 |
|
Stephen Chung
|
ff6d205c1d
|
Make Modules::set_raw_fn public.
|
2020-07-07 22:59:23 +08:00 |
|
Stephen Chung
|
b71d9acdc2
|
Merge branch 'master' into plugins
|
2020-07-06 23:14:44 +08:00 |
|
Stephen Chung
|
2b3f10f2c5
|
Define functions anywhere during parsing.
|
2020-07-06 22:57:50 +08:00 |
|
Stephen Chung
|
3b7a7426cf
|
Merge branch 'master' into plugins
|
2020-07-06 21:52:47 +08:00 |
|
Stephen Chung
|
f5ff759fcc
|
Merge branch 'master' of https://github.com/schungx/rhai
|
2020-07-06 21:31:03 +08:00 |
|
Stephen Chung
|
d0711394f0
|
Expose FnPtr and move name checking into
|
2020-07-06 21:30:35 +08:00 |
|
Alvin Wong
|
4a3a32dc3a
|
Fix serializing externally-tagged enum representations
|
2020-07-06 21:11:41 +08:00 |
|
Alvin Wong
|
0644c67252
|
Impl. deserializing enum representations
|
2020-07-06 18:32:22 +08:00 |
|
Stephen Chung
|
46cdec1280
|
Refine docs and tests.
|
2020-07-06 16:20:03 +08:00 |
|
Alvin Wong
|
8f53ce50d4
|
Ensure rhai::INT can be deserialized into any integer types
|
2020-07-06 15:30:56 +08:00 |
|
Alvin Wong
|
8bc1b25edd
|
Fix only_i32 build
|
2020-07-06 15:30:55 +08:00 |
|
Stephen Chung
|
fbe15d25b6
|
Merge branch 'master' into plugins
|
2020-07-06 13:11:46 +08:00 |
|
Stephen Chung
|
3e45d5d9a5
|
Refine docs and API.
|
2020-07-06 13:01:57 +08:00 |
|
Stephen Chung
|
d9fe6a1980
|
Add boolean xor operator and readjust % precedence.
|
2020-07-06 12:24:28 +08:00 |
|
Stephen Chung
|
05a4b466d1
|
New register_raw_fn_n shortcuts.
|
2020-07-06 12:06:57 +08:00 |
|
Stephen Chung
|
ea86888638
|
Add new &Module parameter to native functions.
|
2020-07-06 12:04:02 +08:00 |
|
Stephen Chung
|
495d202af4
|
Add new AST API.
|
2020-07-06 10:02:54 +08:00 |
|
Stephen Chung
|
a27f89b524
|
Add new register_fn_raw API.
|
2020-07-05 23:08:44 +08:00 |
|
Stephen Chung
|
4052ad3df1
|
Assignments return () and no compound assignments.
|
2020-07-05 23:07:02 +08:00 |
|
Stephen Chung
|
ef2d28d423
|
Merge branch 'master' into plugins
|
2020-07-05 18:12:35 +08:00 |
|
Stephen Chung
|
e390dd73e6
|
Add custom operators.
|
2020-07-05 17:41:45 +08:00 |
|
Stephen Chung
|
936a3ff44a
|
Add feature to disable symbols.
|
2020-07-05 15:23:51 +08:00 |
|
Stephen Chung
|
368b4a480b
|
Reformat code.
|
2020-07-04 22:53:00 +08:00 |
|
Stephen Chung
|
d626bf9f5b
|
Refine no_function feature.
|
2020-07-04 16:21:15 +08:00 |
|
Stephen Chung
|
b3b3a083b8
|
Add docs on serde feature.
|
2020-07-04 15:39:40 +08:00 |
|
Stephen Chung
|
2b2deba5e0
|
Remove serde from default feature.
|
2020-07-03 22:48:33 +08:00 |
|
Stephen Chung
|
78c94daf46
|
Add ser::to_dynamic.
|
2020-07-03 22:42:56 +08:00 |
|
Stephen Chung
|
fa84e5c502
|
Add serde deserialization.
|
2020-07-03 17:19:55 +08:00 |
|
Stephen Chung
|
1b7ffdf408
|
Better type display.
|
2020-07-03 10:45:01 +08:00 |
|
Stephen Chung
|
bdc7b69266
|
Remove feature gate for Instant.
|
2020-07-02 22:16:09 +08:00 |
|
Stephen Chung
|
9c9f550200
|
Minor refactor.
|
2020-07-02 21:46:08 +08:00 |
|
Stephen Chung
|
e14cfbd9d7
|
Restore plugins code.
|
2020-07-02 12:47:24 +08:00 |
|
Stephen Chung
|
760c13d36e
|
Fix features.
|
2020-07-01 22:21:43 +08:00 |
|
Stephen Chung
|
e614790897
|
Enable function pointers even under no_function.
|
2020-06-30 18:34:58 +08:00 |
|
Stephen Chung
|
52ef223f83
|
Fix pad functions.
|
2020-06-30 18:34:32 +08:00 |
|
Stephen Chung
|
d6a08be223
|
Refactor.
|
2020-06-29 23:55:28 +08:00 |
|
Stephen Chung
|
063851a6ad
|
Merge branch 'tokenizer'
|
2020-06-28 15:51:37 +08:00 |
|
Stephen Chung
|
527d41d0e3
|
No modules in scope.
|
2020-06-28 15:49:24 +08:00 |
|
Stephen Chung
|
aac04a5e53
|
Remove modules from Scope and use separate stack.
|
2020-06-27 23:56:24 +08:00 |
|
Stephen Chung
|
549ef6bf7f
|
Add oop.rhai script.
|
2020-06-27 17:34:39 +08:00 |
|
Stephen Chung
|
04d2fb5001
|
Fix no_std.
|
2020-06-26 23:24:47 +08:00 |
|
Stephen Chung
|
ab347fa14e
|
Add Module::iter_script_fn.
|
2020-06-26 22:33:27 +08:00 |
|
Stephen Chung
|
74c82bbd9c
|
Refactor.
|
2020-06-26 22:03:21 +08:00 |
|
Stephen Chung
|
8c632ed928
|
Remove println.
|
2020-06-26 19:54:12 +08:00 |
|
Stephen Chung
|
31eaf321d0
|
Refactor tokenizer.
|
2020-06-26 19:44:50 +08:00 |
|
Stephen Chung
|
175c3ccaec
|
OOP support.
|
2020-06-26 10:39:18 +08:00 |
|
Stephen Chung
|
580a62daaf
|
Add sign function.
|
2020-06-25 19:19:16 +08:00 |
|
Stephen Chung
|
fe640e0e13
|
Implement function pointers.
|
2020-06-25 18:07:57 +08:00 |
|
Stephen Chung
|
58c198776f
|
Code cleanup.
|
2020-06-25 11:07:46 +08:00 |
|
Stephen Chung
|
ab60c2e1d2
|
Add scope command to repl.
|
2020-06-24 22:45:34 +08:00 |
|
Stephen Chung
|
d5eb2887ff
|
Refactor Dynamic.
|
2020-06-23 19:24:26 +08:00 |
|
Stephen Chung
|
3b1719e0bc
|
Introduce ChainType to prepare for more chaining operators.
|
2020-06-23 17:36:07 +08:00 |
|
Stephen Chung
|
54c5c139f9
|
Add internals feature.
|
2020-06-23 10:43:24 +08:00 |
|
Stephen Chung
|
a9b168ba99
|
Refine docs.
|
2020-06-22 22:02:49 +08:00 |
|
Stephen Chung
|
7cc1a3f5dc
|
Change Map keys to ImmutableString to facilitate fast keys().
|
2020-06-21 16:37:05 +08:00 |
|
Stephen Chung
|
ffe0c559be
|
Remove scope parameter from ModuleResolver::resolve.
|
2020-06-20 21:49:45 +08:00 |
|
Stephen Chung
|
478bc7ab30
|
Change README to point to the Rhai book.
|
2020-06-20 12:23:32 +08:00 |
|
Stephen Chung
|
cc57a2344e
|
Fix doc test.
|
2020-06-20 10:49:15 +08:00 |
|
Stephen Chung
|
35fa61cd4b
|
Do not export fn_native.
|
2020-06-18 18:39:28 +08:00 |
|
Stephen Chung
|
2a73841549
|
Add support for Instant for wasm32.
|
2020-06-17 16:50:57 +08:00 |
|
Stephen Chung
|
ae6d5e13a9
|
Gate i128/u128 for wasm32 target.
|
2020-06-17 16:50:46 +08:00 |
|
Stephen Chung
|
e095a87ea2
|
Remove wasm64 target.
|
2020-06-17 16:49:51 +08:00 |
|
Stephen Chung
|
84fbcb03b3
|
Add WASM section.
|
2020-06-17 15:45:11 +08:00 |
|
Stephen Chung
|
7f4f737ff2
|
Gate WASM target.
|
2020-06-17 09:54:17 +08:00 |
|
Stephen Chung
|
b6e1f652b6
|
Fix bug when setting character in string via a method call.
|
2020-06-16 23:49:11 +08:00 |
|
Stephen Chung
|
151cd1af48
|
Support compiling to WASM.
|
2020-06-16 23:47:31 +08:00 |
|
Stephen Chung
|
1adf3cc39a
|
Support for trailing commas.
|
2020-06-16 22:14:46 +08:00 |
|
Stephen Chung
|
dc540755e7
|
Revert plugins.
|
2020-06-16 09:40:31 +08:00 |
|
Stephen Chung
|
29044cc305
|
Merge branch 'plugins'
|
2020-06-16 09:36:47 +08:00 |
|
Stephen Chung
|
ff37e02443
|
Add iterator support for strings.
|
2020-06-16 09:34:30 +08:00 |
|
Stephen Chung
|
4603f8026f
|
Add getters for Engine setting fields.
|
2020-06-15 23:20:50 +08:00 |
|
Stephen Chung
|
fcb5059570
|
Do not check for data oversize when unchecked.
|
2020-06-15 22:04:14 +08:00 |
|
Stephen Chung
|
9bd2d4c981
|
Merge branch 'master' into plugins
|
2020-06-15 21:52:15 +08:00 |
|
Stephen Chung
|
a417bdd8e3
|
Support registering functions with a reference to the scripting engine.
|
2020-06-15 21:49:02 +08:00 |
|
Stephen Chung
|
31d2fa410b
|
Streamline code.
|
2020-06-14 22:44:59 +08:00 |
|
Stephen Chung
|
f26c12b8ea
|
Better error messages for unrecognized tokens.
|
2020-06-14 19:13:11 +08:00 |
|
Stephen Chung
|
0c6a939c66
|
Better convert LexError to ParseError.
|
2020-06-14 16:56:36 +08:00 |
|
Stephen Chung
|
bb691a0313
|
Add maximum data size limits.
|
2020-06-14 14:25:47 +08:00 |
|
Stephen Chung
|
27ad7bbebe
|
Merge branch 'master' into plugins
|
2020-06-14 00:14:52 +08:00 |
|
Stephen Chung
|
22d30c95c9
|
Add maximum data size limits.
|
2020-06-14 00:09:16 +08:00 |
|
Stephen Chung
|
f004575590
|
Fix namespace error in no_std.
|
2020-06-13 17:03:49 +08:00 |
|
Stephen Chung
|
b24fdd7a4d
|
Change call_fn_dynamic to accept any type that is IntoIterator<Item=Dynamic>.
|
2020-06-12 19:54:55 +08:00 |
|
Stephen Chung
|
96e5a1c56d
|
Merge branch 'master' into plugins
|
2020-06-12 18:04:30 +08:00 |
|
Stephen Chung
|
9d91349513
|
Refine position display in error messages.
|
2020-06-12 18:04:16 +08:00 |
|
Stephen Chung
|
6cc27eb9f4
|
Better error messages.
|
2020-06-11 23:21:39 +08:00 |
|
Stephen Chung
|
d92613eaf6
|
Fix parse positions.
|
2020-06-11 23:08:00 +08:00 |
|
Stephen Chung
|
d03f6ed983
|
Merge branch 'master' into plugins
|
2020-06-11 22:45:20 +08:00 |
|
Stephen Chung
|
e4cca7620f
|
Better debug formatting for StaticVec.
|
2020-06-11 22:18:30 +08:00 |
|
Stephen Chung
|
8f55a15ab0
|
Collect parse settings into struct type.
|
2020-06-11 22:03:47 +08:00 |
|
Stephen Chung
|
0ac3a7d8b4
|
Use type alias TokenStream.
|
2020-06-11 18:13:33 +08:00 |
|
Stephen Chung
|
95f94a3348
|
Add strings example.
|
2020-06-09 12:21:21 +08:00 |
|
Stephen Chung
|
b4b835f80a
|
Remove unnecessary "sync" feature gates.
|
2020-06-08 14:10:16 +08:00 |
|
Stephen Chung
|
a4cabc1ac7
|
Better String parameter error message.
|
2020-06-08 14:10:06 +08:00 |
|
Stephen Chung
|
d4ebb3c96d
|
Merge branch 'master' into plugins
|
2020-06-08 10:26:51 +08:00 |
|
Stephen Chung
|
ead366aac8
|
Better String parameter error message.
|
2020-06-08 10:26:32 +08:00 |
|
Stephen Chung
|
5fb4b04cb0
|
Put type on transmute call.
|
2020-06-08 10:26:12 +08:00 |
|
Stephen Chung
|
e942ef358c
|
Transparently convert &str to ImmutableString for register_fn.
|
2020-06-07 17:54:33 +08:00 |
|
Stephen Chung
|
6841beb351
|
Merge branch 'master' into plugins
|
2020-06-06 13:25:46 +08:00 |
|
Stephen Chung
|
5f40a1376a
|
Implement index setters.
|
2020-06-06 13:06:00 +08:00 |
|
Stephen Chung
|
ea806ba100
|
Merge branch 'master' into plugins
|
2020-06-05 15:39:44 +08:00 |
|
Stephen Chung
|
56eb659d5a
|
Unify all functions into CallableFunction type, remove FunctionsLib.
|
2020-06-05 15:14:42 +08:00 |
|
Stephen Chung
|
1442cc9b7a
|
Merge branch 'master' into plugins
|
2020-06-03 11:15:55 +08:00 |
|
Stephen Chung
|
ec6e3daabb
|
Refactor.
|
2020-06-03 10:44:36 +08:00 |
|
jhwgh1968
|
27b8f9929d
|
Basic Implementation of Plugins and Plugin Functions
|
2020-06-02 21:44:28 -05:00 |
|
Stephen Chung
|
b8da1691d3
|
Consolidate callbacks.
|
2020-06-02 13:33:16 +08:00 |
|
Stephen Chung
|
b70d38e820
|
Avoid passing position until error.
|
2020-06-01 15:25:22 +08:00 |
|
Stephen Chung
|
a5d8ce2e49
|
Merge branch 'master' into plugins
|
2020-06-01 14:14:47 +08:00 |
|
Stephen Chung
|
b8b12055b9
|
Disable if-expression when parsing expressions.
|
2020-06-01 13:26:20 +08:00 |
|
Stephen Chung
|
6d190096fd
|
Fix bug with bracket postfix when no_index.
|
2020-06-01 13:03:01 +08:00 |
|
Stephen Chung
|
8e876b0b86
|
Merge branch 'master' into plugins
|
2020-06-01 10:58:26 +08:00 |
|
Stephen Chung
|
cec6748ac6
|
Remove no_module gates to prepare for plugins.
|
2020-06-01 10:58:14 +08:00 |
|
Stephen Chung
|
c6e5f672c9
|
More benchmarks and examples.
|
2020-05-31 23:44:49 +08:00 |
|
Stephen Chung
|
840afe74bb
|
Simplify eval_dot_index_chain.
|
2020-05-31 15:51:26 +08:00 |
|
Stephen Chung
|
d7d49a5196
|
Fix bug in chained dot/index expression.
|
2020-05-31 14:27:16 +08:00 |
|
Stephen Chung
|
76d792011f
|
Add Engine::call_fn_dynamic.
|
2020-05-31 12:37:19 +08:00 |
|
Stephen Chung
|
5f727335a6
|
Add type info.
|
2020-05-31 12:36:42 +08:00 |
|
Stephen Chung
|
13c49387ef
|
Add OptimizationLevel::is_simple
|
2020-05-31 12:36:31 +08:00 |
|
Stephen Chung
|
c9de37e8d1
|
Hash functions only once via custom hasher.
|
2020-05-31 00:02:23 +08:00 |
|
Stephen Chung
|
6924b62939
|
Merge branch 'master' into plugins
|
2020-05-30 13:51:54 +08:00 |
|
Stephen Chung
|
acd0f6b56b
|
!= defaults to true for different parameter types.
|
2020-05-30 13:49:40 +08:00 |
|
Stephen Chung
|
4c46c7e26b
|
Register property versions of some methods.
|
2020-05-30 10:30:21 +08:00 |
|
Stephen Chung
|
666a618e40
|
Add register getter/setter/indexer to modules.
|
2020-05-30 10:28:17 +08:00 |
|
Stephen Chung
|
2bcc51cc45
|
Fix bug in index expressions.
|
2020-05-30 10:27:48 +08:00 |
|
Stephen Chung
|
e1242df5c8
|
Extract copy/restore of first argument in method call.
|
2020-05-29 18:15:58 +08:00 |
|
Stephen Chung
|
9616452c00
|
Fix bug in calling script function in method style.
|
2020-05-29 00:53:30 +08:00 |
|
Stephen Chung
|
acd4685145
|
Convert function calls to method calls to use &mut first argument.
|
2020-05-28 23:57:09 +08:00 |
|
Stephen Chung
|
a9a95b3c2d
|
Merge branch 'master' into plugins
|
2020-05-28 14:09:27 +08:00 |
|
Stephen Chung
|
e84d4a88e9
|
Do not check function call depth if no_function.
|
2020-05-28 14:08:07 +08:00 |
|
Stephen Chung
|
30782212e4
|
Add set_fn_4/mut for modules.
|
2020-05-28 14:07:34 +08:00 |
|
Stephen Chung
|
0b259d0062
|
Move += for ImmutableString to Engine.
|
2020-05-28 10:33:28 +08:00 |
|
Stephen Chung
|
854634afa0
|
Allow native overriding implementation of assignment operators.
|
2020-05-27 13:22:10 +08:00 |
|
Stephen Chung
|
24a93ef824
|
Add missing imports.
|
2020-05-26 23:05:44 +08:00 |
|
Stephen Chung
|
27c7cc4af7
|
Fix syntax error.
|
2020-05-26 23:05:21 +08:00 |
|
Stephen Chung
|
b34d5fe3a1
|
Complete ImmutableString.
|
2020-05-26 14:14:03 +08:00 |
|
Stephen Chung
|
95e67c48bd
|
Optimize op-assignment statement.
|
2020-05-25 20:14:31 +08:00 |
|
Stephen Chung
|
fca140ef55
|
Refine immutable strings.
|
2020-05-25 17:01:39 +08:00 |
|
Stephen Chung
|
99ea2b33c9
|
Use immutable strings.
|
2020-05-25 13:44:28 +08:00 |
|
Stephen Chung
|
bbed4c6ef4
|
Docs.
|
2020-05-24 23:42:40 +08:00 |
|
Stephen Chung
|
fd6dad0253
|
Remove builtin check.
|
2020-05-24 23:42:16 +08:00 |
|
Stephen Chung
|
0374311cf6
|
Optimize hot path of operators calling.
|
2020-05-24 16:40:00 +08:00 |
|
Stephen Chung
|
1798d4d6a0
|
Fix function call optimizations.
|
2020-05-24 11:57:46 +08:00 |
|
Stephen Chung
|
d56634cac7
|
Complete built-in operators.
|
2020-05-24 00:29:06 +08:00 |
|
Stephen Chung
|
b49e1e199a
|
Build-in certain common operators.
|
2020-05-23 18:59:28 +08:00 |
|
Stephen Chung
|
a743c47345
|
Refactor.
|
2020-05-22 21:50:24 +08:00 |
|
Stephen Chung
|
8d12dc2fc1
|
Add Dynamic::as_float.
|
2020-05-22 21:49:53 +08:00 |
|
Stephen Chung
|
e224550861
|
Move boxing of ParseError into ParseErrorType.
|
2020-05-22 18:28:13 +08:00 |
|
Stephen Chung
|
2f0ab18b70
|
Merge register_result_fn and register_dynamic_fn.
|
2020-05-22 13:09:17 +08:00 |
|
Stephen Chung
|
3408086240
|
Copy values differently.
|
2020-05-22 13:08:57 +08:00 |
|
Stephen Chung
|
800a7bf283
|
Remove unnecessary traits and types.
|
2020-05-21 17:11:01 +08:00 |
|
Stephen Chung
|
cd570558c3
|
Remove count_args macro.
|
2020-05-21 09:31:31 +08:00 |
|
Stephen Chung
|
39cd1c8413
|
Merge branch 'master' into plugins
|
2020-05-21 09:30:03 +08:00 |
|
Stephen Chung
|
80fcc40710
|
Use function pointers for iterators.
|
2020-05-20 19:27:23 +08:00 |
|
Stephen Chung
|
c98633dd2b
|
Add EvalPackage.
|
2020-05-20 11:12:22 +08:00 |
|
Stephen Chung
|
5db1fd3712
|
Do not optimize eval_expression scripts.
|
2020-05-20 00:06:19 +08:00 |
|
Stephen Chung
|
4a1fd66b9f
|
Reduce Rc/Arc wrapping for functions.
|
2020-05-19 22:25:57 +08:00 |
|
Stephen Chung
|
ab76a69b12
|
Avoid repeating empty TypeId's when calculating hash.
|
2020-05-19 20:07:51 +08:00 |
|
Stephen Chung
|
3295060dba
|
Unify all functions under CallableFunction type.
|
2020-05-19 19:03:06 +08:00 |
|
Stephen Chung
|
a22f338b03
|
Back out NativeCallable trait.
|
2020-05-19 10:13:37 +08:00 |
|
Stephen Chung
|
6b8c6bda42
|
Use u64 for operations counter.
|
2020-05-19 10:08:27 +08:00 |
|
Stephen Chung
|
1824dced69
|
Limit expression/statement nesting depths.
|
2020-05-18 19:32:22 +08:00 |
|
Stephen Chung
|
f4a528a88a
|
Add release notes.
|
2020-05-18 09:36:34 +08:00 |
|
Stephen Chung
|
8b5550eeb6
|
Complete StaticVec implementation.
|
2020-05-17 22:19:49 +08:00 |
|
Stephen Chung
|
a2c50879fe
|
Fix dropping issues with StaticVec and use it everywhere.
|
2020-05-17 00:24:07 +08:00 |
|
Stephen Chung
|
0cb781c1aa
|
Avoid allocation in Target.
|
2020-05-16 11:42:56 +08:00 |
|
Stephen Chung
|
be97047e51
|
Limit modules loading.
|
2020-05-15 21:40:54 +08:00 |
|
Stephen Chung
|
55c97eb649
|
Add progress tracking and operations limit.
|
2020-05-15 11:43:32 +08:00 |
|
Stephen Chung
|
5d5ceb4049
|
Consolidate all unsafe code under one single file.
|
2020-05-14 18:27:22 +08:00 |
|
Stephen Chung
|
5c61827c7c
|
Force-cast local variable names when pushing into scope.
|
2020-05-14 11:21:56 +08:00 |
|
Stephen Chung
|
cabceb7498
|
Better handling of errors during function calls.
|
2020-05-13 21:58:38 +08:00 |
|
Stephen Chung
|
9d8d074940
|
Consistent naming of methods.
|
2020-05-13 20:22:05 +08:00 |
|
Stephen Chung
|
5a02548ebc
|
Allocate packages with higher functions capacity.
|
2020-05-13 19:39:34 +08:00 |
|
Stephen Chung
|
30e5e2f034
|
Use modules to implement packages.
|
2020-05-13 19:21:42 +08:00 |
|
Stephen Chung
|
8e8816cb0c
|
Add compile_scripts_with_scope.
|
2020-05-13 11:57:07 +08:00 |
|
Stephen Chung
|
996a54279c
|
Pre-calculate property getter/setter function names.
|
2020-05-13 10:19:18 +08:00 |
|
Stephen Chung
|
d6fd5416b0
|
Add replace function for characters
|
2020-05-12 23:30:55 +08:00 |
|
Stephen Chung
|
ec67879759
|
Derive more standard traits.
|
2020-05-12 18:48:25 +08:00 |
|
Stephen Chung
|
03c64688ad
|
Fix sync feature.
|
2020-05-12 16:32:22 +08:00 |
|
Stephen Chung
|
2e28967565
|
Fix bug with wrong method call hash.
|
2020-05-12 10:20:29 +08:00 |
|
Stephen Chung
|
33c9be7efc
|
Reformat.
|
2020-05-11 23:48:50 +08:00 |
|
Stephen Chung
|
414f3d3c23
|
Fix bug with calling a pure function method-call style.
|
2020-05-11 18:55:58 +08:00 |
|
Stephen Chung
|
4a8710a4a9
|
Create NativeCallable trait.
|
2020-05-11 13:36:50 +08:00 |
|
Stephen Chung
|
314ec5e4d2
|
Remove checks for number of arguments.
|
2020-05-11 10:29:33 +08:00 |
|
Stephen Chung
|
7ea341833c
|
Merge branch 'master' into plugins
|
2020-05-10 21:59:27 +08:00 |
|
Stephen Chung
|
8aa0e2ceb4
|
Use StaticVec to avoid most allocations with function arguments.
|
2020-05-10 21:25:47 +08:00 |
|
Stephen Chung
|
974512d650
|
Use StaticVec to build arguments list.
|
2020-05-10 16:56:17 +08:00 |
|
Stephen Chung
|
80debbc432
|
Refactor.
|
2020-05-10 00:19:13 +08:00 |
|
Stephen Chung
|
95490adf0b
|
Merge branch 'master' into plugins
|
2020-05-10 00:14:03 +08:00 |
|
Stephen Chung
|
29159b359b
|
Refactor.
|
2020-05-10 00:13:49 +08:00 |
|
Stephen Chung
|
a7bfac21bd
|
Reducing boxing and sizes of Expr/Stmt.
|
2020-05-09 21:46:38 +08:00 |
|
Stephen Chung
|
17e4adc049
|
Move hash calculation out of loop.
|
2020-05-09 16:21:11 +08:00 |
|
Stephen Chung
|
79f39bd702
|
Pre-calculate function call hashes.
|
2020-05-09 16:15:50 +08:00 |
|
Stephen Chung
|
0d20137d6c
|
Implement private modifier for functions.
|
2020-05-09 11:29:30 +08:00 |
|
Stephen Chung
|
d1de84fdd2
|
Add comments and fix documentation.
|
2020-05-09 10:00:59 +08:00 |
|
Stephen Chung
|
e50fcc385f
|
Pre-calculate index for module-qualified calls.
|
2020-05-08 22:38:56 +08:00 |
|
Stephen Chung
|
eb52bfa28a
|
Add export statement.
|
2020-05-08 16:49:24 +08:00 |
|
Stephen Chung
|
89d75b1b11
|
Fix compilation errors for no_module.
|
2020-05-08 14:50:48 +08:00 |
|
Stephen Chung
|
e0745ef069
|
Do not build index for multiple packages to avoid Engine creation regression.
|
2020-05-08 13:27:51 +08:00 |
|
Stephen Chung
|
e6fabe58cc
|
Unify function hash calculations, pre-hash module-qualified function calls.
|
2020-05-08 11:34:56 +08:00 |
|