turn ast::ident into a struct

This will help with the auto_serialize2 migration. We have to change
ident from a type alias to uint into a unique type. We need to use
a struct instead of a "enum ident = token::str_num" because structs
support constants, but newtypes do not.
This commit is contained in:
Erick Tryzelaar
2012-09-19 18:50:24 -07:00
committed by Graydon Hoare
parent c0b9986c8f
commit b96af73159
20 changed files with 152 additions and 122 deletions

View File

@@ -23,7 +23,7 @@ pure fn dummy_sp() -> span { return mk_sp(0u, 0u); }
pure fn path_name_i(idents: ~[ident], intr: token::ident_interner) -> ~str {
pure fn path_name_i(idents: ~[ident], intr: @token::ident_interner) -> ~str {
// FIXME: Bad copies (#2543 -- same for everything else that says "bad")
str::connect(idents.map(|i| *intr.get(*i)), ~"::")
}