bson-rust - PR #566: Rust 1748 Add serde_conv macro for object_id::AsHexString and object_id::FromHexString

XMLWordPrintableJSON

    • Type: Task
    • Resolution: Duplicate
    • Priority: Unknown
    • None
    • Affects Version/s: None
    • Component/s: None
    • None
    • Hide

      1. What would you like to communicate to the user about this feature?
      2. Would you like the user to see examples of the syntax and/or executable code and its output?
      3. Which versions of the driver/connector does this apply to?

      Show
      1. What would you like to communicate to the user about this feature? 2. Would you like the user to see examples of the syntax and/or executable code and its output? 3. Which versions of the driver/connector does this apply to?
    • None
    • None
    • None
    • None
    • None
    • None

      JamieTsai1024 has created PR #566: Rust 1748 Add serde_conv macro for object_id::AsHexString and object_id::FromHexString in bson-rust

      Issue Text:

      • Add custom `serde_conv` macro, `my_serde_conv`, to:
        1. Support rustdoc documentation for structs
        2. Support serializers that may fail by wrapping the return type for `serialize` in a `Result`
      • Original implementation assumes that serialization cannot fail
      • Refactor full struct `(de)serialize_as` implementations to use `my_serde_conv` macro
      • `object_id::AsHexString`
      • `object_id::FromHexString`

            Assignee:
            Isabel Atkinson
            Reporter:
            TPM Jira Automations Bot
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Created:
              Updated:
              Resolved: