reverted: removed box access from assignment
This commit is contained in:
parent
f590e3c42e
commit
0fe3fb68a6
|
@ -96,6 +96,8 @@ typedef struct BoxAccess_t {
|
||||||
// list of recursive box accesses
|
// list of recursive box accesses
|
||||||
// contains a list of BoxMembers (each specifying their own type, name and box type)
|
// contains a list of BoxMembers (each specifying their own type, name and box type)
|
||||||
GArray* member;
|
GArray* member;
|
||||||
|
// box variable to access
|
||||||
|
Variable* variable;
|
||||||
AST_NODE_PTR nodePtr;
|
AST_NODE_PTR nodePtr;
|
||||||
} BoxAccess;
|
} BoxAccess;
|
||||||
|
|
||||||
|
@ -263,7 +265,7 @@ typedef struct Variable_t {
|
||||||
union VariableImplementation {
|
union VariableImplementation {
|
||||||
VariableDeclaration declaration;
|
VariableDeclaration declaration;
|
||||||
VariableDefiniton definiton;
|
VariableDefiniton definiton;
|
||||||
BoxMember member;
|
BoxAccess member;
|
||||||
} impl;
|
} impl;
|
||||||
AST_NODE_PTR nodePtr;
|
AST_NODE_PTR nodePtr;
|
||||||
} Variable;
|
} Variable;
|
||||||
|
@ -484,22 +486,8 @@ typedef struct Branch_t {
|
||||||
// | Statements |
|
// | Statements |
|
||||||
// '------------------------------------------------'
|
// '------------------------------------------------'
|
||||||
|
|
||||||
typedef enum AssignmentKind_t {
|
|
||||||
// direct access to a variable
|
|
||||||
AssignmentKindVariable,
|
|
||||||
// access to a member of a box
|
|
||||||
// can be nested such as: foo.bar.kee
|
|
||||||
AssignmentKindBoxMember
|
|
||||||
} AssignmentKind;
|
|
||||||
|
|
||||||
// Can either be a direct variable access or
|
|
||||||
// a nested box member access
|
|
||||||
typedef struct Assignment_t {
|
typedef struct Assignment_t {
|
||||||
Variable* variable;
|
Variable* variable;
|
||||||
AssignmentKind kind;
|
|
||||||
union AssignmentImplementation_t {
|
|
||||||
BoxAccess accees;
|
|
||||||
} impl;
|
|
||||||
Expression value;
|
Expression value;
|
||||||
AST_NODE_PTR nodePtr;
|
AST_NODE_PTR nodePtr;
|
||||||
} Assignment;
|
} Assignment;
|
||||||
|
|
Loading…
Reference in New Issue