Uploaded image for project: 'Rust Driver'
  1. Rust Driver
  2. RUST-1916

Allow passing a HashMap directly into the doc macro

    • Type: Icon: Improvement Improvement
    • Resolution: Unresolved
    • Priority: Icon: Minor - P4 Minor - P4
    • None
    • Affects Version/s: None
    • Component/s: BSON
    • None
    • Rust Drivers

      See this issue for more details:

      Passing a map like this seems like a reasonable use case. Ideally, we'd be able to accept anything type that produces an iterator of (impl Into<String>, impl Into<Bson>) pairs. We could potentially implement a conversion like this for Document or amend this existing implementation to be more permissive. We'd then need to update the doc!/bson! macros to accept this kind of trait impl.

            Assignee:
            Unassigned Unassigned
            Reporter:
            isabel.atkinson@mongodb.com Isabel Atkinson
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Created:
              Updated: