v.gen.c: do not use precomputed const values in -usecache mode (fix `v test-all` on M1)
parent
3f5e3c4bfe
commit
24c59881f5
|
@ -4905,9 +4905,11 @@ fn (mut g Gen) const_decl(node ast.ConstDecl) {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
if ct_value := field.comptime_expr_value() {
|
if g.pref.build_mode != .build_module {
|
||||||
if g.const_decl_precomputed(field.mod, name, ct_value, field.typ) {
|
if ct_value := field.comptime_expr_value() {
|
||||||
continue
|
if g.const_decl_precomputed(field.mod, name, ct_value, field.typ) {
|
||||||
|
continue
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if field.is_simple_define_const() {
|
if field.is_simple_define_const() {
|
||||||
|
|
Loading…
Reference in New Issue