Commit Graph

155 Commits

Author SHA1 Message Date
06f17f491c Move variable setting code into utilities. 2018-09-13 23:57:33 -07:00
ca6075e8d5 Add a new method call operator, and more.
The '.' operator now represents method calls. A function f: (a, b)->c
can be called as a.f(b), which is equivalent to f(a, b). Besides
this change, all reserved operators now have a negative precedence
(it's relative, remember?), and some function names were changed.
2018-09-13 17:05:39 -07:00
4425b27b52 Make overloading code a utility function and call from interpreter.
This fixes #10.
2018-09-13 16:09:04 -07:00
5617484aff Make parsing function public.
libab already provides a _run_tree ... you can't run_tree if there's
no tree.
2018-09-12 14:43:43 -07:00
c4a7117704 Ensure operator does not try to take ownership of string. 2018-08-22 17:45:45 -07:00
0065fe5e65 Add utility functions to create libab instances on the heap. 2018-08-12 00:46:37 -07:00
ffcbab9d94 Remove unused files. 2018-08-11 20:11:32 -07:00
76ea606099 Finish basic implementation of garbage collection. 2018-08-11 20:01:43 -07:00
f4ecb82c46 Intermediate commit before visitor refactor. 2018-08-11 18:22:18 -07:00
80e7c95915 Make small adjustments to GC functions. 2018-08-11 16:00:00 -07:00
9eae28928a Move GC code to separate source file. 2018-08-11 01:40:30 -07:00
ec2421e5d7 Begin working on a garbage collector. 2018-08-11 01:29:48 -07:00
d7ef8e236d Add more specific lookup functions. 2018-08-10 19:47:11 -07:00
4a058384c1 Make some functions public. 2018-08-10 18:39:26 -07:00
3b79b5751a Add true and false keywords to the parser. 2018-08-10 16:06:30 -07:00
7c8c547540 Add true / false values to interpreter. 2018-08-10 15:29:56 -07:00
25f5d3469b Add a boolean type. 2018-08-10 00:52:12 -07:00
48300cd86e Implement reserved operators. 2018-06-21 19:00:45 -07:00
03577269f2 Add various ways to call code. 2018-06-21 17:06:53 -07:00
7dfc55154e Require scope in interpreter calls. 2018-06-21 16:11:39 -07:00
13ccea10e4 Add scope to internal functions. 2018-06-21 14:25:11 -07:00
827dba9013 Add the libab prefix to free functions. 2018-06-17 19:43:18 -07:00
f83b7d169c Resolve function types when they're created. 2018-06-17 19:01:15 -07:00
88ec979ba5 Add scope modes instead of a flag. 2018-06-17 01:25:41 -07:00
27c79d44f5 Add a foreach function to ref_trie. 2018-06-16 20:51:54 -07:00
695fbed235 Put free functions into common header / source file. 2018-06-15 22:54:58 -07:00
39dd07b134 Add pseudo-refcounting to tree creation. 2018-06-12 23:34:18 -07:00
9b575916ff Create a new creation function for new initialization type. 2018-06-02 20:56:30 -07:00
cbd57f2585 Add new way to initialize functions. 2018-06-02 20:56:10 -07:00
62dd41e634 Use the unit type correctly instead of null references. 2018-06-02 16:06:13 -07:00
8207f1f450 Add unit value to interpreter. 2018-06-02 15:59:13 -07:00
969e457fba Add a unit type. 2018-06-02 15:37:04 -07:00
f199bc6efd Add a function to call a function by name. 2018-06-01 23:32:19 -07:00
5fec3bd63c Make operators simply aliases to functions. 2018-06-01 15:24:55 -07:00
19416d0e15 Add clear functions to table and trie. 2018-05-31 19:29:14 -07:00
34b97e42ac Add scopes to functions. 2018-05-28 01:18:06 -07:00
031e6434c5 Add a new table entry type. 2018-05-27 23:10:59 -07:00
1f8788dd32 Add functions for getting special types. 2018-05-27 00:11:00 -07:00
1f7294ce29 Add libabacus parameter to function calls. 2018-05-27 00:02:20 -07:00
f4de244c41 Format code. 2018-05-26 21:55:30 -07:00
fb55e20e84 Add utilities to reuse common internal function code. 2018-05-26 15:04:28 -07:00
1cd7f3f45a Finish the draft implementation. 2018-05-22 17:45:32 -07:00
070dc179ff Add beginnings of function calling code. 2018-05-22 15:21:10 -07:00
2a1d51ae78 Add additional result types and change some code to use appropriate types. 2018-05-22 13:03:14 -07:00
680f65d2e6 Add additional functions to ref_vec. 2018-05-22 12:44:15 -07:00
72e143396c Add two utility functions to function_list. 2018-05-20 09:56:24 -07:00
a6029d7ef4 Add utility function for executing code. 2018-05-18 14:15:15 -07:00
03cce8d1fb Clean up some comments. 2018-05-17 15:33:38 -07:00
c3a7657c71 Format code. 2018-05-17 14:53:48 -07:00
97543a3d19 Remove unused nesting in behavior struct. 2018-05-16 23:10:33 -07:00