| Age | Commit message (Collapse) | Author |
|
* `type_size_store` is no longer a thing. loading and storing a pointer
to a value may dereference up to `@sizeOf(T)` bytes, even for
integers such as `u24`.
* fix `types_have_same_zig_comptime_repr` to not think that the
same `ZigTypeId` means the `ConstExprValue` neccesarily has the
same representation.
* implement `buf_write_value_bytes` and `buf_read_value_bytes` for
`ContainerLayoutPacked`
closes #1120
|
|
this adds the prototype of panic to @import("builtin")
and then uses it to do an implicit cast of the panic
function to this prototype, rather than redoing all the
implicit cast logic.
closes #1894
closes #1895
|
|
* Fixes breaches of the guarantee that `@sizeOf(T) >= @alignOf(T)`
* Fixes std.mem.secureZero for integers where this guarantee previously
was breached
* Fixes std.mem.Allocator for integers where this guarantee previously
was breached
Closes #1851
Closes #1864
|
|
See #1059
|
|
see #1059
|
|
See #1059
|
|
See #1059
|
|
|
|
also vectors and arrays now use the same ConstExprVal representation
See #903
|
|
See #903
* create with `@Vector(len, ElemType)`
* only wrapping addition is implemented
This feature is far from complete; this is only the beginning.
|
|
This commit contains everything from the copy-elision-2
branch that does not have to do with copy elision directly,
but is generally useful for master branch.
* All const values know their parents, when applicable, not
just structs and unions.
* Null pointers in const values are represented explicitly,
rather than as a HardCodedAddr value of 0.
* Rename "maybe" to "optional" in various code locations.
* Separate DeclVarSrc and DeclVarGen
* Separate PtrCastSrc and PtrCastGen
* Separate CmpxchgSrc and CmpxchgGen
* Represent optional error set as an integer, using the 0 value.
In a const value, it uses nullptr.
* Introduce type_has_one_possible_value and use it where applicable.
* Fix debug builds not setting memory to 0xaa when storing
undefined.
* Separate the type of a variable from the const value of a variable.
* Use copy_const_val where appropriate.
* Rearrange structs to pack data more efficiently.
* Move test/cases/* to test/behavior/*
* Use `std.debug.assertOrPanic` in behavior tests instead of
`std.debug.assert`.
* Fix outdated slice syntax in docs.
|
|
the representation of the const expr val in zig, and the
type that we tell LLVM it is.
|
|
fixes a compiler crash when building
https://github.com/AndreaOrru/zen
|
|
closes #1541
|
|
See #1121
|
|
We were caching the ConstExprValue of string literals,
which works if you can never modify ConstExprValues.
This premise is broken with `comptime var ...`.
So I implemented an optimization in ConstExprValue
arrays, where it stores a `Buf *` directly rather
than an array of ConstExprValues for the elements,
and then similar to array of undefined, it is
expanded into the canonical form when necessary.
However many operations can happen directly on the
`Buf *`, which is faster.
Furthermore, before a ConstExprValue array is expanded
into canonical form, it removes itself from the string
literal cache. This fixes the issue, because before an
array element is modified it would have to be expanded.
closes #1076
|
|
closes #1178
|
|
closes #1248
closes #1052
closes #1154
|
|
zig returned the wrong alignment for coroutine promises
in some cases
|
|
closes #1283
|
|
|
|
...zig run, zig build, compiler_rt.a, and builtin.a
|
|
also panic instead of emitting bad code for returning small structs
See #1481
|
|
|
|
|
|
closes #902
|
|
from a fn defined inside it. closes #876
|
|
|
|
|
|
|
|
closes #834
|
|
|
|
* fix wrong implicit cast for `@IntType` bit_count parameter.
* fix incorrect docs for `@IntType` bit_count parameter.
closes #1242
closes #745
closes #1240
|
|
closes #1202
|
|
|
|
|
|
* enable slicing for single-item ptr to arrays
* disable slicing for other single-item pointers
* enable indexing for single-item ptr to arrays
* disable indexing for other single-item pointers
see #770
closes #386
|
|
add pointer arithmetic for unknown length pointer
|
|
both ir.cpp and analyze.cpp have a function resolve_inferred_error_set,
which is a nearly exact copy-paste. This commit removes the one in ir.cpp
and exposes then one in analyze.cpp. This also allows us to make
analyze_fn_body local to analyze.cpp, as it is not used anywhere in
ir.cpp after this change
|
|
|
|
* you can label suspend blocks
* labeled break supports suspend blocks
See #803
|
|
See #821
Now the code works correctly, but error return traces are missing
the frames from coroutines.
|
|
closes #828
|
|
coro return was reading from a value that coro await was
writing to. that wasn't how it was designed to work, it
was an implementation mistake.
this commit also has some work-in-progress code for fixing
error return traces across suspend points.
|
|
closes #639
|
|
closes #384
|
|
but it has bugs
|
|
this one doesn't work either
|
|
See #727
|
|
See #727
|