Define new variables after evaluating the initialization expression.
TRAC #13627
GLSL allows to write things like "float x = x;" where a new variable x is defined and the value of an existing variable x is assigned. HLSL uses C semantics (the new variable is created before the assignment is evaluated), so we need to convert this to "float t = x, x = t;".
Signed-off-by: Daniel Koch
Author: Nicolas Capens
git-svn-id: https://angleproject.googlecode.com/svn/trunk@478 736b8ea6-26fd-11df-bfd4-992fa37f6226
diff --git a/src/compiler/OutputHLSL.h b/src/compiler/OutputHLSL.h
index dc3c482..ddbd077 100644
--- a/src/compiler/OutputHLSL.h
+++ b/src/compiler/OutputHLSL.h
@@ -120,7 +120,7 @@
ScopeBracket mScopeBracket;
unsigned int mScopeDepth;
- int mArgumentIndex; // For creating unique argument names
+ int mUniqueIndex; // For creating unique names
};
}