@@ -9,7 +9,7 @@ mod perftools {
9
9
use anyhow:: { Context , Result } ;
10
10
use bytes:: { Buf , BytesMut } ;
11
11
use camino:: Utf8PathBuf ;
12
- use flate2:: { bufread:: GzEncoder , Compression } ;
12
+ use flate2:: { Compression , bufread:: GzEncoder } ;
13
13
use prost:: Message ;
14
14
use std:: collections:: { HashMap , HashSet } ;
15
15
use std:: { fs, io:: Read } ;
@@ -113,7 +113,10 @@ impl ProfilerContext {
113
113
locations_ids. push ( LocationId ( location. id ) ) ;
114
114
} else {
115
115
let mut location = match & function_stack[ 0 ] {
116
- FunctionCall :: EntrypointCall ( function_name) | FunctionCall :: InternalFunctionCall ( InternalFunctionCall :: NonInlined ( function_name) | Syscall ( function_name) ) => {
116
+ FunctionCall :: EntrypointCall ( function_name)
117
+ | FunctionCall :: InternalFunctionCall (
118
+ InternalFunctionCall :: NonInlined ( function_name) | Syscall ( function_name) ,
119
+ ) => {
117
120
let line = pprof:: Line {
118
121
function_id : self . function_id ( function_name) . into ( ) ,
119
122
line : 0 ,
@@ -126,7 +129,11 @@ impl ProfilerContext {
126
129
is_folded : true ,
127
130
}
128
131
}
129
- FunctionCall :: InternalFunctionCall ( InternalFunctionCall :: Inlined ( _) ) => unreachable ! ( "First function in a function stack corresponding to a single location cannot be inlined" )
132
+ FunctionCall :: InternalFunctionCall ( InternalFunctionCall :: Inlined ( _) ) => {
133
+ unreachable ! (
134
+ "First function in a function stack corresponding to a single location cannot be inlined"
135
+ )
136
+ }
130
137
} ;
131
138
132
139
for function in function_stack. get ( 1 ..) . unwrap_or_default ( ) {
@@ -144,7 +151,9 @@ impl ProfilerContext {
144
151
| FunctionCall :: InternalFunctionCall (
145
152
InternalFunctionCall :: NonInlined ( _) | Syscall ( _) ,
146
153
) => {
147
- unreachable ! ( "Only first function in a function stack corresponding to a single location can be not inlined" )
154
+ unreachable ! (
155
+ "Only first function in a function stack corresponding to a single location can be not inlined"
156
+ )
148
157
}
149
158
}
150
159
}
0 commit comments