https://github.com/shader-slang/slang
Raw File
Tip revision: d8f4c9424c69a3d406fabf56a25dd3eda4bc7d51 authored by Sai Praveen Bangaru on 21 October 2023, 01:21:30 UTC
Fix issue with transposing `IRMakeVector` with non-singleton operands (#3280)
Tip revision: d8f4c94
undef.slang
//TEST:SIMPLE:
// #undef support

// warning: undef of something not defined
#undef FOO

#define BAR 1.0f

float foo() { return BAR + 2.0; }

#ifdef BAR
// okay
#else
#error not okay
#endif

#undef BAR

typedef float BAR;

BAR bar() { return 2.0; }

#if !defined(BAR)
// okay
#else
#error not okay
#endif


#define FOO

#undef FOO
back to top