jdarais commented on code in PR #382:
URL: https://github.com/apache/avro-rs/pull/382#discussion_r2667146676


##########
avro/src/schema.rs:
##########
@@ -2722,6 +2755,29 @@ pub mod derive {
             T::get_schema_in_ctxt(named_schemas, enclosing_namespace)
         }
     }
+
+    impl AvroSchemaComponent for core::time::Duration {
+        fn get_schema_in_ctxt(
+            named_schemas: &mut Names,
+            enclosing_namespace: &Namespace,
+        ) -> Schema {
+            let name = Name {

Review Comment:
   It looks like the `AvroSchemaComponent::get_schema_in_ctxt` function doesn't 
return a Result, so we'd have to do something like 
`Name::new("duration").unwrap().fully_qualified_name(enclosing_namespace);`.  
Is that preferred over constructing the Name struct directly, or is there 
another function to construct a Name that can't fail that we could use here?



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to