fix function name

pull/139/head
Rod Elias 3 years ago committed by GitHub
parent 2ff96aa67a
commit e415eedde3
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

@ -10654,7 +10654,7 @@ note: the function `prints_one_thing` is defined here
4 | fn prints_one_thing<T: Display>(input: T) {
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
```
It's easy to understand that function `print_one_thing` is private. It also shows us with `src\main.rs:4:5` where to find the function. This is helpful because you can write `mod`s not just in one file, but over a lot of files as well.
It's easy to understand that function `prints_one_thing` is private. It also shows us with `src\main.rs:4:5` where to find the function. This is helpful because you can write `mod`s not just in one file, but over a lot of files as well.
Now we just write `pub fn` instead of `fn` and everything works.

Loading…
Cancel
Save