Jeroen van Rijn
f34ba44bf8
big: Add shl, shr and shrmod.
2021-08-11 20:59:51 +02:00
Jeroen van Rijn
d4d863c4db
big: Add mod_power_of_two.
2021-08-11 20:59:51 +02:00
Jeroen van Rijn
78c0877994
big: Add get(a, type) and get_float.
2021-08-11 20:59:51 +02:00
Jeroen van Rijn
1d0b37c1d8
big: add shl1, shr1.
2021-08-11 20:59:51 +02:00
Jeroen van Rijn
7648f2e655
big: Finish big ZII refactor.
2021-08-11 20:59:50 +02:00
Jeroen van Rijn
d9efa6c8b5
big: More ZII refactoring.
2021-08-11 20:59:50 +02:00
Jeroen van Rijn
2e372b33a3
big: More ZII refactoring.
2021-08-11 20:59:50 +02:00
Jeroen van Rijn
687c211a58
big: ZII.
2021-08-11 20:59:50 +02:00
Jeroen van Rijn
4eadd0867d
big: Continuing to refactor.
2021-08-11 20:59:50 +02:00
Jeroen van Rijn
9dba17cf87
bigint: refactor to big.Int instead of bigint.Int.
2021-08-11 20:59:50 +02:00
Jeroen van Rijn
baef0c291d
bigint: Added some more helpers.
2021-08-11 20:59:50 +02:00
Jeroen van Rijn
cccd290834
bigint: Add is_power_of_two helper.
2021-08-11 20:59:50 +02:00
Jeroen van Rijn
5af85aed3d
bigint: itoa support for arbitrary precision if is_power_of_two(radix)
2021-08-11 20:59:50 +02:00
Jeroen van Rijn
e600e5947b
bigint: remove unnecessary boundary checks.
2021-08-11 20:59:50 +02:00
Jeroen van Rijn
d7ae611f76
bigint: itoa now writes backwards directly, no need to reverse after.
2021-08-11 20:59:50 +02:00
Jeroen van Rijn
04a83eb9f7
bigint: pass size to itoa_raw.
2021-08-11 20:59:50 +02:00
Jeroen van Rijn
341e8a3c99
bigint: itoa works for numbers <= 120 bits.
2021-08-11 20:59:50 +02:00
Jeroen van Rijn
e3d8ac559d
bigint: Fast paths for radix code.
2021-08-11 20:59:50 +02:00
Jeroen van Rijn
767948ab46
bigint: log_n for bases that fit within one DIGIT or are a power of two.
2021-08-11 20:59:50 +02:00
Jeroen van Rijn
dbcd8da733
bigint: Working on itoa and logn.
2021-08-11 20:59:50 +02:00
Jeroen van Rijn
905d5459a9
bigint: Add count_bits and more prep.
2021-08-11 20:59:50 +02:00
Jeroen van Rijn
dfd5a993a2
bigint: Prepare for multiplication.
2021-08-11 20:59:50 +02:00
Jeroen van Rijn
daceaa65f5
bigint: Add substractin with immediate.
2021-08-11 20:59:50 +02:00
Jeroen van Rijn
c2c07f07db
Add single DIGIT addition.
2021-08-11 20:59:50 +02:00
Jeroen van Rijn
c5cbd3260a
bigint: Add prototypes for immediate add+sub.
2021-08-11 20:59:50 +02:00
Jeroen van Rijn
d57e1be89f
bigint: Improve add.
2021-08-11 20:59:50 +02:00
Jeroen van Rijn
18dda6ff9d
Start of core:math/bigint
...
We have:
- `init` to create a new `Int`
- `init(from_integer)` to create a new `Int` and set it to `from_integer`.
- `set(Int, from_integer)` to set an `Int` to `from_integer`
- `add(dest, a, b)` to add `a` and `b` into `dest`.
- `sub(dest, a, b)` to subtract `b` from `a` and put the result in `dest`.
And a few helper functions, like:
- `is_zero`, `is_negative`, ...
- `grow`, `shrink`, `clear`, `zero`
2021-08-11 20:59:50 +02:00
gingerBill
a3abe991a4
Add package core:encoding/hxa
2021-08-09 16:26:51 +01:00
gingerBill
d99ed692ba
Add utility procedures: io.read_ptr; io.write_ptr; io.read_ptr_at; io.write_ptr_at
2021-08-09 12:33:21 +01:00
gingerBill
4d00c2b800
Allocator_Error.Mode_Not_Implemented; Minor improvement to map runtime procedures
2021-08-08 14:29:45 +01:00
gingerBill
db3501f61b
[Breaking] Change the layout json.Value to be a union rather than a struct of a json.Pos and the union
2021-08-08 12:59:35 +01:00
gingerBill
48538aa792
Remove package core:encoding/cel
2021-08-08 12:50:38 +01:00
Jeroen van Rijn
ebd034fff9
CEL: Fix ISE.
2021-08-08 02:19:32 +02:00
gingerBill
0d257c61cd
Disallow using on an enum declaration.
2021-08-05 17:46:42 +01:00
gingerBill
dd8fa1d690
Prefer ..= over ..
2021-08-04 00:36:10 +01:00
gingerBill
af6df7d7c9
Improve error cases in core:odin/parser
2021-08-04 00:23:31 +01:00
gingerBill
57a17a708b
Improve core:odin/parser
2021-08-04 00:10:41 +01:00
gingerBill
afff9478c8
Make core:odin/tokenizer be consistent with the compiler's version
2021-08-03 23:27:26 +01:00
Jeroen van Rijn
d260ca6738
string.cut uses context.allocator by default.
2021-08-02 17:58:42 +02:00
Jeroen van Rijn
0dc900ba34
Add strings.cut, which returns a substring.
2021-08-01 19:41:20 +02:00
gingerBill
9cd5ea59dd
Big simplification and improvement of the entity collection system, reducing unneeded steps for packages
2021-07-27 20:45:50 +01:00
Jeroen van Rijn
5dfff51a40
Allow core:sys/windows to build on Windows only
2021-07-15 12:13:57 +02:00
gingerBill
2949e4b0c7
Fix floattidf typo
2021-07-10 22:23:22 +01:00
gingerBill
f6c1a5bf6e
Merge branch 'master' of https://github.com/odin-lang/Odin
2021-07-09 15:33:30 +01:00
gingerBill
6afc28f827
Use builtin.min and builtin.max in package slice
2021-07-09 15:33:25 +01:00
streof
114efbc57c
Fix error: Cannot assign to a procedure parameter
2021-07-09 14:03:49 +02:00
streof
2c71494ad1
Fix error: Undeclared name: p
2021-07-09 13:54:27 +02:00
gingerBill
7acbf8b7b9
Add slice.min and add slice.max
2021-07-08 11:23:07 +01:00
gingerBill
f7413ca974
Fix thread_unix.odin
2021-07-05 16:36:07 +01:00
gingerBill
9b3a0251ca
Use or_else in the core library when it makes sense
2021-07-05 16:33:01 +01:00