Andrew Kelley
a71fbe49cb
IR: add FnProto instruction
2016-12-18 19:40:26 -05:00
Andrew Kelley
e50ced44a2
IR: all structs anonymous
2016-12-18 16:56:50 -05:00
Andrew Kelley
d7a2b05a81
IR: introduce concept of lvalues
2016-10-23 00:21:29 -04:00
Andrew Kelley
633781e31d
empty function compiles successfully with IR
2016-09-30 20:12:00 -04:00
Andrew Kelley
4e2fa2d15b
*WIP*
2016-09-30 02:21:21 -04:00
Andrew Kelley
3239b3cb69
use size_t for indexes
...
protect against incorrect copies in debug mode
2016-09-19 11:54:01 -04:00
alter
cf9b21c09f
MacOSX compatibility
...
- Implemented some syscall for MacOSX
- tested on : El Capitan 10.11 x86_64
- make self hosted test run on macosx
- modified run_test so it does not fail when parseh throws
warnings (most of them are related to buildin types from
gcc that arent defined in header files and unions)
- making -mmacosx-version-min and -mios-version-min works like
gcc (command line paramers have precedence over enviroment variables)
2016-09-14 02:46:02 -04:00
Andrew Kelley
de7e88c38f
build: remove -Wmissing-prototypes
...
this causes errors with llvm's own h files which we have no control over.
2016-09-06 11:01:51 -04:00
Andrew Kelley
651dc31247
implement null as a literal type
2016-08-29 22:14:09 -07:00
Andrew Kelley
ed50bd1b65
progress toward stack trace printing
2016-08-17 20:11:04 -07:00
Andrew Kelley
0450b73e3e
std: add tests for mt32 and mt64
2016-07-28 20:14:57 -07:00
Andrew Kelley
7edef4f3fd
add beginning of print stack trace function
...
introduce std.debug and move std.assert to std.debug.assert
add mem.copy
2016-05-17 13:32:43 -07:00
Andrew Kelley
26718a619c
recognize ar program and pass --gc-sections to ld
...
See #54
2016-05-11 14:44:10 -07:00
Andrew Kelley
d92ae20f45
add hashmap to standard library
...
closes #22
2016-05-09 15:07:38 -07:00
Andrew Kelley
0c32b0b4ad
add list implementation to standard library
2016-05-08 01:34:00 -07:00
Andrew Kelley
01c46eef3a
std: separate str and cstr
2016-05-07 10:52:52 -07:00
Andrew Kelley
66ed7a5eb5
beginnings of network standard library code
2016-05-03 20:48:53 -07:00
Andrew Kelley
da406cb112
build: add test coverage target
2016-04-23 09:57:38 -07:00
Andrew Kelley
35362f8137
better parsing of C macros
...
See #88
2016-04-21 15:48:13 -07:00
Andrew Kelley
f4c7e1bf49
rearrange standard library a bit
2016-04-18 16:42:56 -07:00
Andrew Kelley
a177e30534
compile-time function evaluation of pure functions
2016-04-12 09:35:33 -07:00
Andrew Kelley
5dbc21b511
update cat example, refactor std
...
partial implementation of @err_name
2016-04-08 16:21:30 -07:00
Andrew Kelley
17a36859e7
build: std files each specify install destination
2016-03-01 19:00:03 -07:00
Andrew Kelley
9c3d7b628c
rename syscall.zig to linux.zig
2016-03-01 14:11:38 -07:00
Andrew Kelley
f1d338194e
rewrite how importing works
...
* Introduce the concept of packages. Closes #3
* Add support for error notes.
* Introduce `@import` and `@c_import` builtin functions and
remove the `import` and `c_import` top level declarations.
* Introduce the `use` top level declaration.
* Add `--check-unused` parameter to perform semantic
analysis and codegen on all top level declarations, not
just exported ones and ones referenced by exported ones.
* Delete the root export node and add `--library` argument.
2016-03-01 03:13:40 -07:00
Andrew Kelley
04cc59be65
update run_tests to work on windows
2016-02-17 20:44:07 -07:00
Andrew Kelley
06398a22d0
back to normal print specifiers
...
disable warnings for format specifiers on mingw since the
compiler emits bogus warnings
2016-02-16 21:43:38 -07:00
Andrew Kelley
6793548868
fix 64 bit integer printing for mingw
...
in order to do this I had to turn off -pedantic
2016-02-16 20:21:37 -07:00
Andrew Kelley
984e7d6cc7
first pass at linking on macos
2016-02-15 20:56:52 -07:00
Andrew Kelley
3664e8e4e2
use llvm-config to find llvm include dirs
2016-02-15 15:52:19 -07:00
Andrew Kelley
c8376af92d
add @ctz, @clz and compiler_rt implementation
2016-02-13 12:50:13 -07:00
Andrew Kelley
7828456b30
std: delete malloc and free
...
later we'll add a full featured allocator instead of this
2016-02-12 02:23:22 -07:00
Andrew Kelley
2bf6c28bc3
ability to cross compile
...
hello_libc.zig can produce a windows build
2016-02-11 01:33:27 -07:00
Andrew Kelley
1ff2edf67e
add "targets" command to list architectures, oses, abis
2016-02-10 15:41:50 -07:00
Andrew Kelley
bb4a532785
move os_get_random_bytes to os.zig
2016-02-04 01:00:54 -07:00
Andrew Kelley
a6d4335217
fix running tests when linking with libc
2016-02-03 23:07:55 -07:00
Andrew Kelley
11a0644365
basic support for building a test target
2016-02-03 18:02:01 -07:00
Andrew Kelley
fc5ffd32e9
build: prefer llvm-config
2016-02-01 22:38:55 -07:00
Andrew Kelley
c7eb8aaec5
build: fix release mode
2016-02-01 15:26:01 -07:00
Andrew Kelley
3f0062d7a9
Merge pull request #100 from MovingtoMars/float_print
...
basic float printing
2016-01-27 23:46:09 -07:00
MovingtoMars
dc08412895
basic float printing
2016-01-28 19:28:43 +13:00
Andrew Kelley
51ab9b03ce
Merge remote-tracking branch 'origin/master'
2016-01-27 21:11:53 -07:00
Andrew Kelley
b6354ddd5a
move AST rendering code to separate file
2016-01-27 21:10:38 -07:00
MovingtoMars
1a913f6bf2
simple malloc and free using mmap
2016-01-28 12:39:02 +13:00
Andrew Kelley
0278468479
upgrade to the libclang C++ API
...
c_import creates a tmp .h file and parses it with libclang,
reporting any errors found.
See #88
2016-01-27 00:01:49 -07:00
Andrew Kelley
32e2196257
number literal rework
2016-01-21 03:02:25 -07:00
Andrew Kelley
890714b8ca
Revert "delete parseh"
...
This reverts commit 18374ea8f1
.
2016-01-18 21:28:54 -07:00
Andrew Kelley
18374ea8f1
delete parseh
...
we'll have to switch to the clang C++ api anyway
we'll revive this code later
2016-01-15 14:16:07 -07:00
Andrew Kelley
a3c97081ca
add ?? maybe unwrapping binary operator
...
add null literal
fix number literal / maybe interactions
2016-01-07 03:23:38 -07:00
Andrew Kelley
5f0bfcac24
fix undefined reference to memcpy in release mode
...
when not depending on libc, we generate memcpy and memset
implementations.
2016-01-06 06:40:25 -07:00