File tree Expand file tree Collapse file tree 2 files changed +4
-4
lines changed Expand file tree Collapse file tree 2 files changed +4
-4
lines changed Original file line number Diff line number Diff line change @@ -4,7 +4,7 @@ A library for simple profiling your code with HTML reports as result.
4
4
At first the rprofiler must be initialized by the call ` rprofiler::PROFILER.initialize() ` method.
5
5
This method is returned an object of ProfilerData struct, where will be gathering all runtime information.
6
6
Then you can use special ` profile_block ` macro for profiling blocks of your code. It has some syntax variations:
7
- ```
7
+ ``` rust
8
8
profile_block! ();
9
9
profile_block! (name " name of code block" );
10
10
// Conditional profiling
@@ -31,7 +31,7 @@ features = ["disable_profiling"]
31
31
```
32
32
33
33
# Examples
34
- ```
34
+ ``` rust
35
35
fn factorial (value : i32 ) -> i32 {
36
36
match value > 1 {
37
37
true => value * factorial (value - 1 ),
Original file line number Diff line number Diff line change 4
4
//! At first the rprofiler must be initialized by the call `rprofiler::PROFILER.initialize()` method.
5
5
//! This method is returned an object of ProfilerData struct, where will be gathering all runtime information.
6
6
//! Then you can use special `profile_block` macro for profiling blocks of your code. It has some syntax variations:
7
- //! ```
7
+ //! ```rust
8
8
//! profile_block!();
9
9
//! profile_block!(name "name of code block");
10
10
//! // Conditional profiling
31
31
//! ```
32
32
//!
33
33
//! # Examples
34
- //! ```
34
+ //! ```rust
35
35
//! fn factorial(value: i32) -> i32 {
36
36
//! match value > 1 {
37
37
//! true => value*factorial(value - 1),
You can’t perform that action at this time.
0 commit comments