diff --git a/symbol_search.cc b/symbol_search.cc index 0355fb6bb..8a50ae1c6 100644 --- a/symbol_search.cc +++ b/symbol_search.cc @@ -59,7 +59,7 @@ NetScope*symbol_search(const LineInfo*li, Design*des, NetScope*scope, scope = des->find_scope(scope, path_list); - if (scope->is_auto() && li) { + if (scope && scope->is_auto() && li) { cerr << li->get_fileline() << ": error: Hierarchical " "reference to automatically allocated item " "`" << key << "' in path `" << path << "'" << endl;