- replaced 'vector<2>' and 'vector<3>' with 'vector2' and 'vector3'.

- added initializer syntax for vectors. A vector can be set with vectorvar = (x,y,z); for a 3-dimensional vector and vectorvar = (x, y); for a 2-dimensional one.
This commit is contained in:
Christoph Oelckers 2016-10-28 01:14:21 +02:00
parent 286f9510d4
commit 3fa315aaea
8 changed files with 42 additions and 25 deletions

View file

@ -98,6 +98,7 @@ enum EZCCTreeNodeType
AST_Default,
AST_FlagStmt,
AST_PropertyStmt,
AST_VectorInitializer,
NUM_AST_NODE_TYPES
};
@ -385,6 +386,11 @@ struct ZCC_ExprTrinary : ZCC_Expression
ZCC_Expression *Right;
};
struct ZCC_VectorInitializer : ZCC_Expression
{
ZCC_Expression *X, *Y, *Z;
};
struct ZCC_Statement : ZCC_TreeNode
{
};