chaokunyang opened a new issue, #2863:
URL: https://github.com/apache/fory/issues/2863
### Feature Request
```rust
fn test_tuple_size_mismatch() {
let fory = Fory::default().compatible(true);
// Test 1a: Long tuple serialized, short tuple deserialized
let long = (42i32, "hello".to_string(), 3.14f64, true);
let bin = fory.serialize(&long).unwrap();
let short: (i32, String) = fory.deserialize(&bin).expect("deserialize
long to short");
assert_eq!(short.0, 42);
assert_eq!(short.1, "hello");
// Test 1b: Short tuple serialized, long tuple deserialized
let short = (100i32, "world".to_string());
let bin = fory.serialize(&short).unwrap();
let long: (i32, String, f64, bool) =
fory.deserialize(&bin).expect("deserialize short to long");
assert_eq!(long.0, 100);
assert_eq!(long.1, "world");
// Remaining fields should be default values
assert_eq!(long.2, 0.0);
assert_eq!(long.3, false);
}
```
### Is your feature request related to a problem? Please describe
_No response_
### Describe the solution you'd like
_No response_
### Describe alternatives you've considered
_No response_
### Additional context
_No response_
--
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]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]