Commit Graph

505 Commits

Author SHA1 Message Date
dc7289b239 Fix for optional langs 2024-11-04 01:24:28 -05:00
b69d14b894 Add some missing functionality for Bytes 2024-11-04 01:12:37 -05:00
fc9a6f1416 Add RNGs to the language 2024-11-03 22:37:48 -05:00
7ccb7a8a9b Use an RNG parameter for array:random(), array:shuffle(),
array:shuffled()
2024-11-03 16:10:03 -05:00
39a58bc129 Clean up behavior and syntax for unsigned bit shifts (<<<, >>>) 2024-11-03 16:06:26 -05:00
3743913ce2 Add unsigned integer shifts 2024-11-03 15:48:13 -05:00
f656c9eb26 Better error messaging for binops and support for bit shifting by an
integer literal (without a bit size)
2024-11-03 15:15:03 -05:00
078b443185 Add a repeat keyword 2024-11-03 12:20:53 -05:00
d905fa4888 Minor fix 2024-11-03 11:25:18 -05:00
92a593b80f Support reductions for comparison operators like == and < 2024-11-02 22:34:35 -04:00
0b7a0dd043 Change reducers to use (OP: ...) syntax and return an optional value 2024-11-02 20:22:19 -04:00
e0fb49376b Fix type members not appearing in headers for declared values 2024-10-30 14:28:20 -04:00
de3628c5b5 Fix for methods not appearing in headers 2024-10-30 14:27:02 -04:00
fb683a2b1b Organize typedef headers so the typedefs come before the namespace
members
2024-10-30 14:02:34 -04:00
9ebb039a81 Fix up some GCC compiler flag options for LTO and inlining 2024-10-29 23:14:31 -04:00
63a5032ca0 Disallow mutation of read-only views 2024-10-27 20:35:30 -04:00
41c0ea851a Deprecate "&" for stack references 2024-10-27 20:35:12 -04:00
df258c1773 Remove an unnecessary ARRAY_COPY() 2024-10-27 19:39:34 -04:00
71d6787541 Bugfix: for array:find() and array:sorted() and array:binary_search(),
do an ARRAY_COPY() if a user closure is being passed in, because the
closure could mutate the array and the semantics of those functions
should be to return information based on a snapshot
2024-10-27 19:33:28 -04:00
67702b2d77 Fix issue with non-ID chars in filenames 2024-10-10 01:09:17 -04:00
a2490f4a50 Clean up codegen for when statements 2024-10-09 21:01:43 -04:00
074cf22ad4 Change function syntax from func(args)->ret to func(args -> ret) 2024-10-09 13:26:28 -04:00
7c853f83c9 Fix closure handling behavior for defer so that it can mutate
closed-over variables.
2024-10-09 00:45:52 -04:00
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