mirror of
https://github.com/roc-lang/roc.git
synced 2025-09-29 14:54:47 +00:00
Dump roc checkmate
This commit is contained in:
parent
1282110ef5
commit
fcd733e1df
8 changed files with 119 additions and 10 deletions
|
@ -1,3 +1,5 @@
|
|||
use std::error::Error;
|
||||
|
||||
use roc_checkmate_schema::{AllEvents, Event, VariableEvent};
|
||||
use roc_types::subs as s;
|
||||
|
||||
|
@ -105,6 +107,11 @@ impl Collector {
|
|||
self.current_event_path.pop();
|
||||
}
|
||||
|
||||
pub fn write(&self, writer: impl std::io::Write) -> Result<(), Box<dyn Error>> {
|
||||
self.events.write(writer)?;
|
||||
Ok(())
|
||||
}
|
||||
|
||||
fn add_event(&mut self, event: impl Into<Event>) {
|
||||
let mut event = event.into();
|
||||
let is_appendable = EventW::Sub(&mut event).appendable();
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue