diff options
author | John Hodge <tpg@mutabah.net> | 2016-05-22 13:49:45 +0800 |
---|---|---|
committer | John Hodge <tpg@mutabah.net> | 2016-05-22 13:49:45 +0800 |
commit | eba9d8f840a5b81f0188d109e63631c9a34c28e9 (patch) | |
tree | 84afcedb79bbe6fa8cb4098f78cd2b8e5dc700e9 /src/ast/crate.cpp | |
parent | 9a13dd6f999984c45c72eccd0f8ad35430c4b12e (diff) | |
download | mrust-eba9d8f840a5b81f0188d109e63631c9a34c28e9.tar.gz |
Clean up dead code (both useless code, and stuff that will be rewritten for HIR)
Diffstat (limited to 'src/ast/crate.cpp')
-rw-r--r-- | src/ast/crate.cpp | 22 |
1 files changed, 0 insertions, 22 deletions
diff --git a/src/ast/crate.cpp b/src/ast/crate.cpp index 699bd288..d40879f3 100644 --- a/src/ast/crate.cpp +++ b/src/ast/crate.cpp @@ -45,28 +45,6 @@ void Crate::load_externs() iterate_module(m_root_module, cb); } -void Crate::index_impls() -{ - // Iterate all modules, grabbing pointers to all impl blocks - auto cb = [this](Module& mod){ - for( auto& impl : mod.impls() ) - m_impl_index.push_back( &impl ); - for( auto& impl : mod.neg_impls() ) - m_neg_impl_index.push_back( &impl ); - }; - iterate_module(m_root_module, cb); - iterate_module(g_compiler_module, cb); - - // Create a map of inherent impls - for( const auto& impl : m_impl_index ) - { - if( impl->def().trait().is_valid() == false ) - { - auto& ent = m_impl_map[impl->def().type()]; - ent.push_back( impl ); - } - } -} void Crate::iterate_functions(fcn_visitor_t* visitor) { |