diff options
Diffstat (limited to 'src')
| -rw-r--r-- | src/display/display_sink.rs | 4 | 
1 files changed, 3 insertions, 1 deletions
| diff --git a/src/display/display_sink.rs b/src/display/display_sink.rs index f5ec026..e83f084 100644 --- a/src/display/display_sink.rs +++ b/src/display/display_sink.rs @@ -453,7 +453,9 @@ mod instruction_text_sink {                  // write single ASCII characters. this is wrong in the general case, but `write_char`                  // here is not going to be used in the general case.                  if cfg!(debug_assertions) { -                    panic!("InstructionTextSink::write_char would truncate output"); +                    if c > '\x7f' { +                        panic!("InstructionTextSink::write_char would truncate output"); +                    }                  }                  let to_push = c as u8;                  // `ptr::write` here because `underlying.add(underlying.len())` may not point to an | 
