Commit Graph

15 Commits (1a0081b763d145de8a89ab94aca400daa5666dac)

Author SHA1 Message Date
Andrew Kelley 1a0081b763 add peer type resolution for T and ?T
See #334
2017-04-22 11:45:04 -04:00
Andrew Kelley e3c524c1d4 rename `@ptrcast` to `@ptrCast` to follow convention 2017-04-21 10:39:13 -04:00
Raul Leal 5234016561 Add @offsetOf builtin function 2017-04-20 11:53:00 +00:00
Raul Leal 3266585606 Implicit cast from T to %?T
closes #171
2017-04-17 19:55:56 -04:00
Andrew Kelley 7611ed3484 allow implicit cast from `[N]T` to `&const []const T`
closes #296
2017-04-07 17:56:01 -04:00
Andrew Kelley f7e9d7aa5d ability to implicitly cast integer literal to &const Int
where Int is an integer type

also introduce `@intToPtr` builtin for converting a usize
to a pointer. users now have to use this instead of `(&T)(int)`.

closes #311
2017-04-07 15:35:38 -04:00
Andrew Kelley 273cebdf4d peer resolve types [N]T, [M]T as []const T
closes #125
2017-04-06 18:07:38 -04:00
Andrew Kelley 8fd0fddce5 zig build system progress
* In-progress os.ChildProcess.spawn implementation. See #204
 * Add explicit cast from integer to error. Closes #294
 * fix casting from error to integer
 * fix compiler crash when initializing variable to undefined
   with no type
2017-04-02 18:19:59 -04:00
Andrew Kelley f8e63c4584 change `@bitcast` to `@ptrcast`
See #290
2017-03-31 06:18:20 -04:00
Andrew Kelley 3ca027ca82 first pass at zig build system
* `zig build --export [obj|lib|exe]` changed to `zig build_obj`,
   `zig build_lib` and `zig build_exe` respectively.
 * `--name` parameter is optional when it can be inferred from the
   root source filename. closes #207
 * `zig build` now looks for `build.zig` which interacts with
   `std.build.Builder` to describe the targets, and then the zig
   build system prints TODO: build these targets. See #204
 * add `@bitcast` which is mainly used for pointer reinterpret
   casting and make explicit casting not do pointer reinterpretation.
   Closes #290
 * fix debug info for byval parameters
 * sort command line help options
 * `std.debug.panic` supports format string printing
 * add `std.mem.IncrementingAllocator`
 * fix const ptr to a variable with data changing at runtime.
   closes #289
2017-03-31 05:55:41 -04:00
Andrew Kelley af536ac343 introduce new test syntax
* remove setFnTest builtin
 * add test "name" { ... } syntax
 * remove --check-unused argument. functions are always lazy now.
2017-03-16 16:02:35 -04:00
Andrew Kelley a76558db26 fix behavior with reinterpreting constant memory 2017-03-14 21:38:27 -04:00
Andrew Kelley b258fdb532 add integer literal to pointer explicit cast
closes #227
2017-01-31 13:38:04 -05:00
Andrew Kelley 3b5e26b7f7 self hosted tests import std library 2017-01-05 03:57:48 -05:00
Andrew Kelley 6c9ec3688e IR testing: rename cases3 dir to cases 2016-12-26 02:49:30 -05:00