fix: make hello public

This commit is contained in:
Satya Rohith 2018-12-13 15:07:10 +05:30 committed by GitHub
parent ced7cc5c65
commit 9da1dd74c0
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -50,7 +50,7 @@ fn main() {
And a `foo.rs` that had this:
```rust,ignore
fn hello() {
pub fn hello() {
println!("Hello, world!");
}
```
@ -65,4 +65,4 @@ No need to tell `rustc` about `foo.rs`; the `mod` statements give it
everything that it needs. This is different than how you would use a C
compiler, where you invoke the compiler on each file, and then link
everything together. In other words, the *crate* is a translation unit, not a
particular module.
particular module.