Add support for 'k', 'M', and 'G' suffixes to integer constants.

(Denoting units of 1024, 1024*1024, and 1024*1024*1024, respectively.)

Issue #128.
This commit is contained in:
Matt Pharr
2012-01-06 14:47:47 -08:00
parent 11033e108e
commit 8da9be1a09
5 changed files with 83 additions and 20 deletions

View File

@@ -0,0 +1,14 @@
export uniform int width() { return programCount; }
export void f_fu(uniform float RET[], uniform float aFOO[], uniform float b) {
unsigned int32 a = 3G;
a -= 2G;
a -= 1024M;
RET[programIndex] = a;
}
export void result(uniform float RET[]) {
RET[programIndex] = 0;
}