Skip to content

Commit 20772e0

Browse files
committedMar 28, 2025·
make write_char defaultable
1 parent ddfd585 commit 20772e0

File tree

2 files changed

+6
-0
lines changed

2 files changed

+6
-0
lines changed
 

‎builtin/builtin.mbti

+1
Original file line numberDiff line numberDiff line change
@@ -803,6 +803,7 @@ pub(open) trait Logger {
803803
write_substring(Self, String, Int, Int) -> Unit
804804
write_char(Self, Char) -> Unit
805805
}
806+
impl Logger::write_char
806807

807808
pub(open) trait Mod {
808809
op_mod(Self, Self) -> Self

‎builtin/traits.mbt

+5
Original file line numberDiff line numberDiff line change
@@ -55,6 +55,11 @@ pub(open) trait Logger {
5555
write_char(Self, Char) -> Unit
5656
}
5757

58+
///|
59+
impl Logger with write_char(self, value) {
60+
self.write_string([value])
61+
}
62+
5863
///|
5964
/// Trait for types that can be converted to `String`
6065
pub(open) trait Show {

0 commit comments

Comments
 (0)