fix: swapped argument order in new_inconsistent_union calls (#9001) (#9010)
diff --git a/rust/flatbuffers/src/verifier.rs b/rust/flatbuffers/src/verifier.rs
index a841bf7..e992279 100644
--- a/rust/flatbuffers/src/verifier.rs
+++ b/rust/flatbuffers/src/verifier.rs
@@ -492,8 +492,8 @@
                 Ok(self)
             }
             _ => InvalidFlatbuffer::new_inconsistent_union(
-                key_field_name.into(),
                 val_field_name.into(),
+                key_field_name.into(),
             ),
         }
     }
diff --git a/rust/reflection/src/reflection_verifier.rs b/rust/reflection/src/reflection_verifier.rs
index 524efbd..be492c7 100644
--- a/rust/reflection/src/reflection_verifier.rs
+++ b/rust/reflection/src/reflection_verifier.rs
@@ -397,8 +397,8 @@
         }
     } else {
         return InvalidFlatbuffer::new_inconsistent_union(
-            format!("{}_type", field.name()),
             field.name().to_string(),
+            format!("{}_type", field.name()),
         )?;
     }