Commit Graph

248 Commits

Author SHA1 Message Date
Stephen Chung
07f25bacd9 Fix test output. 2021-11-23 16:44:59 +08:00
Stephen Chung
dc918447b6 Fix tests. 2021-11-13 22:47:01 +08:00
Stephen Chung
11f180bd4e Fix error template. 2021-10-29 17:59:38 +08:00
Stephen Chung
a51482e9c8 Fix formatting. 2021-10-23 12:28:42 +08:00
Stephen Chung
07181feacf Revise test output. 2021-10-23 12:12:23 +08:00
wackbyte
9f0347df9f Fix some rustdoc warnings and a typo in FLOAT's docs
Unfortunately, I can't fix the 2 remaining warnings.
2021-10-22 12:03:06 +08:00
Stephen Chung
ae493918a2 Update test outputs. 2021-10-20 15:34:21 +08:00
Stephen Chung
3f2dd23e6e Allow #[cfg(...)] in plugin functions. 2021-10-20 15:30:11 +08:00
Stephen Chung
0265af415d General code cleanup. 2021-10-20 13:36:40 +08:00
Stephen Chung
3001e90775 Deprecate From<EvalAltResult> for Result<T, Box<EvalAltResult>> because it is clearer for code to explicitly wrap errors in Err. 2021-10-19 23:52:58 +08:00
Stephen Chung
716e6191c0 Update error templates. 2021-10-12 20:57:47 +08:00
Stephen Chung
0b72a31d07 Fix test output. 2021-09-27 11:24:48 +08:00
Stephen Chung
65326d87f4 Fix test output. 2021-09-24 18:42:57 +08:00
Stephen Chung
e191f9d91e Merge branch 'bug-fixes' 2021-09-19 22:34:47 +08:00
Stephen Chung
661d00bc94 Fix test output. 2021-09-19 22:08:29 +08:00
Stephen Chung
6510b617fe Reduce usage of Default::default() 2021-09-11 19:40:40 +08:00
Stephen Chung
2980683153 Fix test output. 2021-09-02 22:44:33 +08:00
Stephen Chung
cb90ce96d2 Fix codegen test. 2021-08-30 12:12:25 +08:00
Stephen Chung
b6d38a8fc9 Fix metadata build. 2021-08-30 10:25:24 +08:00
Stephen Chung
33d1006d28 Fix test output. 2021-08-21 11:51:45 +08:00
Stephen Chung
94674679d9 Rename as_string and as_immutable_string. 2021-08-17 15:50:55 +08:00
Stephen Chung
4bf22e6cb7 Fix test output. 2021-08-12 11:53:05 +08:00
Stephen Chung
a05142d4e9 Change Rhai dependency to 1. 2021-08-01 22:22:00 +08:00
Stephen Chung
df482d3574 Satisfy clippy. 2021-07-24 14:11:16 +08:00
Stephen Chung
204c08a131 Bump codegen. 2021-07-07 08:38:56 +08:00
Stephen Chung
694ac5b5bd General code fixups. 2021-07-04 16:40:15 +08:00
Stephen Chung
02e886e33b Bump rhai_codegen version to require 0.20.3 of rhai. 2021-06-22 22:43:44 +08:00
Stephen Chung
68ea8c27fd Fix unchecked.
Do not duplicate data size checking.
2021-06-12 10:26:50 +08:00
Stephen Chung
a1950a9562 Bump versions. 2021-06-10 19:09:27 +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
65b7135324 Fix tests. 2021-06-07 11:54:10 +08:00
Stephen Chung
5f36f1a28c Remove PluginFunction::is_variadic. 2021-05-29 18:32:34 +08:00
Stephen Chung
c6ee20094b Fix teset output. 2021-05-25 11:09:55 +08:00
Stephen Chung
d07d4d295d Fix tests. 2021-05-22 19:34:10 +08:00
Stephen Chung
941e09d29d Guard against setters mutating constants, and allow pure setters. 2021-05-15 11:41:42 +08:00
Stephen Chung
202285f9ab Disallow pure setters. 2021-05-13 10:34:24 +08:00
Stephen Chung
13d5092c4d Allow setters returning values when return_raw. 2021-05-02 23:51:37 +08:00
Stephen Chung
b091113334 Eliminate unnecessary data structures. 2021-04-27 22:28:01 +08:00
Stephen Chung
e4ffd2d52a Fix codegen test. 2021-04-19 22:12:20 +08:00
Stephen Chung
e31506fe51 Bump version. 2021-04-16 21:59:11 +08:00
Stephen Chung
d564a66869 Change rhai dependency. 2021-03-31 16:48:46 +08:00
Stephen Chung
c0b2eee9f2 Fix syn regression. 2021-03-29 12:46:46 +08:00
Stephen Chung
0afc2a0842 Reverse Module::set_plugin_fn. 2021-03-26 18:41:28 +08:00
Stephen Chung
c443c3bb48 Gate codegen metadata output under metadata feature. 2021-03-26 10:59:34 +08:00
Stephen Chung
adbb5f8eb8 Use static array for codegen parameters info. 2021-03-25 14:02:50 +08:00
Stephen Chung
c4fe1782df Streamline string handling. 2021-03-24 13:17:52 +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
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
39fb78293c Change codegen tests for return_raw. 2021-03-22 19:21:42 +08:00
Stephen Chung
a82f0fc738 Allow non-Dynamic in return_raw. 2021-03-22 11:18:09 +08:00
Stephen Chung
b3bcd7bf79 Fix codegen test. 2021-03-22 10:08:43 +08:00
Stephen Chung
aa0594210c Use RhaiResult for plugin return. 2021-03-19 10:30:30 +08:00
Stephen Chung
d0922adb5b Deprecate RegisterFn and RegisterResultFn. 2021-03-15 11:36:30 +08:00
Stephen Chung
f3b5df09af Fix codegen test results. 2021-02-26 20:14:23 +08:00
Stephen Chung
33fa57d95b Refine codegen error positions. 2021-02-26 20:00:25 +08:00
Stephen Chung
37fe14ba16 Raise error if pure misuse. 2021-02-26 18:28:21 +08:00
Stephen Chung
823ecef1f1 #[rhai_fn(pure)] must have &mut parameter. 2021-02-26 17:19:40 +08:00
Stephen Chung
2f78626a21 Update README. 2021-02-25 17:53:01 +08:00
Stephen Chung
067983bb57 Fix codegen tests. 2021-02-21 15:44:01 +08:00
Stephen Chung
dd3b16403f Code cleanup. 2021-02-21 14:11:19 +08:00
Stephen Chung
fc7697d504 Reflect visibility to generated modules. 2021-02-21 13:51:24 +08:00
Stephen Chung
ac1b7debe9 Add pure function attribute. 2021-02-19 23:13:41 +08:00
Stephen Chung
61d7356e08 Reduce spelling warnings in codegen. 2021-02-18 17:42:49 +08:00
Stephen Chung
4815de3634 Fix codegen test error display. 2021-02-09 14:34:51 +08:00
Stephen Chung
7fc38d4cd2 Change rhaiscript.github.io to rhai.rs 2021-01-30 07:19:54 +08:00
Stephen Chung
9e2c1a5860 Bump version. 2021-01-15 19:55:14 +08:00
Stephen Chung
8c47d61456 Refine documentation and comments. 2021-01-11 23:09:33 +08:00
Stephen Chung
96b1e7777b Update URL links. 2021-01-07 17:30:06 +08:00
Stephen Chung
67a85a19ae Fix codegen test. 2021-01-06 19:30:58 +08:00
Stephen Chung
e059ca009c Fix feature builds. 2021-01-06 18:22:45 +08:00
Stephen Chung
fba2dd7a84 Bump version. 2020-12-30 15:17:16 +08:00
Stephen Chung
dc4e52e795 Code enhancements. 2020-12-26 13:05:57 +08:00
Stephen Chung
809b813def Simplify codegen. 2020-12-24 21:28:40 +08:00
Stephen Chung
9fd7e01197 Simplify code. 2020-12-23 23:29:19 +08:00
Stephen Chung
746a0b186f Fix typo. 2020-12-23 15:15:47 +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
95b8dcc623 Update docs. 2020-12-16 14:57:28 +08:00
Stephen Chung
4c4a209609 Fix tests. 2020-11-30 21:16:59 +08:00
Stephen Chung
65a4ceb3be Getters/setters and indexers in a plugin module are default global. 2020-11-30 00:52:21 +08:00
Stephen Chung
8d410dfc71 Add return type to function metadata. 2020-11-22 22:15:17 +08:00
Stephen Chung
07fe132e1a Add gen_fn_siguatures API. 2020-11-22 17:21:34 +08:00
Stephen Chung
e5c9ca23b5 Build index when creating a module. 2020-11-21 22:18:32 +08:00
Stephen Chung
863c6b45a5 Fine tune codegen for global exports. 2020-11-17 14:29:28 +08:00
Stephen Chung
bd094d95b4 Fix codegen doc error. 2020-11-17 13:11:31 +08:00
Stephen Chung
df72d324ba Fix tests. 2020-11-17 12:40:12 +08:00
Stephen Chung
a19865d811 Add global/internal parameters to rhai_fn. 2020-11-17 12:09:56 +08:00
Stephen Chung
c919ee4e46 Fine tune hash map sizes. 2020-11-15 13:49:54 +08:00
Stephen Chung
cbd7ed2ca7 Fix test. 2020-10-28 22:30:35 +08:00
Stephen Chung
2c7c719cd5 Minor cleanup before release. 2020-10-22 12:26:44 +08:00
Stephen Chung
09f8b13f2d Fix test output. 2020-10-20 11:10:46 +08:00
Stephen Chung
643ecc86a3 Minor refactor 2020-10-20 09:21:41 +08:00
Stephen Chung
46b92c9d1f Allow NativeCallContext in function arguments. 2020-10-18 21:47:34 +08:00
Stephen Chung
29374a8ce7 Update version. 2020-10-16 17:48:50 +08:00
Stephen Chung
a6fa94d946 Rhai function names with $ and . no longer fail. 2020-10-15 14:36:10 +08:00
Stephen Chung
8abb3c5203 Fix ui tests. 2020-10-15 14:06:54 +08:00
Stephen Chung
3c9250b0bf Skip wrapping if function returns Dynamicc. 2020-10-15 13:28:22 +08:00
Stephen Chung
d35c216465 Add README's. 2020-10-07 22:56:21 +08:00