We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
Repro:
pub fn process(db: &SimpleParserDatabase, struct_ast: &ast::ItemStruct) -> TokenStream { let name_string = struct_ast.name(db).text(db).to_string(); let name_token = TokenTree::Ident(Token::new(name_string.clone(), TextSpan::call_site())); let impl_string = format!("{}NameImpl", name_string.clone()); let impl_token = TokenTree::Ident(Token::new(impl_string, TextSpan::call_site())); let res_string = format!("\"{}\"", name_string); let res_token = TokenTree::Ident(Token::new(res_string, TextSpan::call_site())); quote! { impl #impl_token of NameTrait<#name_token> { fn name(self: @#name_token) -> ByteArray { #res_token } } } }
generates:
impl MyStructNameImplof NameTrait<MyStruct> {
Branch dev, https://github.com/software-mansion/scarb/blob/dev/plugins/cairo-lang-quote/src/lib.rs
dev
The text was updated successfully, but these errors were encountered:
DelevoXDG
No branches or pull requests
Repro:
generates:
Branch
dev
, https://github.com/software-mansion/scarb/blob/dev/plugins/cairo-lang-quote/src/lib.rsThe text was updated successfully, but these errors were encountered: