summaryrefslogtreecommitdiff
path: root/tests/namespace_test
diff options
context:
space:
mode:
Diffstat (limited to 'tests/namespace_test')
-rw-r--r--tests/namespace_test/namespace_test1_generated.rs12
-rw-r--r--tests/namespace_test/namespace_test2_generated.rs12
2 files changed, 16 insertions, 8 deletions
diff --git a/tests/namespace_test/namespace_test1_generated.rs b/tests/namespace_test/namespace_test1_generated.rs
index 0f293925..37b0175a 100644
--- a/tests/namespace_test/namespace_test1_generated.rs
+++ b/tests/namespace_test/namespace_test1_generated.rs
@@ -72,7 +72,9 @@ impl<'a> flatbuffers::Follow<'a> for UnionInNestedNS {
type Inner = Self;
#[inline]
fn follow(buf: &'a [u8], loc: usize) -> Self::Inner {
- let b = flatbuffers::read_scalar_at::<u8>(buf, loc);
+ let b = unsafe {
+ flatbuffers::read_scalar_at::<u8>(buf, loc)
+ };
Self(b)
}
}
@@ -81,7 +83,7 @@ impl flatbuffers::Push for UnionInNestedNS {
type Output = UnionInNestedNS;
#[inline]
fn push(&self, dst: &mut [u8], _rest: &[u8]) {
- flatbuffers::emplace_scalar::<u8>(dst, self.0);
+ unsafe { flatbuffers::emplace_scalar::<u8>(dst, self.0); }
}
}
@@ -209,7 +211,9 @@ impl<'a> flatbuffers::Follow<'a> for EnumInNestedNS {
type Inner = Self;
#[inline]
fn follow(buf: &'a [u8], loc: usize) -> Self::Inner {
- let b = flatbuffers::read_scalar_at::<i8>(buf, loc);
+ let b = unsafe {
+ flatbuffers::read_scalar_at::<i8>(buf, loc)
+ };
Self(b)
}
}
@@ -218,7 +222,7 @@ impl flatbuffers::Push for EnumInNestedNS {
type Output = EnumInNestedNS;
#[inline]
fn push(&self, dst: &mut [u8], _rest: &[u8]) {
- flatbuffers::emplace_scalar::<i8>(dst, self.0);
+ unsafe { flatbuffers::emplace_scalar::<i8>(dst, self.0); }
}
}
diff --git a/tests/namespace_test/namespace_test2_generated.rs b/tests/namespace_test/namespace_test2_generated.rs
index d9391861..4db42a06 100644
--- a/tests/namespace_test/namespace_test2_generated.rs
+++ b/tests/namespace_test/namespace_test2_generated.rs
@@ -72,7 +72,9 @@ impl<'a> flatbuffers::Follow<'a> for UnionInNestedNS {
type Inner = Self;
#[inline]
fn follow(buf: &'a [u8], loc: usize) -> Self::Inner {
- let b = flatbuffers::read_scalar_at::<u8>(buf, loc);
+ let b = unsafe {
+ flatbuffers::read_scalar_at::<u8>(buf, loc)
+ };
Self(b)
}
}
@@ -81,7 +83,7 @@ impl flatbuffers::Push for UnionInNestedNS {
type Output = UnionInNestedNS;
#[inline]
fn push(&self, dst: &mut [u8], _rest: &[u8]) {
- flatbuffers::emplace_scalar::<u8>(dst, self.0);
+ unsafe { flatbuffers::emplace_scalar::<u8>(dst, self.0); }
}
}
@@ -209,7 +211,9 @@ impl<'a> flatbuffers::Follow<'a> for EnumInNestedNS {
type Inner = Self;
#[inline]
fn follow(buf: &'a [u8], loc: usize) -> Self::Inner {
- let b = flatbuffers::read_scalar_at::<i8>(buf, loc);
+ let b = unsafe {
+ flatbuffers::read_scalar_at::<i8>(buf, loc)
+ };
Self(b)
}
}
@@ -218,7 +222,7 @@ impl flatbuffers::Push for EnumInNestedNS {
type Output = EnumInNestedNS;
#[inline]
fn push(&self, dst: &mut [u8], _rest: &[u8]) {
- flatbuffers::emplace_scalar::<i8>(dst, self.0);
+ unsafe { flatbuffers::emplace_scalar::<i8>(dst, self.0); }
}
}