summaryrefslogtreecommitdiffstats
path: root/tests/rust/constant_constexpr.rs
diff options
context:
space:
mode:
Diffstat (limited to 'tests/rust/constant_constexpr.rs')
-rw-r--r--tests/rust/constant_constexpr.rs14
1 files changed, 14 insertions, 0 deletions
diff --git a/tests/rust/constant_constexpr.rs b/tests/rust/constant_constexpr.rs
new file mode 100644
index 0000000..c4d2b8c
--- /dev/null
+++ b/tests/rust/constant_constexpr.rs
@@ -0,0 +1,14 @@
+pub const CONSTANT_I64: i64 = 216;
+pub const CONSTANT_FLOAT32: f32 = 312.292;
+pub const DELIMITER: char = ':';
+pub const LEFTCURLY: char = '{';
+#[repr(C)]
+struct Foo {
+ x: i32,
+}
+
+pub const SomeFoo: Foo = Foo { x: 99, };
+
+impl Foo {
+ pub const CONSTANT_I64_BODY: i64 = 216;
+}