summaryrefslogtreecommitdiff
path: root/src/macros.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/macros.cpp')
-rw-r--r--src/macros.cpp3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/macros.cpp b/src/macros.cpp
index d8d74d5a..296f6d40 100644
--- a/src/macros.cpp
+++ b/src/macros.cpp
@@ -523,8 +523,9 @@ bool Macro_HandlePattern(TTStream& lex, const MacroPatEnt& pat, unsigned int lay
for( auto ent = g_macro_module; ent; ent = ent->m_prev )
{
const AST::Module& mm = *ent->m_item;
- for( const auto &m : mm.macros() )
+ for( unsigned int i = mm.macros().size(); i --; )
{
+ const auto& m = mm.macros()[i];
DEBUG("" << m.name);
if( m.name == name )
{