Commit Graph

7123 Commits

Author SHA1 Message Date
gingerBill
40bcfc7c8d Update json/unmarshal.odin for the new runtime.__dynamic_map_set 2022-09-17 13:05:14 +01:00
gingerBill
bfe0ffd6e6 Minor clean up 2022-09-17 13:02:06 +01:00
gingerBill
8ee6bb5d4b Add contextless where possible in dynamic_map_internal.odin 2022-09-17 13:00:19 +01:00
gingerBill
0ebc2add03 Use a cache when generating the map header to minimize stack wastage 2022-09-17 12:56:03 +01:00
gingerBill
7840c1b89f Change __dynamic_map_get and __dynamic_map_set to use separate parameters rather than take a singular struct 2022-09-17 12:48:12 +01:00
gingerBill
0428d5ae2e Catch missing areas of Map_Index usage 2022-09-17 12:27:34 +01:00
gingerBill
b967ae2739 Change internal map indices to use a distinct uint rather than just int 2022-09-17 12:21:23 +01:00
gingerBill
c462496bd5 Merge pull request #2048 from odin-lang/pow2-map
Use pow of two capacity for hash maps to allow for `& (n-1)` instead of `% n`
2022-09-17 11:28:42 +01:00
gingerBill
a903e5024c Chnage next_pow2 to ceil_to_pow2 2022-09-17 11:18:26 +01:00
gingerBill
7cce55e2fc Merge pull request #2051 from graphitemaster/dale/vendor-zlib
Vendor zlib
2022-09-17 11:17:07 +01:00
gingerBill
99a1a10286 Fixed #2044 Uninitialised constant struct member values can cause crash
Foo :: struct {
    x: i32,
    data: sa.Small_Array(10, i32),
}

defaultFoo :: Foo{
    x = 1,
    // The 'data' value is not set!
}

fmt.println(defaultFoo.data) // caused the bug
2022-09-17 11:01:56 +01:00
gingerBill
9640b49319 Fix #1435 type switch statements of empty union types 2022-09-17 10:42:54 +01:00
gingerBill
1bc0e66ed1 Improve error message for using offset_of within a struct itself of that struct 2022-09-17 10:36:49 +01:00
gingerBill
117d32dfc4 Enforce constant pointer cast on global procedure variable initialization x := proc() {} 2022-09-17 10:26:57 +01:00
gingerBill
320b84df4f Fix #2052 typo in linalg.max_single 2022-09-17 10:20:52 +01:00
gingerBill
98eaf5c6c0 Fix #2054 Differing behaviours with defer statements for single vs multiple return values caused by naïve ABI optimization 2022-09-17 10:20:04 +01:00
Jeroen van Rijn
9842019205 [examples] Add math/noise, align imports. 2022-09-15 18:01:15 +02:00
Jeroen van Rijn
479278be4e Merge pull request #2053 from z64/master
Fix -verbose-error source lines from having last char cut off with LF files
2022-09-15 16:09:15 +02:00
Zac Nowicki
4767311a22 Fix -verbose-error source lines from having last char cut off
Fixes #1226
2022-09-15 07:09:38 -04:00
gingerBill
f50fc33749 Clean up of the core library to make the stream vtables not be pointers directly. 2022-09-15 10:00:50 +01:00
Jeroen van Rijn
8aba92da9b [zlib] Add statically linked x64 library. 2022-09-14 23:27:28 +02:00
Jeroen van Rijn
59f3e10f0a [zlib] Add LICENSE, update README 2022-09-14 23:08:52 +02:00
Dale Weiler
8b82bcef7d vendor zlib 2022-09-14 16:09:13 -04:00
gingerBill
1e595f2e26 Add missing import 2022-09-14 18:27:02 +01:00
gingerBill
28ad4f8623 Use json field tag for json.marshal 2022-09-14 18:21:12 +01:00
gingerBill
a3c04db828 Revert "Just get the value directly and store it in another global variable"
This reverts commit 190c3ab0cd.
2022-09-14 17:57:12 +01:00
gingerBill
3ea7af4c9c Minor fix to lb_big_int_to_llvm 2022-09-14 17:51:33 +01:00
gingerBill
190c3ab0cd Just get the value directly and store it in another global variable
// global
x := &Foo{}
2022-09-14 17:50:31 +01:00
gingerBill
53c7cf895c Merge branch 'master' of https://github.com/odin-lang/Odin 2022-09-14 16:52:09 +01:00
gingerBill
db1b7b2d21 Allow for ignored fields in struct for json.unmarshal 2022-09-14 16:52:01 +01:00
Jeroen van Rijn
7cd7886111 Merge pull request #2050 from ftphikari/master
sys/windows: add definitions
2022-09-14 12:36:51 +02:00
hikari
164ba944ac sys/windows: add definitions 2022-09-14 11:42:19 +03:00
Jeroen van Rijn
e7fb2cf73b Merge pull request #2049 from eadesmet/master
Added support for ID3D11InfoQueue
2022-09-13 02:02:57 +02:00
eadesmet
023cc8b572 Added support for ID3D11InfoQueue 2022-09-12 18:19:12 -04:00
gingerBill
0ff5ff6ff2 Use pow of two capacity for hash maps to allow for & (n-1) instead of % n 2022-09-12 21:22:45 +01:00
gingerBill
a35d6a6f8d Improve mem/virtual handling of out of memory on Windows 2022-09-12 17:06:32 +01:00
gingerBill
663b62e45f Fix ODIN_BUILD_PROJECT_NAME 2022-09-12 14:43:50 +01:00
gingerBill
6910182011 Fix debug generation for named results 2022-09-12 14:12:31 +01:00
gingerBill
bba47b6f54 Merge branch 'master' of https://github.com/odin-lang/Odin 2022-09-12 13:44:34 +01:00
gingerBill
ef372bd861 Replace #optional_second with #optional_allocator_error 2022-09-12 13:08:32 +01:00
gingerBill
fbbfe438dc Improve debug info to named return values 2022-09-12 13:08:05 +01:00
Jeroen van Rijn
7e495a5fe5 Merge pull request #2045 from ShimmyShaman/master
small doc fix for strings.last_index_any
2022-09-11 21:45:40 +02:00
Adam Rasburn
0f036eebc0 doc fix for strings.last_index_any 2022-09-12 07:37:15 +12:00
gingerBill
e008eeac6a Simplify package io by removing different unnecessary types and calls 2022-09-11 15:42:08 +01:00
Jeroen van Rijn
25e330500f Merge pull request #2043 from Kelimion/tga_tests
Tga tests
2022-09-10 20:29:47 +02:00
Jeroen van Rijn
fa20988f51 Merge branch 'master' into tga_tests 2022-09-10 20:22:49 +02:00
Jeroen van Rijn
99f4cc3006 [core:image/tga] Add tests. 2022-09-10 20:22:10 +02:00
Jeroen van Rijn
a1487e4814 Merge pull request #2040 from ryancsh/master
Add windows.timeGetTime()
2022-09-10 20:16:04 +02:00
Ryan Chan
183a02c584 Add windows.timeGetTime()
Here is the windows documentation for it: https://docs.microsoft.com/en-us/windows/win32/api/timeapi/nf-timeapi-timegettime
2022-09-10 16:54:34 +04:00
gingerBill
913e8b2e02 Unify debug parameter code 2022-09-10 10:03:51 +01:00