Edit

kc3-lang/angle/src/compiler/Initialize.h

Branch :

  • Show log

    Commit

  • Author : alokp@chromium.org
    Date : 2010-11-12 15:42:16
    Hash : 044a5cf8
    Message : Refactored glslang grammar files to make: - lexer and parser reentrant - line number handling automatic Caveats: - The preprocessor is still not thread-safe and full of bugs. I have another not-yet-ready patch to replace the preprocessor. - The grammar files use options that are not supported by the old versions of flex and bison checked into compiler/tools. So I need to check-in the generated lexer-parser along with a shell script to generate them. Review URL: http://codereview.appspot.com/2992041 git-svn-id: https://angleproject.googlecode.com/svn/trunk@475 736b8ea6-26fd-11df-bfd4-992fa37f6226

  • src/compiler/Initialize.h
  • //
    // Copyright (c) 2002-2010 The ANGLE Project Authors. All rights reserved.
    // Use of this source code is governed by a BSD-style license that can be
    // found in the LICENSE file.
    //
    
    #ifndef _INITIALIZE_INCLUDED_
    #define _INITIALIZE_INCLUDED_
    
    #include "compiler/Common.h"
    #include "compiler/ShHandle.h"
    #include "compiler/SymbolTable.h"
    
    typedef TVector<TString> TBuiltInStrings;
    
    class TBuiltIns {
    public:
        POOL_ALLOCATOR_NEW_DELETE(GlobalPoolAllocator)
    
        void initialize(ShShaderType type, ShShaderSpec spec,
                        const ShBuiltInResources& resources);
        const TBuiltInStrings& getBuiltInStrings() { return builtInStrings; }
    
    protected:
        TBuiltInStrings builtInStrings;
    };
    
    void IdentifyBuiltIns(ShShaderType type, ShShaderSpec spec,
                          const ShBuiltInResources& resources,
                          TSymbolTable& symbolTable);
    
    void InitExtensionBehavior(const ShBuiltInResources& resources,
                               TExtensionBehavior& extensionBehavior);
    
    #endif // _INITIALIZE_INCLUDED_