ability to slice an undefined pointer at compile time if the len is 0
This commit is contained in:
@@ -4201,6 +4201,7 @@ static LLVMValueRef gen_const_val(CodeGen *g, ConstExprValue *const_val, const c
|
||||
continue;
|
||||
}
|
||||
ConstExprValue *field_val = &const_val->data.x_struct.fields[i];
|
||||
assert(field_val->type != nullptr);
|
||||
LLVMValueRef val = gen_const_val(g, field_val, "");
|
||||
fields[type_struct_field->gen_index] = val;
|
||||
make_unnamed_struct = make_unnamed_struct || is_llvm_value_unnamed_type(field_val->type, val);
|
||||
|
||||
Reference in New Issue
Block a user