Commit Graph

41 Commits

Author SHA1 Message Date
3513b94fc7 Unify parsing code to correctly handle parsing integers and numbers with
a &success boolean. Check for overflow as well.
2024-09-04 16:08:34 -04:00
6d7a359f8f Bugfix some text replacement things 2024-09-02 19:49:52 -04:00
80a09e6dba Fix up some integer and print statement stuff 2024-09-02 19:29:43 -04:00
61e482f6f3 Initial WIP first past 2024-09-02 18:47:39 -04:00
dceb925573 Bugfix for parsing ints 2024-08-23 11:38:54 -04:00
b76fbd3beb Add Int:clamped() and Num:clamped() 2024-08-18 23:20:54 -04:00
a49870f810 Add primality testing and next_prime()/prev_prime() 2024-08-18 15:22:51 -04:00
20b7793963 Make small integer constants actually constant 2024-08-17 15:17:41 -04:00
bac188ce07 Change division and modulus to use euclidean division, plus fix up a few
integer bugs
2024-08-16 14:24:20 -04:00
0f1c475bb4 More fixes for ints 2024-08-16 13:14:45 -04:00
436c6d4457 Bugfix 2024-08-16 13:13:35 -04:00
9c2d7c437d Fix up type conversions with ints and nums 2024-08-14 14:57:01 -04:00
e56fd1aa94 Add Int:sqrt() 2024-08-13 16:36:41 -04:00
e0223a4c20 Support ^ exponentiation for integers 2024-08-13 16:32:00 -04:00
f0d97cd4cd Make biggest int semantically meaningful 2024-08-13 14:27:50 -04:00
5a0502bdf5 Fix some edge cases 2024-08-13 14:13:02 -04:00
148782e61b Create inlined fast versions of integer ops 2024-08-13 13:50:19 -04:00
2c4f6536a3 Fix Int->Num promotions 2024-08-13 02:51:10 -04:00
9b9087bfef Get rid of slow_* int functions 2024-08-13 02:42:02 -04:00
25519d2434 Fixing up more stuff 2024-08-13 02:28:14 -04:00
aa74180ed1 Fixing up integers 2024-08-13 02:20:48 -04:00
158a1c6ad2 More fixes 2024-08-13 02:09:18 -04:00
21fd5c8195 Bugfixes 2024-08-13 01:43:46 -04:00
d08f795794 Partially working first draft of bigints 2024-08-13 01:30:25 -04:00
c045c54309 Add a Range datatype with creation methods like 5:to(10) and
modification methods like `range:by(2)` or `range:reversed()`
2024-08-05 14:40:28 -04:00
17be975d3a Fix integer random functions so they correctly handle all representable
ranges
2024-08-03 16:23:28 -04:00
e439fcd1e2 Clean up imports a bit 2024-05-18 14:42:35 -04:00
e6f78f1d89 Add from_text() method for ints/nums 2024-04-10 13:23:49 -04:00
04d9adc813 Switch naming convention to use '$' in symbols more 2024-03-29 12:54:31 -04:00
d94c1057ac Improve codegen for enums by eliminating unnecessary methods 2024-03-18 14:11:56 -04:00
7622f62935 More file comments 2024-03-18 12:57:49 -04:00
23478e7036 Rename as_str -> as_text 2024-03-03 18:16:33 -05:00
bf5a725345 Definitively go with "Int" and "Num" over "Int64" and "Num64", plus add
Int__bits()
2024-03-03 13:37:05 -05:00
ec7a9e5f10 Initial pass at namespacing 2024-03-03 13:04:50 -05:00
a7bbbe9584 Const typeinfos 2024-02-27 13:47:29 -05:00
ce0e1c25e2 Stop using namespace types 2024-02-27 13:39:12 -05:00
86f3a80544 Split out parts into appropriate headers 2024-02-17 23:27:02 -05:00
4a5c651d43 Overload type names with constructor and namespace struct 2024-02-17 22:15:45 -05:00
30c5b1ec25 Use #defines for Int aliasing 2024-02-17 19:54:32 -05:00
dd2de31666 Fix up USE_COLOR 2024-02-17 19:52:37 -05:00
d46925dbfa Cleanup of builtins 2024-02-17 19:32:30 -05:00