diff options
author | Martin Fischer <martin@push-f.com> | 2021-11-22 06:36:37 +0100 |
---|---|---|
committer | Martin Fischer <martin@push-f.com> | 2021-11-22 07:45:30 +0100 |
commit | bacdafb4883d8f8ea06e498285c78f82de9a391b (patch) | |
tree | 30f3f795e2b8c4895cea7e708ca4a1fe46eedd0c /src/lib.rs | |
parent | a973a628ec051ab9483fde7d694bb261bb793178 (diff) |
support Vec, VecDeque & LinkedList collections
Diffstat (limited to 'src/lib.rs')
-rw-r--r-- | src/lib.rs | 6 |
1 files changed, 5 insertions, 1 deletions
@@ -409,7 +409,11 @@ impl TypeTransform { quote! {#arg.map_err(|x| #err_inner)} } } - _other => arg, + TypeTransform::Collection(inner) => { + let inner = inner.convert(quote!(x)); + quote! {#arg.into_iter().map(|x| #inner).collect()} + } + TypeTransform::NoOp => arg, } } } |