We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 8211927 commit dfcc1efCopy full SHA for dfcc1ef
lxc-sys/examples/demo.rs
@@ -2,9 +2,7 @@ use lxc_sys::lxc_container;
2
use std::ptr::{null, null_mut};
3
4
macro_rules! str {
5
- ($e:expr) => {{
6
- std::ffi::CString::new($e).unwrap()
7
- }};
+ ($e:expr) => {{ std::ffi::CString::new($e).unwrap() }};
8
}
9
10
fn main() {
src/container.rs
@@ -4,9 +4,7 @@ use crate::ffi::to_mut_cstr;
macro_rules! get {
- ( $container:ident . $prop:ident ) => {{
- unsafe { (*$container.inner).$prop }
+ ( $container:ident . $prop:ident ) => {{ unsafe { (*$container.inner).$prop } }};
11
( $container:ident . $prop:ident -> c_str ) => {{
12
let result = get!($container.$prop);
0 commit comments