Commit Graph

3383 Commits

Author SHA1 Message Date
Lucas Perlind
73c1f08776 Improve error messages with 'using _' 2022-10-15 19:46:17 +11:00
gingerBill
047d45584e Fix #2016 when passing an untyped integer to a generic typeid parameter 2022-10-11 21:21:56 +01:00
gingerBill
970ac22647 Merge branch 'master' of https://github.com/odin-lang/Odin 2022-10-10 21:49:03 +01:00
gingerBill
419eab5059 Force call site attributes for procedures (relating to #2121 causing ABI issues for intrinsics.objc_send) 2022-10-10 21:48:56 +01:00
Jeroen van Rijn
159c5311c3 Revert "Fix #2112" 2022-10-08 23:01:06 +02:00
Jeroen van Rijn
ab7367ae47 Fix #2112 2022-10-08 19:00:05 +02:00
Lucas Perlind
e188a542da llvm_backend_debug: Add debug info for soa pointer
This fixes issue #2113
2022-10-08 17:08:28 +11:00
gingerBill
35e70f4be1 Add node data for union when using intrinsics.type_convert_variants_to_pointers 2022-09-27 22:30:00 +01:00
gingerBill
0fe006157e Remove extra pointer indirection 2022-09-27 00:18:19 +01:00
gingerBill
4d208dc092 Override lbArgKind to be indirect for #by_ptr parameters 2022-09-27 00:10:05 +01:00
gingerBill
a7484f16cb Merge branch 'master' of https://github.com/odin-lang/Odin 2022-09-22 15:17:42 +01:00
gingerBill
6c8aad0afb Make intrinsics.{count_ones, count_zeros, count_trailing_zeros, count_leading_zeros} work at compile time 2022-09-22 15:17:36 +01:00
Colin Davidson
2ff61bdfc7 fix target features to make wasm intrinsics happy 2022-09-21 18:35:56 -07:00
gingerBill
b426e8577b cap(Enum) (equivalent to max(Enum)-min(Enum)+1) 2022-09-22 01:09:18 +01:00
gingerBill
532133d648 Minor technical improvement 2022-09-22 00:55:28 +01:00
gingerBill
6fe1825db9 Improve error message for slicing an enumerated array 2022-09-22 00:47:23 +01:00
gingerBill
b15968f140 Improve suggestions for certain assignments 2022-09-22 00:42:03 +01:00
gingerBill
0ddf1bf660 Minor style change 2022-09-22 00:36:31 +01:00
gingerBill
dade5b5ef2 Improve error message for check_is_expressible (Cannot convert X to Y from Z) 2022-09-22 00:34:36 +01:00
gingerBill
3aea9a7c20 Improve error messages for compile time known bounds checking 2022-09-22 00:30:10 +01:00
gingerBill
0dce7769f4 Clean up private internal constant global handling 2022-09-22 00:18:03 +01:00
gingerBill
8c3f01fbfa Correct parapoly determination of generated internal type of a map 2022-09-22 00:05:11 +01:00
gingerBill
9b9aa9c353 Remove more dead code for map header stuff 2022-09-21 13:08:40 +01:00
gingerBill
831620bfc4 Remove header cache code 2022-09-21 13:06:02 +01:00
gingerBill
4f50988799 Remove debug code 2022-09-21 13:03:30 +01:00
gingerBill
ff97a73152 Reduce unnecessary map gets 2022-09-21 13:03:13 +01:00
gingerBill
1d793ea338 Split header table data and the map pointer 2022-09-21 12:09:05 +01:00
gingerBill
5337413c56 Temporary patch for lb_gen_map_header 2022-09-21 11:36:14 +01:00
gingerBill
3ff56e4405 Correct get_fullpath_relative to remove all trailing path separators (/ and \) 2022-09-21 11:31:52 +01:00
gingerBill
eb7a9c55b0 Improve parapoly support for ^T to [^]$V and vice versa 2022-09-20 22:47:53 +01:00
gingerBill
4d512c2cf6 Correct lb_gen_map_header initialization 2022-09-17 13:40:29 +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
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
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
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
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
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
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
gingerBill
913e8b2e02 Unify debug parameter code 2022-09-10 10:03:51 +01:00
gingerBill
623d687192 Split debug info generation for direct and indirect parameters 2022-09-09 23:07:09 +01:00
gingerBill
3fae8b49db Fix pointer cast of constant procedure values 2022-09-08 17:27:13 +01:00