Otherwise, in the added test, we get:
``` vkd3d-compiler: vkd3d-shader/hlsl.c:452: hlsl_init_deref_from_index_chain: Assertion `chain' failed. ```
because on the path that triggers the following error:
``` E5002: Wrong type for argument 1 of 'tex3D': expected 'sampler' or 'sampler3D', but got 'sampler2D'. ```
a NULL params.resource is passed to hlsl_new_resource_load() and then to hlsl_init_deref_from_index_chain().