Andrew Kelley
4f2d49fd13
std.zig.parse: fix parsing of doc comments after fields
...
closes #1404
2018-08-27 19:21:38 -04:00
Andrew Kelley
b92fac329e
Merge branch 'raulgrell-CastToCVoid'
2018-08-27 18:31:41 -04:00
Andrew Kelley
45d9d9f953
minor fixups
2018-08-27 18:31:28 -04:00
raulgrell
e2a9f2ef98
Allow implicit cast from *T and [*]T to ?*c_void
2018-08-27 23:13:57 +01:00
Andrew Kelley
c48be3a742
langref: document exporting a library
...
closes #1431
2018-08-27 17:44:58 -04:00
tgschultz
ecc5464024
Handle unions differently in std.fmt ( #1432 )
...
* Handle unions differently in std.fmt
Print the active tag's value in tagged unions. Untagged unions considered unsafe to print and treated like a pointer or an array.
2018-08-27 17:25:33 -04:00
Andrew Kelley
009e90f446
fix @typeInfo unable to distinguish compile error vs no-payload
...
closes #1421
closes #1426
2018-08-27 17:13:34 -04:00
Andrew Kelley
2f2215c9f4
this was intended to be included in the previous commit
2018-08-27 16:26:36 -04:00
Andrew Kelley
526d8425ab
fix false negative determining if function is generic
...
This solves the smaller test case of #1421 but the
other test case is still an assertion failure.
2018-08-27 16:14:48 -04:00
Andrew Kelley
68e2794e15
ir: const_ptr_pointee asserts that its return value is non-null
2018-08-26 13:13:26 -04:00
Andrew Kelley
6a3fad1d59
Revert "src/ir.cpp: check return value of `const_ptr_pointee` to protect against dereferencing null pointers;"
...
This reverts commit 0839ed1f94
.
I realized too late there is a better fix. See PR #1419
2018-08-26 13:04:58 -04:00
kristopher tate
0839ed1f94
src/ir.cpp: check return value of `const_ptr_pointee` to protect against dereferencing null pointers;
2018-08-26 13:02:09 -04:00
Andrew Kelley
8047f0eae2
fix llvm assertion failure when building std lib tests for macos
...
closes #1417
2018-08-26 02:36:18 -04:00
Andrew Kelley
526338b00f
document fixed-width integer types
...
closes #1280
2018-08-25 17:39:43 -04:00
Andrew Kelley
56a53021a1
Merge branch 'tgschultz-patch-3'
2018-08-25 17:28:40 -04:00
Andrew Kelley
2cce171448
add test for previous commit
2018-08-25 17:28:30 -04:00
tgschultz
61c0c6d502
Fixed compile error when passing enum to fmt
...
Caused by struct printing behavior. Enums are different enough from structs and unions that the field iteration behavior doesn't do what we want even if @memberName didn't error on enums.
2018-08-25 10:51:49 -05:00
Andrew Kelley
4003cd4747
Merge pull request #1406 from ziglang/macos-stack-traces
...
MacOS stack traces
closes #1365
2018-08-25 04:50:51 -04:00
Andrew Kelley
815950996d
Merge remote-tracking branch 'origin/master' into macos-stack-traces
2018-08-25 04:48:58 -04:00
Andrew Kelley
8aacfc8465
add workaround on macos for shared libraries
2018-08-25 04:37:55 -04:00
Andrew Kelley
02f5a9fa62
fix handling multiple extern vars with the same name
2018-08-25 03:55:59 -04:00
Andrew Kelley
b95ff12f2f
fix regressions
2018-08-25 03:40:47 -04:00
Andrew Kelley
ac36f98e72
fix stack traces on linux
2018-08-25 03:07:37 -04:00
Andrew Kelley
32901926f0
compilation unit cwd dir appears to be unnecessary on macos
2018-08-24 15:43:48 -04:00
Andrew Kelley
4e7c255e4d
macos stack traces have address-to-line translation
2018-08-24 14:55:55 -04:00
Andrew Kelley
bf1f91595d
std.debug: remove workaround for fixed bug
2018-08-24 13:00:28 -04:00
Andrew Kelley
6b31b178a6
fix regression from 2f7f7d815d
2018-08-24 12:59:31 -04:00
Andrew Kelley
95e197667e
macos stack traces have the compilation unit in them
2018-08-24 11:30:36 -04:00
Andrew Kelley
0a918aaa14
Merge pull request #1407 from ziglang/builtin-alignment-fix
...
Fix builtin alignment type
2018-08-24 10:42:43 -04:00
Marc Tiehuis
05f9b14fc2
Fix builtin alignment type
...
Closes #1235 .
2018-08-24 17:57:17 +12:00
Andrew Kelley
3a02ba9b82
fix error message for incorrect panic handler fn signature
...
closes #1353
2018-08-23 23:22:48 -04:00
Andrew Kelley
3173c90f14
macos stack traces: read debug info sections from .o files
2018-08-23 23:08:34 -04:00
Andrew Kelley
6c064cfd88
Merge pull request #1405 from shawnl/path-max
...
missing PATH_MAX change
2018-08-23 20:16:13 -04:00
Shawn Landden
2f7f7d815d
missing PATH_MAX change
2018-08-23 17:00:50 -07:00
Andrew Kelley
5c1ec20c9a
MacOS stack traces use the already mmapped executable
...
...rather than trying to find the executable on the file system.
Also use a more robust PIE offset calculation based on the
available metadata.
And for the last function, use the data that tells the end
rather than assuming 4K.
Also they print in a consistent way with Linux stack traces.
2018-08-23 16:23:33 -04:00
Andrew Kelley
327482c3a4
Merge pull request #1402 from ziglang/default-fp-ieee-strict
...
Default to strict IEEE floating point
2018-08-23 08:26:09 -04:00
Andrew Kelley
68dcdf1c86
Merge pull request #1401 from kristate/mem-testWriteIntImpl-u64
...
std/mem.zig: test writing u64 integers;
2018-08-23 08:25:26 -04:00
Marc Tiehuis
353419f82d
Default to strict IEEE floating point
...
Closes #1227 .
2018-08-23 22:54:46 +12:00
Andrew Kelley
8f96553be8
rename std.debug.ElfStackTrace to std.debug.DebugInfo
2018-08-22 21:35:49 -04:00
kristopher tate
e95345b3dc
std/mem.zig: test writing u64 integers;
2018-08-23 09:03:02 +09:00
Andrew Kelley
4b68ef45af
fix incorrectly generating an unused const fn global
...
closes #1277
2018-08-22 14:31:30 -04:00
Andrew Kelley
5aeb3217ee
fixup for previous commit
2018-08-22 14:24:48 -04:00
Raul Leal
87b10400c2
allow implicit cast from *[N]T to ?[*]T ( #1398 )
...
* allow implicit cast from *[N]T to ?[*]T
2018-08-22 13:12:08 -04:00
Andrew Kelley
3d780cf2ef
Merge branch 'shawnl-path_max'
...
This does a proof of concept of changing most file system APIs to not
require an allocator and remove the possibility of failure via
OutOfMemory.
This also does most of the work of #534 .
2018-08-21 21:02:01 -04:00
Andrew Kelley
3dd1026c8b
fix docs on windows
2018-08-21 21:01:37 -04:00
Andrew Kelley
02ba4b1678
Merge branch 'master' into shawnl-path_max
2018-08-21 20:56:28 -04:00
Andrew Kelley
478db39866
fix selfExePath on macosx
2018-08-21 20:52:21 -04:00
Andrew Kelley
b2917e6be0
Revert "Merge branch 'mtn-translate-c-enum-vals'"
...
This reverts commit 937b822fa9
, reversing
changes made to dd4b13ac03
.
Tests failing on Windows.
Re-opens #1360
2018-08-21 20:50:03 -04:00
Andrew Kelley
ea1b21dbdb
fix linux
...
* error.BadFd is not a valid error code. it would always be a bug to
get this error code.
* merge error.Io with existing error.InputOutput
* merge error.PathNotFound with existing error.FileNotFound.
Not all OS's support both.
* add os.File.openReadC
* add error.BadPathName for windows file operations with invalid
characters
* add os.toPosixPath to help stack allocate a null terminating byte
* add some TODOs for other functions to investigate removing the
allocator requirement
* optimize some implementations to use the alternate functions when
a null byte is already available
* add a missing error.SkipZigTest
* os.selfExePath uses a non-allocating API
* os.selfExeDirPath uses a non-allocating API
* os.path.real uses a non-allocating API
* add os.path.realAlloc and os.path.realC
* convert many windows syscalls to use the W versions (See #534 )
2018-08-21 20:31:50 -04:00
Andrew Kelley
51852d2587
fix windows
2018-08-21 16:07:28 -04:00