Hacky support for fn-like proc macros
This commit is contained in:
parent
cb816b1ea8
commit
bee56e68a3
1 changed files with 3 additions and 3 deletions
|
@ -89,9 +89,8 @@ impl ProcMacroClient {
|
||||||
macros
|
macros
|
||||||
.into_iter()
|
.into_iter()
|
||||||
.filter_map(|(name, kind)| {
|
.filter_map(|(name, kind)| {
|
||||||
// FIXME: Support custom derive only for now.
|
|
||||||
match kind {
|
match kind {
|
||||||
ProcMacroKind::CustomDerive => {
|
ProcMacroKind::CustomDerive | ProcMacroKind::FuncLike => {
|
||||||
let name = SmolStr::new(&name);
|
let name = SmolStr::new(&name);
|
||||||
let expander: Arc<dyn tt::TokenExpander> =
|
let expander: Arc<dyn tt::TokenExpander> =
|
||||||
Arc::new(ProcMacroProcessExpander {
|
Arc::new(ProcMacroProcessExpander {
|
||||||
|
@ -101,7 +100,8 @@ impl ProcMacroClient {
|
||||||
});
|
});
|
||||||
Some((name, expander))
|
Some((name, expander))
|
||||||
}
|
}
|
||||||
_ => None,
|
// FIXME: Attribute macro are currently unsupported.
|
||||||
|
ProcMacroKind::Attr => None,
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
.collect()
|
.collect()
|
||||||
|
|
Loading…
Add table
Reference in a new issue