-
Notifications
You must be signed in to change notification settings - Fork 222
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Report error on nested functions. (#5792)
* Report error on nested functions. * Fix. --------- Co-authored-by: Ellie Hermaszewska <ellieh@nvidia.com>
- Loading branch information
1 parent
2bec21e
commit 525412c
Showing
3 changed files
with
35 additions
and
2 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -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 | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters