Index: src/scopes.cc |
diff --git a/src/scopes.cc b/src/scopes.cc |
index 7d52db85a9faf74df460aade3e557bbcb5818e4a..dbcc4b60832bf33d5e096bab9f2634128263b25b 100644 |
--- a/src/scopes.cc |
+++ b/src/scopes.cc |
@@ -938,7 +938,7 @@ void Scope::Print(int n) { |
// Print header. |
Indent(n0, Header(scope_type_, function_kind_, is_declaration_scope())); |
- if (!scope_name_->IsEmpty()) { |
+ if (scope_name_ != nullptr && !scope_name_->IsEmpty()) { |
PrintF(" "); |
PrintName(scope_name_); |
} |