mirror of
https://github.com/carbon-language/carbon-lang.git
synced 2026-10-06 09:24:46 +01:00
Refactory the IR/builder relationship (#2342)
I'm thinking about how to handle multiple files, and I think the current IRFactory is useful as a file-focused thing. So shifting/renaming accordingly. (doing this in its own PR to make the history a little cleaner for git's move detection)
This commit is contained in:
@@ -14,7 +14,7 @@
|
||||
#include "toolchain/diagnostics/sorting_diagnostic_consumer.h"
|
||||
#include "toolchain/lexer/tokenized_buffer.h"
|
||||
#include "toolchain/parser/parse_tree.h"
|
||||
#include "toolchain/semantics/semantics_ir_factory.h"
|
||||
#include "toolchain/semantics/semantics_ir.h"
|
||||
#include "toolchain/source/source_buffer.h"
|
||||
|
||||
namespace Carbon {
|
||||
@@ -162,7 +162,7 @@ auto Driver::RunDumpSubcommand(DiagnosticConsumer& consumer,
|
||||
return !tokenized_source.has_errors() && !parse_tree.has_errors();
|
||||
}
|
||||
|
||||
auto semantics_ir = SemanticsIRFactory::Build(tokenized_source, parse_tree);
|
||||
SemanticsIR semantics_ir(tokenized_source, parse_tree);
|
||||
if (dump_mode == DumpMode::SemanticsIR) {
|
||||
consumer.Flush();
|
||||
semantics_ir.Print(output_stream_);
|
||||
|
||||
Reference in New Issue
Block a user