Skip to content

Commit d17b767

Browse files
authored
Merge pull request #17219 from fedetrim/master
[SR-7904] Add source filenames in the output of `-dump-ast`
2 parents a59e909 + 63f0697 commit d17b767

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

lib/AST/ASTDumper.cpp

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -773,7 +773,9 @@ namespace {
773773
void visitSourceFile(const SourceFile &SF) {
774774
OS.indent(Indent);
775775
PrintWithColorRAII(OS, ParenthesisColor) << '(';
776-
PrintWithColorRAII(OS, ASTNodeColor) << "source_file";
776+
PrintWithColorRAII(OS, ASTNodeColor) << "source_file ";
777+
PrintWithColorRAII(OS, LocationColor) << '\"' << SF.getFilename() << '\"';
778+
777779
for (Decl *D : SF.Decls) {
778780
if (D->isImplicit())
779781
continue;

0 commit comments

Comments
 (0)