Commit Graph

3187 Commits (9bdcd2a495d4189d6536d43f1294dffb38daa9a5)

Author SHA1 Message Date
Andrew Kelley a10351b439 disable atomic stack and queue tests for non-linux 2018-04-28 18:19:00 -04:00
Andrew Kelley 5d6e44b3f2 add tests for std.atomic Queue and Stack 2018-04-28 18:00:51 -04:00
Andrew Kelley 96ecb40259 add fuzz tests for std.atomic.Stack 2018-04-28 17:53:06 -04:00
Andrew Kelley 4ac36d094c add std.atomic.Stack and std.atomic.Queue 2018-04-28 16:11:32 -04:00
Jimmi Holst Christensen 73bf897b5c Using allocate instead of allocate_nonzero so we don't have to memset 2018-04-28 19:21:23 +02:00
Jimmi Holst Christensen d6f033b42d Fixed build error 2018-04-28 19:09:25 +02:00
Jimmi Holst Christensen 837166319d Trying to fix osx build failing by setting param_info.type to nullptr 2018-04-28 19:02:46 +02:00
Alexandros Naskos af73462da4 Started work on function definition TypeInfo generation. 2018-04-28 19:57:59 +03:00
Jimmi Holst Christensen 341f8c1e86 Fixed wrong formatting for arg_index when reporting @ArgType error 2018-04-28 17:57:47 +02:00
Alexandros Naskos 9ba400673d Generating TypeInfo's now forces definitions to be resolved. 2018-04-28 18:38:38 +03:00
Jimmi Holst Christensen fba0347ec4 .ReturnType and @ArgType now emits errors on unresolved types
related: #846
2018-04-28 17:17:48 +02:00
Jimmi Holst Christensen 2fc34eaa58 Functions with infered error set can now return literals
fixes #852
2018-04-28 16:27:31 +02:00
Alexandros Naskos 61b0180596 Added definition TypeInfo generation, except for function definitions. 2018-04-28 17:01:19 +03:00
Jimmi Holst Christensen 3178528335 Removed zero sized error set optimization
fixes #762
fixes #818
2018-04-28 14:05:08 +02:00
Alexandros Naskos ea2596280f Added BoundFn TypeInfo generation. 2018-04-27 05:10:20 +03:00
Alexandros Naskos 8f703f919f Added Fn TypeInfo generation. 2018-04-27 04:29:50 +03:00
Alexandros Naskos a2dadbc206 Added struct TypeInfo generation. 2018-04-27 02:52:09 +03:00
Alexandros Naskos 9041d0d37e Fixed enum tag type detection in TypeInfo generation. 2018-04-27 02:05:24 +03:00
Alexandros Naskos 884e32d5c3 Added ErrorUnion, Union TypeInfo generation 2018-04-26 19:56:34 +03:00
Alexandros Naskos fbbbee6b72 Switched to shallow TypeInfo. 2018-04-26 18:18:47 +03:00
Alexandros Naskos 4aa5d87ada Added ErrorSet TypeInfo generation. 2018-04-26 17:14:38 +03:00
Alexandros Naskos f5977f68eb Added Enum TypeInfo except for methods 2018-04-26 16:41:59 +03:00
Alexandros Naskos 7a91e4736a Reset parent on cached TypeInfo values if we need to. 2018-04-26 14:29:27 +03:00
Alexandros Naskos bb56360bfa Added TypeInfo cache 2018-04-26 14:03:19 +03:00
Alexandros Naskos dd88d7deda Cleanup 2018-04-26 13:27:16 +03:00
Alexandros Naskos bc160821d3 Changed TypeInfo layout. 2018-04-25 17:50:11 +03:00
Alexandros Naskos 2606993cb4 Fixed ir_type_info_struct_set_parent for struct parents. 2018-04-25 11:59:35 +03:00
Alexandros Naskos d68aea4f35 Added checks for field name/index mapping in TypeInfo generation. Abstracted the parent setting out. 2018-04-25 11:35:46 +03:00
Braedon 07af6559d8
Changed to use shifting and masking 2018-04-25 16:26:57 +10:00
Braedon f6cbe9a9cc
Utf8 Encode 2018-04-25 14:59:03 +10:00
Andrew Kelley 7270f35c93 Merge remote-tracking branch 'origin/master' into float-printing 2018-04-24 23:47:37 -04:00
Andrew Kelley 27cbb44993
Merge pull request #949 from zig-lang/complex-math
Add initial complex-number support
2018-04-24 21:24:08 -04:00
Andrew Kelley 84391af7b8 convert NOTE to TODO so we catch it later
See #363

For Complex as a builtin type, see discussion in #949
2018-04-24 21:23:03 -04:00
Andrew Kelley 1d998d5dce clean up complex math tests 2018-04-24 21:14:12 -04:00
Andrew Kelley 13076d5f22 std.mem: add more slice manipulation functions
* add std.mem.trimLeft
 * add std.mem.trimRight
 * add std.mem.trimRight
 * add std.mem.lastIndexOfScalar
 * add std.mem.lastIndexOfAny
 * add std.mem.lastIndexOf
 * add std.mem.endsWith

closes #944

Thanks Braedon Wooding for the original PR
2018-04-24 20:53:36 -04:00
Alexandros Naskos 778b931bf3 Fixed comptime union void field access 2018-04-25 02:50:18 +03:00
Alexandros Naskos 182a9fad2d Added ArrayInfo, NullableInfo, PromiseInfo generation 2018-04-24 17:38:30 +03:00
Alexandros Naskos 09d7033d1d PointerInfo child is known at comptime 2018-04-24 17:08:45 +03:00
Alexandros Naskos 2d8553c853 Fixed PointerInfo generation 2018-04-24 17:01:20 +03:00
Alexandros Naskos 189e8e97bd PointerInfo child is a pointer to a TypeInfo union, still not working correctly 2018-04-24 16:50:36 +03:00
Alexandros Naskos 0e5fb035e3 Added (broken) pointer info, float info 2018-04-24 16:23:22 +03:00
Alexandros Naskos e9309d3b13 Fixed IntInfo generation. 2018-04-24 15:17:34 +03:00
Alexandros Naskos ec2a3ed500 Attempt at adding comptime union field access 2018-04-24 15:03:46 +03:00
Marc Tiehuis 0501e066b5 crypto throughput test now uses os.time module 2018-04-24 23:54:27 +12:00
Alexandros Naskos fb88f5a0d2 @typeInfo with void payloads now works! 2018-04-24 11:20:33 +03:00
Marc Tiehuis d5e99cc05e Add initial complex-number support
- Library type instead of builtin
 - All C complex functions implemented

Partial WIP: Needs more tests for edge cases.
2018-04-24 19:18:31 +12:00
Alexandros Naskos 7eab62325b One step towards @typeInfo 2018-04-24 01:49:22 +03:00
Andrew Kelley 15bf0c1541 fix interaction between defer and labeled break
closes #830
2018-04-23 18:06:33 -04:00
Andrew Kelley 89a4c373d3 fix bigint twos complement implementation
closes #948
2018-04-23 12:06:18 -04:00
Marc Tiehuis e5175d432e Fix release float printing errors
Fixes #564.
Fixes #669.
Fixes #928.
2018-04-23 17:22:51 +12:00