aboutsummaryrefslogtreecommitdiffstats
path: root/liblll
diff options
context:
space:
mode:
Diffstat (limited to 'liblll')
-rw-r--r--liblll/CodeFragment.h4
-rw-r--r--liblll/CompilerState.cpp2
-rw-r--r--liblll/CompilerState.h2
3 files changed, 4 insertions, 4 deletions
diff --git a/liblll/CodeFragment.h b/liblll/CodeFragment.h
index 6622de3e..95d21563 100644
--- a/liblll/CodeFragment.h
+++ b/liblll/CodeFragment.h
@@ -50,8 +50,8 @@ public:
private:
void finalise(CompilerState const& _cs);
- template <class T> void error() const { BOOST_THROW_EXCEPTION(T() ); }
- template <class T> void error(std::string const& reason) const {
+ template <class T> static void error() { BOOST_THROW_EXCEPTION(T() ); }
+ template <class T> static void error(std::string const& reason) {
auto err = T();
err << errinfo_comment(reason);
BOOST_THROW_EXCEPTION(err);
diff --git a/liblll/CompilerState.cpp b/liblll/CompilerState.cpp
index 9701e16b..d53dec7e 100644
--- a/liblll/CompilerState.cpp
+++ b/liblll/CompilerState.cpp
@@ -30,7 +30,7 @@ CompilerState::CompilerState()
{
}
-CodeFragment const& CompilerState::getDef(std::string const& _s)
+CodeFragment const& CompilerState::getDef(std::string const& _s) const
{
if (defs.count(_s))
return defs.at(_s);
diff --git a/liblll/CompilerState.h b/liblll/CompilerState.h
index c29d3b7d..96a0246d 100644
--- a/liblll/CompilerState.h
+++ b/liblll/CompilerState.h
@@ -40,7 +40,7 @@ struct CompilerState
{
CompilerState();
- CodeFragment const& getDef(std::string const& _s);
+ CodeFragment const& getDef(std::string const& _s) const;
void populateStandard();
unsigned stackSize = 128;