[spv-out] support function arguments as pointers

This commit is contained in:
Dzmitry Malyshau committed 2021-04-24 01:54:48 -04:00
1 parent 34b830da17
commit 77a64da189
1 file changed
+4
+4
View File
@@ -2298,6 +2298,10 @@ impl Writer {
let local_var = &function.variables[&variable];
break (local_var.id, spirv::StorageClass::Function);
}
crate::Expression::FunctionArgument(index) => {
let id = function.parameters[index as usize].result_id.unwrap();
break (id, spirv::StorageClass::Function);
}
ref other => unimplemented!("Unexpected pointer expression {:?}", other),
}
};