]> git.tdb.fi Git - libs/gl.git/blobdiff - source/glsl/syntax.cpp
Assign a result type to all expressions
[libs/gl.git] / source / glsl / syntax.cpp
index e20d6c262eae2525a0a979922c800e9956f39f18..d7eec3da4bf680cbf4125d0cb747feccd54af38d 100644 (file)
@@ -94,7 +94,9 @@ void Block::visit(NodeVisitor &visitor)
 
 
 Expression::Expression():
-       oper(0)
+       oper(0),
+       type(0),
+       lvalue(false)
 { }
 
 
@@ -347,7 +349,8 @@ void InterfaceBlock::visit(NodeVisitor &visitor)
 
 
 FunctionDeclaration::FunctionDeclaration():
-       definition(0)
+       definition(0),
+       return_type_declaration(0)
 { }
 
 FunctionDeclaration::FunctionDeclaration(const FunctionDeclaration &other):
@@ -356,7 +359,8 @@ FunctionDeclaration::FunctionDeclaration(const FunctionDeclaration &other):
        name(other.name),
        parameters(other.parameters),
        body(other.body),
-       definition(other.definition==&other ? this : 0)
+       definition(other.definition==&other ? this : 0),
+       return_type_declaration(0)
 { }
 
 void FunctionDeclaration::visit(NodeVisitor &visitor)