Skip to content

Commit 688f49b

Browse files
committed
---
yaml --- r: 15619 b: refs/heads/try c: 55e29ef h: refs/heads/master i: 15617: 13b3445 15615: d916bbd v: v3
1 parent e344b65 commit 688f49b

File tree

2 files changed

+6
-2
lines changed

2 files changed

+6
-2
lines changed

[refs]

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,5 +2,5 @@
22
refs/heads/master: 61b1875c16de39c166b0f4d54bba19f9c6777d1a
33
refs/heads/snap-stage1: e33de59e47c5076a89eadeb38f4934f58a3618a6
44
refs/heads/snap-stage3: 4a81779abd786ff22d71434c6d9a5917ea4cdfff
5-
refs/heads/try: 03d9d6287ba09bbfb7c0dfe8977e6629ea5066e1
5+
refs/heads/try: 55e29ef4aa88d5d16b2ac6880cf1ab39ae11de90
66
refs/tags/release-0.1: 1f5c5126e96c79d22cb7862f75304136e204f105

branches/try/doc/tutorial.md

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -729,7 +729,8 @@ top-level module will be called `foo`, and you can set `RUST_LOG` to
729729
`foo` to enable `warn`, `info` and `debug` logging for the module.
730730

731731
Turned-off `log` statements impose minimal overhead on the code that
732-
contains them, so except in code that needs to be really, really fast,
732+
contains them, because the arguments to `log` are evaluated lazily.
733+
So except in code that needs to be really, really fast,
733734
you should feel free to scatter around debug logging statements, and
734735
leave them in.
735736

@@ -743,6 +744,9 @@ and will log the formatted string:
743744
#error("fatal: %s", get_error_string());
744745
~~~~
745746

747+
Because the macros `#debug`, `#warn`, and `#error` expand to calls to `log`,
748+
their arguments are also lazily evaluated.
749+
746750
## Assertions
747751

748752
The keyword `assert`, followed by an expression with boolean type,

0 commit comments

Comments
 (0)