6889 Commits

Author SHA1 Message Date
Andrew Kelley
018a89c7a1
async functions return void, no more GetSize resume block 2019-07-26 17:07:19 -04:00
Andrew Kelley
7b3686861f
@frameSize works via PrefixData 2019-07-25 22:24:01 -04:00
Andrew Kelley
538c0cd225
implement @frameSize 2019-07-25 15:05:55 -04:00
Andrew Kelley
70bced5dcf
implement @frame and @Frame 2019-07-25 01:47:56 -04:00
Andrew Kelley
ead2d32be8
calling an inferred async function 2019-07-25 00:03:06 -04:00
Andrew Kelley
9e11f67f0d
add test for previous commit 2019-07-24 15:05:39 -04:00
Michael Dusan
8e4f3a6f15 align src for IrInstructionArrayToVector
closes #2942
2019-07-24 15:04:32 -04:00
Andrew Kelley
e220812f2f
implement local variables in async functions 2019-07-24 02:59:51 -04:00
Andrew Kelley
19ee495750
add error for function with ccc indirectly calling async function 2019-07-23 19:35:41 -04:00
Andrew Kelley
7e9760de10
inferring async from async calls 2019-07-23 18:54:45 -04:00
Timon Kruiper
59850c1ce1 Fixed an integer overflow in zig fmt and added testcase 2019-07-23 14:51:30 -04:00
Vexu
57aa8997bd fix escape sequence rendering 2019-07-23 14:49:19 -04:00
Andrew Kelley
317d1ecb2c
Merge remote-tracking branch 'origin/master' into rewrite-coroutines 2019-07-22 14:37:08 -04:00
Andrew Kelley
fcadeb50c0
fix multiple coroutines existing clobbering each other 2019-07-22 14:36:14 -04:00
Andrew Kelley
650e07ebd9
fix suspend at end of function 2019-07-22 13:04:22 -04:00
Andrew Kelley
16be70cbbf
compiler-rt: add __muldi3 2019-07-22 12:49:26 -04:00
Andrew Kelley
bc31c1280e
disable segfault handler when panicking
this prevents a segfault in stack trace printing to activate the
segfault handler.
2019-07-22 12:41:59 -04:00
Andrew Kelley
a3327f0fbd
fix usingnamespace analyzing the expression multiple times 2019-07-22 12:33:24 -04:00
Andrew Kelley
5b69a9cd83
disable segfault handler when panicking
this prevents a segfault in stack trace printing to activate the
segfault handler.
2019-07-22 12:15:16 -04:00
Andrew Kelley
d6d0bb0542
zig build: adjust DESTDIR logic
now if DESTDIR is provided then the default install prefix is /usr.
otherwise the default install prefix is still zig-cache directly.

DESTDIR is prepended to the prefix to match what make install does.
2019-07-22 10:45:59 -04:00
Andrew Kelley
32d0ac1355
fix wrong calling convention on async resume 2019-07-22 00:07:48 -04:00
Andrew Kelley
59bf9ca58c
implement async function parameters 2019-07-21 23:27:47 -04:00
Andrew Kelley
11bd50f2b2
implement coroutine resume 2019-07-21 20:54:08 -04:00
Andrew Kelley
78e03c466c
simple async function passing test 2019-07-21 19:56:37 -04:00
Andrew Kelley
77c2ac3fcd
zig build: support DESTDIR environment variable
closes #2929
2019-07-21 18:04:23 -04:00
Andrew Kelley
56c08eb302
returning from async fn adds bad resume safety 2019-07-21 17:17:44 -04:00
Andrew Kelley
6053ca4f69
fix not jumping to entry 2019-07-21 17:10:16 -04:00
Andrew Kelley
27a5f2c4fa
remove errors for async calling convention 2019-07-21 16:43:43 -04:00
Andrew Kelley
72e983670e
simple async function call working 2019-07-21 16:21:16 -04:00
Andrew Kelley
a2e1be0346
docs: don't try to run the undefined behavior example test 2019-07-20 13:59:18 -04:00
Andrew Kelley
2c1e955de7
always give the type to byval attribute 2019-07-20 13:32:50 -04:00
Andrew Kelley
54e716afdc
remove coroutines implementation and promise type 2019-07-19 18:18:44 -04:00
Andrew Kelley
05454123d4
update clang driver code to llvm9
upstream commit 1931d3cb20a00da732c5210b123656632982fde0
2019-07-19 18:07:31 -04:00
Andrew Kelley
f429f4dcab
Merge branch 'fengb-tokenize-ampamp'
closes #2723
closes #2660
2019-07-19 17:55:12 -04:00
Andrew Kelley
8ea8cff491
slightly simpler implementation 2019-07-19 17:54:06 -04:00
Benjamin Feng
111d3792e0
Docgen invalid for && 2019-07-19 17:11:58 -04:00
Benjamin Feng
484f8a4cc2
Switch old switch / @TagType() to use inferred enums 2019-07-19 17:11:58 -04:00
Benjamin Feng
4708fb23c0
Generate parse error from && 2019-07-19 17:11:58 -04:00
Benjamin Feng
d4ff27180b
Tokenize '&&' as AmpersandAmpersand 2019-07-19 17:11:58 -04:00
Andrew Kelley
af8661405b
fix usingnamespace
It used to be that usingnamespace was only allowed at top level. This
made it OK to put the state inside the AST node data structure. However,
now usingnamespace can occur inside any aggregate data structure, and
therefore the state must be in the TopLevelDeclaration rather than in
the AST node.

There were two other problems with the usingnamespace implementation:

 * It was passing the wrong destination ScopeDecl, so it could cause an
   incorrect error such as "import of file outside package path".
 * When doing `usingnamespace` on a file that already had
   `pub usingnamespace` in it would "steal" the usingnamespace, causing
   incorrect "use of undeclared identifier" errors in the target file.

closes #2632
closes #2580
2019-07-19 16:56:44 -04:00
Andrew Kelley
70e05c67ce
update libcxx to llvm9
upstream commit 1931d3cb20a00da732c5210b123656632982fde0
2019-07-19 16:55:59 -04:00
Andrew Kelley
dab0cf6428
update libunwind to llvm9
upstream commit 1931d3cb20a00da732c5210b123656632982fde0
2019-07-19 16:54:00 -04:00
Andrew Kelley
2117fbdae3
update C headers to llvm9
upstream commit 1931d3cb20a00da732c5210b123656632982fde0
2019-07-19 16:50:45 -04:00
Andrew Kelley
1d07bbbef2
zig build: add valgrind cli options 2019-07-18 20:03:38 -04:00
Andrew Kelley
70da0762f7
better riscv syscalls 2019-07-18 18:15:50 -04:00
Michael Dusan
e5d032982e closes #2916 2019-07-18 16:42:56 -04:00
Andrew Kelley
03a3b1ca39
riscv workarounds for llvm not having good asm integration 2019-07-18 15:20:58 -04:00
Andrew Kelley
a3854d042e
basic riscv support
llvm is giving me `error: couldn't allocate output register for
constraint '{a0}'` which is a bug that needs to be fixed upstream.
2019-07-18 15:03:21 -04:00
Andrew Kelley
07f0de6a8a
compiler-rt: add __muldi3 2019-07-18 13:54:22 -04:00
Andrew Kelley
afbf99c846
riscv musl: only add the +a feature 2019-07-18 12:28:24 -04:00