mirror of
https://github.com/carbon-language/carbon-lang.git
synced 2026-11-22 15:12:40 +00:00
Explorer: Remove PrintDepth and implement PrintIndent. (#3113)
This PR removes `PrintDepth` from statement and declaration. Implements `PrintIndent` for better indented formatting along with various changes to make printing of statements and declarations better. --------- Co-authored-by: Jon Ross-Perkins <jperkins@google.com>
This commit is contained in:
1 parent
05e061fe96
commit
289d05813e
17 files changed
+322
-300
No files matched your search
@@ -343,12 +343,12 @@ void Expression::PrintID(llvm::raw_ostream& out) const {
|
||||
case ExpressionKind::TypeTypeLiteral:
|
||||
out << "type";
|
||||
break;
|
||||
case ExpressionKind::FunctionTypeLiteral:
|
||||
case ExpressionKind::StructLiteral:
|
||||
case ExpressionKind::ArrayTypeLiteral:
|
||||
case ExpressionKind::ValueLiteral:
|
||||
out << cast<ConstantValueLiteral>(*this).constant_value();
|
||||
break;
|
||||
case ExpressionKind::ArrayTypeLiteral:
|
||||
case ExpressionKind::FunctionTypeLiteral:
|
||||
case ExpressionKind::StructLiteral:
|
||||
case ExpressionKind::IndexExpression:
|
||||
case ExpressionKind::SimpleMemberAccessExpression:
|
||||
case ExpressionKind::CompoundMemberAccessExpression:
|
||||
|
||||
Reference in new issue
Block a user