mirror of
https://github.com/plasma-umass/coz.git
synced 2024-09-11 04:55:25 +03:00
Rust: Document scope
in favor of begin
/end
.
This commit is contained in:
parent
96b45326ad
commit
86fc9b13c8
@ -43,14 +43,12 @@ If you'd like to profile the latency of an operation you can instead use:
|
||||
```rust
|
||||
// Boy I wish this function executed more quickly...
|
||||
fn foo() {
|
||||
coz::begin!("foo");
|
||||
|
||||
// ...
|
||||
|
||||
coz::end!("foo");
|
||||
coz::scope!("foo");
|
||||
}
|
||||
```
|
||||
|
||||
Instead of `scope!` you may also use `coz::begin!("foo"); ... coz::end!("foo");`.
|
||||
|
||||
After you've instrumented your code, you need to also ensure that you're
|
||||
compiling with DWARF debug information. To do this you'll want to configure
|
||||
`Cargo.toml` again:
|
||||
|
Loading…
Reference in New Issue
Block a user