]> git.tdb.fi Git - libs/gl.git/blobdiff - source/glsl/parser.h
Add some documentation to the GLSL compiler
[libs/gl.git] / source / glsl / parser.h
index cdb57ebc5b48850bae81f4af251e5a841b669504..9ab1232aaa0d9ad7aec82b24ee873b8b4e998e16 100644 (file)
@@ -41,6 +41,7 @@ private:
 
        std::string expect_type();
        std::string expect_identifier();
+       int expect_integer();
        bool check(const std::string &);
 
        static bool is_interface_qualifier(const std::string &);
@@ -63,12 +64,14 @@ private:
        RefPtr<Import> parse_import();
        RefPtr<Precision> parse_precision();
        RefPtr<Layout> parse_layout();
-       void parse_block(Block &, bool);
+       template<typename T>
+       void parse_block(Block &, bool, RefPtr<T> (Parser::*)());
        RefPtr<Expression> parse_expression(unsigned = 0);
        RefPtr<BinaryExpression> parse_binary(const RefPtr<Expression> &, const Operator *);
        RefPtr<FunctionCall> parse_function_call(const VariableReference &);
        RefPtr<StructDeclaration> parse_struct_declaration();
        RefPtr<VariableDeclaration> parse_variable_declaration();
+       RefPtr<VariableDeclaration> parse_variable_declaration_with_layout();
        RefPtr<FunctionDeclaration> parse_function_declaration();
        RefPtr<InterfaceBlock> parse_interface_block();
        RefPtr<Conditional> parse_conditional();