Closed
Description
#[allow(non_upper_case_globals)]
pub mod kw {
macro_rules! define_keywords {
($($kw:ident)*) => {
$(
pub const $kw: &str = stringify!($kw);
)*
};
}
define_keywords! {
auto
break
case
char
const
continue
default
do
double
else
enum
extern
}
}
pub fn escape_string(s: &str) -> String {
format!("{:?}", s) // FIXME use actual C escaping rules
}
while extending the list of keywords in define_keywords! {}
. The panics are fully deterministic and happens even after restarting.
thread 'Worker' panicked at 'assertion failed: start <= end', /github/home/.cargo/registry/src/proxy-git.cwkhome.fun-1ecc6299db9ec823/text-size-1.1.0/src/range.rs:48:9
stack backtrace:
0: rust_begin_unwind
at /rustc/a55dd71d5fb0ec5a6a3a9e8c27b2127ba491ce52/library/std/src/panicking.rs:584:5
1: core::panicking::panic_fmt
at /rustc/a55dd71d5fb0ec5a6a3a9e8c27b2127ba491ce52/library/core/src/panicking.rs:142:14
2: core::panicking::panic
at /rustc/a55dd71d5fb0ec5a6a3a9e8c27b2127ba491ce52/library/core/src/panicking.rs:48:5
3: ide_completion::completions::item_list::trait_impl::complete_trait_impl_name
4: ide_completion::completions
5: std::panicking::try
6: rust_analyzer::handlers::handle_completion
7: std::panicking::try
8: <F as threadpool::FnBox>::call_box
note: Some details are omitted, run with `RUST_BACKTRACE=full` for a verbose backtrace.
[Error - 14:17:49] Request textDocument/completion failed.
Message: request handler panicked: assertion failed: start <= end
Code: -32603
rust-analyzer version: rust-analyzer version: 0.3.1221-standalone
rustc version: rustc 1.63.0 (4b91a6ea7 2022-08-08)
relevant settings: