mirror of
https://github.com/carbon-language/carbon-lang.git
synced 2026-10-05 17:31:07 +01:00
Split out context targets for check and parse. (#3558)
Per request on #3556. Note, I'm assuming handlers should remain in the same target as the caller for longer-term performance reasons.
This commit is contained in:
@@ -10,6 +10,10 @@
|
||||
|
||||
namespace Carbon::Parse {
|
||||
|
||||
// Declare handlers for each parse state.
|
||||
#define CARBON_PARSE_STATE(Name) auto Handle##Name(Context& context) -> void;
|
||||
#include "toolchain/parse/state.def"
|
||||
|
||||
auto HandleInvalid(Context& context) -> void {
|
||||
CARBON_FATAL() << "The Invalid state shouldn't be on the stack: "
|
||||
<< context.PopState();
|
||||
|
||||
Reference in New Issue
Block a user