Rust 語言之旅 目錄

[沒有翻譯] Module Hierarchy

A module can depend on another one. In order to establish a relationship between a module and its sub-module, you must write in the parent module:

mod foo;

The declaration above will look for a file named foo.rs or foo/mod.rs and will insert its contents inside a module named foo under this scope.

Mascot Ferris