diff options
Diffstat (limited to 'tests/diagnostics/nested-func.slang')
| -rw-r--r-- | tests/diagnostics/nested-func.slang | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/tests/diagnostics/nested-func.slang b/tests/diagnostics/nested-func.slang new file mode 100644 index 000000000..42634cb8a --- /dev/null +++ b/tests/diagnostics/nested-func.slang @@ -0,0 +1,12 @@ +//DIAGNOSTIC_TEST:SIMPLE(filecheck=CHECK): + + +struct VertexOutput{float Input;} +float4 fragmentMain(VertexOutput vertex) : SV_Target +{ + // CHECK: ([[# @LINE+1]]): error 30102 + static float GetValue(int val) { return vertex.Input; } // Simplified example + float a = GetValue(vertex.Input); + + // etc +} |
