nac3artiq: correct global name for const object

This commit is contained in:
ychenfo 2022-05-16 02:50:42 +08:00
parent b9259b1907
commit 2cb725b7ac
1 changed files with 1 additions and 1 deletions

View File

@ -99,7 +99,7 @@ impl StaticValue for PythonValue {
_: &mut dyn CodeGenerator,
) -> BasicValueEnum<'ctx> {
ctx.module
.get_global(self.id.to_string().as_str())
.get_global(format!("{}_const", self.id).as_str())
.map(|val| val.as_pointer_value().into())
.unwrap_or_else(|| {
Python::with_gil(|py| -> PyResult<BasicValueEnum<'ctx>> {