mirror of https://github.com/m-labs/artiq.git
compiler: Consistently use llunit through llvm_ir_generator [nfc]
This commit is contained in:
parent
5dc3b3b28c
commit
5efeb2fea0
|
@ -209,7 +209,7 @@ class LLVMIRGenerator:
|
||||||
if for_return:
|
if for_return:
|
||||||
return llvoid
|
return llvoid
|
||||||
else:
|
else:
|
||||||
return ll.LiteralStructType([])
|
return llunit
|
||||||
elif types._is_pointer(typ):
|
elif types._is_pointer(typ):
|
||||||
return llptr
|
return llptr
|
||||||
elif types.is_function(typ):
|
elif types.is_function(typ):
|
||||||
|
@ -239,7 +239,7 @@ class LLVMIRGenerator:
|
||||||
if for_return:
|
if for_return:
|
||||||
return llvoid
|
return llvoid
|
||||||
else:
|
else:
|
||||||
return ll.LiteralStructType([])
|
return llunit
|
||||||
elif builtins.is_bool(typ):
|
elif builtins.is_bool(typ):
|
||||||
return lli1
|
return lli1
|
||||||
elif builtins.is_int(typ):
|
elif builtins.is_int(typ):
|
||||||
|
@ -1357,7 +1357,7 @@ class LLVMIRGenerator:
|
||||||
name="rpc.args")
|
name="rpc.args")
|
||||||
for index, arg in enumerate(args):
|
for index, arg in enumerate(args):
|
||||||
if builtins.is_none(arg.type):
|
if builtins.is_none(arg.type):
|
||||||
llargslot = self.llbuilder.alloca(ll.LiteralStructType([]),
|
llargslot = self.llbuilder.alloca(llunit,
|
||||||
name="rpc.arg{}".format(index))
|
name="rpc.arg{}".format(index))
|
||||||
else:
|
else:
|
||||||
llarg = self.map(arg)
|
llarg = self.map(arg)
|
||||||
|
|
Loading…
Reference in New Issue