2010-06-28 10:32:08 +00:00
|
|
|
#ifndef MWCOMPILER_CONTEXT_H_INCLUDED
|
|
|
|
#define MWCOMPILER_CONTEXT_H_INCLUDED
|
|
|
|
|
|
|
|
#include <components/compiler/context.hpp>
|
|
|
|
|
|
|
|
namespace SACompiler
|
|
|
|
{
|
|
|
|
class Context : public Compiler::Context
|
|
|
|
{
|
|
|
|
public:
|
|
|
|
|
|
|
|
virtual bool canDeclareLocals() const;
|
|
|
|
///< Is the compiler allowed to declare local variables?
|
2010-07-04 10:29:28 +00:00
|
|
|
|
|
|
|
virtual char getGlobalType (const std::string& name) const;
|
2010-07-09 18:35:34 +00:00
|
|
|
///< 'l: long, 's': short, 'f': float, ' ': does not exist.
|
|
|
|
|
|
|
|
virtual bool isId (const std::string& name) const;
|
|
|
|
///< Does \a name match an ID, that can be referenced?
|
2010-06-28 10:32:08 +00:00
|
|
|
};
|
|
|
|
}
|
|
|
|
|
|
|
|
#endif
|
|
|
|
|