549: fix #543 r=korken89 a=andrewgazelka

The remaining PR to fix #543 alongside https://github.com/rtic-rs/rtic-syntax/pull/58

Co-authored-by: Andrew Gazelka <andrew.gazelka@gmail.com>
This commit is contained in:
bors[bot] 2021-11-09 09:52:28 +00:00 committed by GitHub
commit 4f3c5baf49
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -43,8 +43,10 @@ pub fn codegen(app: &App, analysis: &Analysis, extra: &Extra) -> CodegenResult {
.map(|(k, v)| { .map(|(k, v)| {
let ty = &v.ty; let ty = &v.ty;
let cfgs = &v.cfgs; let cfgs = &v.cfgs;
let docs = &v.docs;
quote!( quote!(
#(#cfgs)* #(#cfgs)*
#(#docs)*
#k: #ty, #k: #ty,
) )
}) })
@ -55,8 +57,10 @@ pub fn codegen(app: &App, analysis: &Analysis, extra: &Extra) -> CodegenResult {
.map(|(k, v)| { .map(|(k, v)| {
let ty = &v.ty; let ty = &v.ty;
let cfgs = &v.cfgs; let cfgs = &v.cfgs;
let docs = &v.docs;
quote!( quote!(
#(#cfgs)* #(#cfgs)*
#(#docs)*
#k: #ty, #k: #ty,
) )
}) })