sema.addConstant: remove type parameter

Now that InternPool migration is finished, all values have types. So
only the value parameter is required.
This commit is contained in:
Andrew Kelley 2023-06-23 16:28:33 -07:00
parent 5fc5e4fbe0
commit 5288929ffd
2 changed files with 269 additions and 335 deletions

View File

@ -5503,7 +5503,7 @@ pub fn analyzeFnBody(mod: *Module, func_index: Fn.Index, arena: Allocator) SemaE
else
break :t arg_tv.ty;
const arg = try sema.addConstant(arg_tv.ty, arg_val);
const arg = try sema.addConstant(arg_val);
sema.inst_map.putAssumeCapacityNoClobber(inst, arg);
total_param_index += 1;
continue;
@ -5517,7 +5517,7 @@ pub fn analyzeFnBody(mod: *Module, func_index: Fn.Index, arena: Allocator) SemaE
else => |e| return e,
};
if (opt_opv) |opv| {
const arg = try sema.addConstant(param_ty, opv);
const arg = try sema.addConstant(opv);
sema.inst_map.putAssumeCapacityNoClobber(inst, arg);
total_param_index += 1;
runtime_param_index += 1;

File diff suppressed because it is too large Load Diff