https://bugs.winehq.org/show_bug.cgi?id=55361
Bug ID: 55361 Summary: Preprocessor does not handle macros used from other macros Product: vkd3d Version: 1.8 Hardware: x86-64 OS: Linux Status: NEW Severity: normal Priority: P2 Component: hlsl Assignee: wine-bugs@winehq.org Reporter: bunglehead@gmail.com Distribution: ---
Created attachment 74941 --> https://bugs.winehq.org/attachment.cgi?id=74941 test
Attaching a test that currently fails with:
E5005: Identifier "a" is not declared.
Preprocessed function looks like this:
vkd3d:547664:trace:preproc_lexer_parse float4 func ( float4 arg ) vkd3d:547664:trace:preproc_lexer_parse { vkd3d:547664:trace:preproc_lexer_parse return ( ( a . r ) + arg . b ) ; vkd3d:547664:trace:preproc_lexer_parse }
So nested macro is using argument name as is, instead of using actual name that outer macro was use with.