mirror of
https://github.com/carbon-language/carbon-lang.git
synced 2026-11-16 01:18:14 +00:00
Add name accessor to NamedEntityView (#994)
This required changing BindingPattern::name() to return `"_"` instead of nullopt when representing a `"_"` binding. Semi-related drive-by fixes: - Update BindingPlaceholderValue to expose a NamedEntity instead of a string name, and stop exposing its type. - Drop the unused SourceLocation parameter of ValueEqual
This commit is contained in:
1 parent
3f12316d6b
commit
50263483d8
13 files changed
+88
-71
No files matched your search
@@ -100,7 +100,7 @@ void Statement::PrintDepth(int depth, llvm::raw_ostream& out) const {
|
||||
}
|
||||
case StatementKind::Continuation: {
|
||||
const auto& cont = cast<Continuation>(*this);
|
||||
out << "continuation " << cont.continuation_variable() << " ";
|
||||
out << "continuation " << cont.name() << " ";
|
||||
if (depth < 0 || depth > 1) {
|
||||
out << "\n";
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user