HLSL: 1) Implement lookahead buffers/stacks for token advance/recede, 2) use it for cast operation.
The grammar now accepts type casts, like "(int)x", but that has to be disambiguated from "(a + b)", needed deeper lookahead and backing up than what existed so far.
This commit is contained in:
@@ -73,6 +73,7 @@ INSTANTIATE_TEST_CASE_P(
|
||||
ToSpirv, HlslCompileTest,
|
||||
::testing::ValuesIn(std::vector<FileNameEntryPointPair>{
|
||||
{"hlsl.assoc.frag", "PixelShaderFunction"},
|
||||
{"hlsl.cast.frag", "PixelShaderFunction"},
|
||||
{"hlsl.float1.frag", "PixelShaderFunction"},
|
||||
{"hlsl.float4.frag", "PixelShaderFunction"},
|
||||
{"hlsl.intrinsics.frag", "PixelShaderFunction"},
|
||||
|
||||
Reference in New Issue
Block a user