The GitHub Actions job "Fory CI" on fory.git/main has succeeded. Run started by GitHub user chaokunyang (triggered by chaokunyang).
Head commit for run: 7cd451561ac8e79d2c8af000f71d796bc77b006c / urlyy <[email protected]> feat(Rust): support Option in MetaFieldType se/de (#2528) ## Why? Rust does not support objects being `null`; instead, it uses the `Option` type to wrap nullable objects. In the current Rust macros, `Option<T>` is extracted as `MetaFieldType { name: "Option", generics: [T] }`, and then compared with the `MetaFieldType { name: T, generics: [] }` received from the sender peer like java. This causes a type mismatch. Therefore, the `Option` type requires special handling. ## What does this PR do? - support `Option` in MetaFieldType se/de. Specifically, during Rust peer serialization, I will serialize `Option<T>` as `(T::type_id, nullable=true)`. During deserialization, `(T::type_id, nullable=true)` will be converted to `Option<T>`, while `(T::type_id, nullable=false)` will be converted to `T`. - correct the previous mistake in #2492, rename `FieldId` to `TypeId`. ## notice It doesn’t support handling adjacent Options, such as Option<Option<T>>. ## Related issues #2526 ## Does this PR introduce any user-facing change? - [ ] Does this PR introduce any public API change? - [ ] Does this PR introduce any binary protocol compatibility change? ## Benchmark Report URL: https://github.com/apache/fory/actions/runs/17233968453 With regards, GitHub Actions via GitBox --------------------------------------------------------------------- To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected]
