diff --git a/spirv_glsl.cpp b/spirv_glsl.cpp index afe18fb2..fad1132e 100644 --- a/spirv_glsl.cpp +++ b/spirv_glsl.cpp @@ -10306,13 +10306,13 @@ string CompilerGLSL::access_chain_internal(uint32_t base, const uint32_t *indice // add yet another virtual interface just for this. auto intptr_expr = join("reinterpret_cast<", type_to_glsl(tmp_type), ">(", expr, ")"); intptr_expr += join(" + ", to_enclosed_unpacked_expression(index), " * ", - get_decoration(ptr_type_id, DecorationArrayStride)); + get_decoration(ptr_type_id, DecorationArrayStride)); if (flags & ACCESS_CHAIN_PTR_CHAIN_CAST_TO_SCALAR_BIT) { is_packed = true; expr = join("*reinterpret_cast(", intptr_expr, ")"); + " *>(", intptr_expr, ")"); } else {