Skip to content

Commit 5ab1062

Browse files
committed
Use namespaced enums
rust-lang/rust#18973 changed the behavior of enums. Enums are now namespaced.
1 parent 690c634 commit 5ab1062

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

generator/src/lib.rs

+2-2
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@ extern crate syntax;
2121
extern crate url;
2222

2323
use phf_mac::util as phf;
24-
use phf_mac::util::{Entry, KeyStr};
24+
use phf_mac::util::{Entry, Key};
2525
use rustc::plugin::Registry;
2626
use syntax::{ast, codemap, parse};
2727
use syntax::ast::{CookedStr, LitStr};
@@ -84,7 +84,7 @@ fn expand(cx: &mut ExtCtxt, sp: codemap::Span, tts: &[ast::TokenTree]) -> Box<Ma
8484
fn generate_entry(cx: &ExtCtxt, sp: codemap::Span, ext: &str, type_: &str, subtype: &str) -> Entry {
8585
// The key
8686
let key = str_to_lit(cx, sp, ext);
87-
let key_contents = KeyStr(token::intern_and_get_ident(ext));
87+
let key_contents = Key::Str(token::intern_and_get_ident(ext));
8888

8989
// The raw media type
9090
let raw_media_type = generate_media_type(cx, sp, type_, subtype);

0 commit comments

Comments
 (0)