diff options
author | Emilio Cobos Álvarez <emilio@crisal.io> | 2018-10-19 02:44:20 +0200 |
---|---|---|
committer | Emilio Cobos Álvarez <emilio@crisal.io> | 2018-10-19 02:44:20 +0200 |
commit | 4d30c15be9cd3bc5392c5e7e0fa5cc04b9e5a2ce (patch) | |
tree | 526222ba8aaa36fa3f57de5a8d5441a96e8a116a | |
parent | 6055f364bd1d341da8fa881741ec36ab0abf0a7a (diff) |
tests: Add test coverage for #1424.
-rw-r--r-- | tests/expectations/tests/macro_const.rs | 10 | ||||
-rw-r--r-- | tests/headers/macro_const.h | 1 |
2 files changed, 8 insertions, 3 deletions
diff --git a/tests/expectations/tests/macro_const.rs b/tests/expectations/tests/macro_const.rs index 382af9a5..3752a39a 100644 --- a/tests/expectations/tests/macro_const.rs +++ b/tests/expectations/tests/macro_const.rs @@ -1,12 +1,16 @@ /* automatically generated by rust-bindgen */ - -#![allow(dead_code, non_snake_case, non_camel_case_types, non_upper_case_globals)] - +#![allow( + dead_code, + non_snake_case, + non_camel_case_types, + non_upper_case_globals +)] pub const foo: &'static [u8; 4usize] = b"bar\0"; pub const CHAR: u8 = 98u8; pub const CHARR: u8 = 0u8; pub const FLOAT: f64 = 5.09; pub const FLOAT_EXPR: f64 = 0.005; +pub const LONG: f64 = 3.0; pub const INVALID_UTF8: [u8; 5usize] = [240u8, 40u8, 140u8, 40u8, 0u8]; diff --git a/tests/headers/macro_const.h b/tests/headers/macro_const.h index c28a3f6b..7c5aa438 100644 --- a/tests/headers/macro_const.h +++ b/tests/headers/macro_const.h @@ -3,5 +3,6 @@ #define CHARR '\0' #define FLOAT 5.09f #define FLOAT_EXPR (5 / 1000.0f) +#define LONG 3L #define INVALID_UTF8 "\xf0\x28\x8c\x28" |