mirror of
https://github.com/Ed94/Odin.git
synced 2026-08-02 12:48:14 +00:00
fix packed gep loads with wrong alignment
This commit is contained in:
+1
-1
@@ -4315,7 +4315,7 @@ gb_internal bool correct_single_type_alias(CheckerContext *c, Entity *e) {
|
|||||||
|
|
||||||
gb_internal bool correct_type_alias_in_scope_backwards(CheckerContext *c, Scope *s) {
|
gb_internal bool correct_type_alias_in_scope_backwards(CheckerContext *c, Scope *s) {
|
||||||
bool correction = false;
|
bool correction = false;
|
||||||
for (u32 n = s->elements.capacity, i = n-1; i < n; i--) {
|
for (u32 n = s->elements.count, i = n-1; i < n; i--) {
|
||||||
auto const &entry = s->elements.entries[i];
|
auto const &entry = s->elements.entries[i];
|
||||||
Entity *e = entry.value;
|
Entity *e = entry.value;
|
||||||
if (entry.hash && e != nullptr) {
|
if (entry.hash && e != nullptr) {
|
||||||
|
|||||||
@@ -66,6 +66,7 @@ struct lbProcedure;
|
|||||||
struct lbValue {
|
struct lbValue {
|
||||||
LLVMValueRef value;
|
LLVMValueRef value;
|
||||||
Type *type;
|
Type *type;
|
||||||
|
bool is_packed;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
@@ -948,6 +948,7 @@ gb_internal void set_base_type(Type *t, Type *base) {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
gb_internal Type *alloc_type(TypeKind kind) {
|
gb_internal Type *alloc_type(TypeKind kind) {
|
||||||
// gbAllocator a = heap_allocator();
|
// gbAllocator a = heap_allocator();
|
||||||
gbAllocator a = permanent_allocator();
|
gbAllocator a = permanent_allocator();
|
||||||
|
|||||||
Reference in New Issue
Block a user