core: Use tilde-fences in docs
Backtick fences don't work for some reason
This commit is contained in:
parent
4063802f64
commit
eb935b8fcb
@ -1531,9 +1531,9 @@ interop, without copying the original string.
|
||||
|
||||
# Example
|
||||
|
||||
```
|
||||
~~~
|
||||
let s = str::as_buf(\"PATH\", { |path_buf| libc::getenv(path_buf) });
|
||||
```
|
||||
~~~
|
||||
"]
|
||||
fn as_c_str<T>(s: str, f: fn(*libc::c_char) -> T) -> T unsafe {
|
||||
as_buf(s) {|buf| f(buf as *libc::c_char) }
|
||||
|
Loading…
x
Reference in New Issue
Block a user