Commit Graph

482 Commits

Author SHA1 Message Date
fcbdf18315 Bugfix for defer using enclosing scope 2024-10-09 00:36:00 -04:00
fc0ad68b50 Bugfix for reductions over conditional comprehensions that have no values. 2024-10-08 21:46:09 -04:00
839c1983a0 Reduce padding needed for optional types and clean up some redundant
type padding
2024-10-08 21:10:36 -04:00
954ed42934 Simplify enum/struct codegen by using reusable general-purpose
metamethods for structs/enums instead of metamethod codegen for each struct/enum
defined.
2024-10-08 13:35:18 -04:00
6b9055db7c Deprecate readonly pointers for now 2024-10-04 13:21:56 -04:00
54e336e30f Update array:sample() to use optional weights and do more error checking 2024-10-02 14:42:51 -04:00
1a6ce0047b Rename TypeInfo -> TypeInfo_t and fix up some typeinfo code 2024-09-30 14:39:30 -04:00
ec0606091b Add datetime literal and tests 2024-09-30 13:55:55 -04:00
076f87361d Support using DateTime() as a constructor 2024-09-29 20:19:46 -04:00
05515d8645 Add DateTime 2024-09-29 20:06:09 -04:00
23af8b64a3 Overhaul of argument parsing code 2024-09-28 15:17:09 -04:00
ca93e6f3cb Simplify code by making name := use ... a Use AST instead of a Declare 2024-09-27 14:56:24 -04:00
9b15799e73 Support iterating over thunks that always return non-null values (useful
for infinite loops)
2024-09-27 14:45:06 -04:00
b26da60f2f Better error message for duplicate fn arg name 2024-09-27 14:22:36 -04:00
0622f758f7 Improved support for CLI arg parsing 2024-09-27 13:56:56 -04:00
b138893c40 Support or= and and= for optional types 2024-09-27 13:13:30 -04:00
ed8b8901c0 Add '$' prefix on all user code 2024-09-24 14:54:22 -04:00
0609a26f31 Fix type promotion for :divided_by() and :scaled_by() metamethods 2024-09-24 13:17:44 -04:00
a56ce0435d Support Int(yes/no) 2024-09-24 12:40:56 -04:00
62745cda95 Use original folder names more 2024-09-22 15:07:44 -04:00
7f5af625e5 Support useing .c files and .S files (assembly) 2024-09-18 15:39:22 -04:00
2158bb97fc Clean up struct code a bit 2024-09-18 01:01:15 -04:00
0829e1a2d1 Clean up enum code 2024-09-18 00:58:41 -04:00
7e0b1a3214 Deprecate linker directives 2024-09-18 00:43:13 -04:00
ec88848f6b Support explicit discards better by allowing multiple declared "_" vars 2024-09-18 00:30:05 -04:00
03a7d5f44d Overhaul of header logic so it now uses topological ordering and
deduplication for libraries with multiple files.
2024-09-17 16:20:30 -04:00
aaa51fc734 Perform topological ordering when compiling typedefs so users don't need
to think about ordering their definitions.
2024-09-17 15:17:13 -04:00
e5f432d4c9 Fix not x for optional values 2024-09-16 16:10:05 -04:00
de49bc5bb3 Deprecate :or_else()/:or_fail()/:or_exit() in favor of the or operator 2024-09-16 16:06:19 -04:00
821bde156c Support (optional or skip) 2024-09-16 15:48:06 -04:00
68c4731ae6 Show more error info 2024-09-16 14:27:18 -04:00
6b5a9d65e3 Overhaul of how libraries are installed 2024-09-15 21:18:42 -04:00
8a1ace4d65 Fix optional text CLI args 2024-09-15 17:53:20 -04:00
8ee23054bf Update Inline C syntax and documentation/tests 2024-09-15 17:34:34 -04:00
835eb7e896 Add optional:or_exit(...) 2024-09-15 16:42:42 -04:00
fb37b0ee42 Fix up if var := ...: in ternary expressions and optional checking
logic
2024-09-15 16:29:45 -04:00
e422079fcc Add a Byte datatype 2024-09-15 15:33:47 -04:00
c455e7b67d Rename builtins/ -> stdlib/ 2024-09-13 20:18:08 -04:00
34c562e88e Move cord helper functions into their own file 2024-09-13 14:23:24 -04:00
da9cc93c46 Make functions print with func name(...)->... [file:line] info 2024-09-12 23:41:32 -04:00
46a2aa2ffc Fix up comprehensions so set comprehensions work and everything is a bit
more clean
2024-09-12 14:27:13 -04:00
990846debb Add enum scoping to arrya/set/table literals 2024-09-12 13:11:03 -04:00
56a4d13975 Automatic promotion to single-argument enum tags with a unique type 2024-09-12 13:05:08 -04:00
1d05704fdd Use CString literals as constant values 2024-09-12 02:18:05 -04:00
327d466b95 Table:get() now uses optional values instead of default or failure modes 2024-09-12 00:55:43 -04:00
fa7e52787f Add postfix ! operator for optionals 2024-09-12 00:13:53 -04:00
8e300312a0 Change check_optional -> check_null 2024-09-11 23:55:49 -04:00
c034175ae1 Add optional:or_else(fallback) and optional:or_fail(message) 2024-09-11 23:17:03 -04:00
cfef667a89 Fix optional integer promotion 2024-09-11 23:13:41 -04:00
0f7cf28af1 Fix threads and integers 2024-09-11 22:50:03 -04:00