X-Git-Url: http://git.tdb.fi/?a=blobdiff_plain;f=source%2Fglsl%2Fsyntax.h;h=3fb848d2ceb81a91fdc07ab19f0e072b0b71010c;hb=b482f6d59aca2b4f1d9e2cbcc0f596d62c057509;hp=7764712498bb3106666f3e8bee98de72881516df;hpb=9d798ac368bfd236a7632a3a15e51bd1112ea63d;p=libs%2Fgl.git diff --git a/source/glsl/syntax.h b/source/glsl/syntax.h index 77647124..3fb848d2 100644 --- a/source/glsl/syntax.h +++ b/source/glsl/syntax.h @@ -6,9 +6,8 @@ #include #include #include -#include "extension.h" +#include "features.h" #include "sourcemap.h" -#include "uniform.h" #pragma push_macro("interface") #undef interface @@ -107,10 +106,13 @@ struct Block: Node { NodeList body; bool use_braces; + bool anonymous; std::map types; std::map variables; + Block *parent; Block(); + Block(const Block &); virtual Block *clone() const { return new Block(*this); } virtual void visit(NodeVisitor &); @@ -143,6 +145,7 @@ struct VariableReference: Expression VariableDeclaration *declaration; VariableReference(); + VariableReference(const VariableReference &); virtual VariableReference *clone() const { return new VariableReference(*this); } virtual void visit(NodeVisitor &); @@ -154,6 +157,9 @@ struct MemberAccess: Expression std::string member; VariableDeclaration *declaration; + MemberAccess(); + MemberAccess(const MemberAccess &); + virtual MemberAccess *clone() const { return new MemberAccess(*this); } virtual void visit(NodeVisitor &); }; @@ -187,6 +193,7 @@ struct Assignment: BinaryExpression VariableDeclaration *target_declaration; Assignment(); + Assignment(const Assignment &); virtual Assignment *clone() const { return new Assignment(*this); } virtual void visit(NodeVisitor &); @@ -200,6 +207,7 @@ struct FunctionCall: Expression NodeArray arguments; FunctionCall(); + FunctionCall(const FunctionCall &); virtual FunctionCall *clone() const { return new FunctionCall(*this); } virtual void visit(NodeVisitor &); @@ -282,6 +290,7 @@ struct VariableDeclaration: Statement NodePtr layout; VariableDeclaration(); + VariableDeclaration(const VariableDeclaration &); virtual VariableDeclaration *clone() const { return new VariableDeclaration(*this); } virtual void visit(NodeVisitor &); @@ -377,8 +386,7 @@ struct Stage std::map in_variables; std::map out_variables; std::map locations; - Version required_version; - std::vector required_extensions; + Features required_features; Stage(Type);