HLSL: Support 1.#INF and -1.#INF syntax.

This commit is contained in:
John Kessenich 2017-04-12 13:26:57 -06:00
parent b5e739c20e
commit 776c515ea5
8 changed files with 256 additions and 16 deletions

View file

@ -92,7 +92,7 @@ namespace glslang {
class TPpToken {
public:
TPpToken() : space(false), ival(0), dval(0.0), i64val(0)
TPpToken() : space(false), i64val(0)
{
loc.init();
name[0] = 0;
@ -108,10 +108,14 @@ public:
bool operator!=(const TPpToken& right) { return ! operator==(right); }
TSourceLoc loc;
bool space; // true if a space (for white space or a removed comment) should also be recognized, in front of the token returned
int ival;
double dval;
long long i64val;
bool space; // true if a space (for white space or a removed comment) should also be recognized, in front of the token returned
union {
int ival;
double dval;
long long i64val;
};
char name[MaxTokenLength + 1];
};