File tree Expand file tree Collapse file tree 1 file changed +11
-1
lines changed
eden/scm/lib/tracing-runtime-callsite/src Expand file tree Collapse file tree 1 file changed +11
-1
lines changed Original file line number Diff line number Diff line change @@ -166,4 +166,14 @@ fn normalize(s: &str) -> String {
166166}
167167
168168static THREAD_LOCK : Lazy < Mutex < ( ) > > = Lazy :: new ( Default :: default) ;
169- static IDENTIFIER_RE : Lazy < Regex > = Lazy :: new ( || Regex :: new ( "Identifier\\ ([^)]*\\ )" ) . unwrap ( ) ) ;
169+ static IDENTIFIER_RE : Lazy < Regex > = Lazy :: new ( || {
170+ // tracing_core::callsite::Identifier is Debug-printed using "Identifier({:p})"
171+ // on a dyn Callsite.
172+ //
173+ // On Rust older than 1.87, it prints as:
174+ // Identifier(0x503000001960)
175+ //
176+ // and on 1.87+ as:
177+ // Identifier(Pointer { addr: 0x503000001960, metadata: DynMetadata(0x55aa5a3b14c8) })
178+ Regex :: new ( r#"Identifier\((0x[0-9a-f]+|Pointer \{ addr: 0x[0-9a-f]+, metadata: DynMetadata\(0x[0-9a-f]+\) \})\)"# ) . unwrap ( )
179+ } ) ;
You can’t perform that action at this time.
0 commit comments