rust/src/test/run-pass/multi.rc
Haitao Li 3e303af86b rustc: Add a path attribute for crate directives
The path information was an optional "filename" component of crate
directive AST. It is now replaced by an attribute with metadata named
"path".

With this commit, a directive

  mod foo = "foo.rs";

should be written as:

  #[path = "foo.rs"]
  mod foo;

Closes issue #906.
2011-11-24 15:31:18 -08:00

9 lines
116 B
Plaintext

#[path = "multi-src"]
mod multi {
// implicitly #[path = "foo.rs"]
mod foo;
#[path = "bar.rs"]
mod bar;
}