Add some CPP tests.
git-svn-id: https://cvs.khronos.org/svn/repos/ogl/trunk/ecosystem/public/sdk/tools/glslang@20457 e7fa87d3-cd2b-0410-9028-fcbf551c1848
This commit is contained in:
55
Test/cppIndent.vert
Normal file
55
Test/cppIndent.vert
Normal file
@@ -0,0 +1,55 @@
|
||||
#define ON
|
||||
|
||||
float sum = 0.0;
|
||||
|
||||
void main()
|
||||
{
|
||||
|
||||
#ifdef ON
|
||||
//yes
|
||||
sum += 1.0;
|
||||
#endif
|
||||
|
||||
#ifdef OFF
|
||||
//no
|
||||
sum += 20.0;
|
||||
#endif
|
||||
|
||||
#if defined(ON)
|
||||
//yes
|
||||
sum += 300.0;
|
||||
#endif
|
||||
|
||||
#if defined(OFF)
|
||||
//no
|
||||
sum += 4000.0;
|
||||
#endif
|
||||
|
||||
#if !defined(ON)
|
||||
//no
|
||||
sum += 50000.0;
|
||||
#endif
|
||||
|
||||
#if !defined(OFF)
|
||||
//yes
|
||||
sum += 600000.0;
|
||||
#endif
|
||||
|
||||
#if defined (ON) && defined (OFF)
|
||||
//no
|
||||
sum += 7000000.0;
|
||||
#endif
|
||||
|
||||
#if defined ( ON ) && ! defined(OFF)
|
||||
//yes
|
||||
sum += 80000000.0;
|
||||
#endif
|
||||
|
||||
#if defined(OFF) || defined(ON)
|
||||
//yes
|
||||
sum += 900000000.0;
|
||||
#endif
|
||||
|
||||
// sum should be 980600301.0
|
||||
gl_Position = vec4(sum);
|
||||
}
|
||||
Reference in New Issue
Block a user