MCPcopy Create free account
hub / github.com/clockworklabs/SpacetimeDB / newline

Method newline

crates/codegen/src/code_indenter.rs:63–65  ·  view source on GitHub ↗

Writes a newline without setting the `needs_indenting` flag. TODO(cloutiertyler): I think it should set the flag, but I don't know if anyone is relying on the current behavior.

(&mut self)

Source from the content-addressed store, hash-verified

61 // TODO(cloutiertyler): I think it should set the flag, but I don't know
62 // if anyone is relying on the current behavior.
63 pub fn newline(&mut self) {
64 self.writer.write_char('\n').unwrap();
65 }
66
67 /// Print an indented block delimited by `before` and `after`, with body written by `f`.
68 pub fn delimited_block<Res>(&mut self, before: &str, f: impl FnOnce(&mut Self) -> Res, after: &str) -> Res {

Callers 15

generate_type_filesMethod · 0.80
generate_reducer_fileMethod · 0.80
generate_global_filesMethod · 0.80
define_enum_for_sumFunction · 0.80
print_reducer_enum_defnFunction · 0.80
print_db_update_defnFunction · 0.80
print_applied_diff_defnFunction · 0.80
generate_reducer_fileMethod · 0.80

Calls 1

unwrapMethod · 0.45

Tested by

no test coverage detected