Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add a path attribute for crate directive #1214

Closed
wants to merge 2 commits into from

Conversation

lht
Copy link
Contributor

@lht lht commented Nov 23, 2011

Fix the last part of issue #906.

lht added 2 commits November 23, 2011 08:32
Temporarily allow path specified in either as attribute or in AST, like:

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

This is a transitional commit to avoid creating a stage1 snapshot.
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 rust-lang#906.
@brson
Copy link
Contributor

brson commented Nov 25, 2011

Looks great! Integrated.

@brson brson closed this Nov 25, 2011
bjorn3 added a commit to bjorn3/rust that referenced this pull request Dec 30, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants