diff options
author | Emilio Cobos Álvarez <emilio@crisal.io> | 2018-03-04 14:43:13 +0100 |
---|---|---|
committer | Emilio Cobos Álvarez <emilio@crisal.io> | 2018-03-04 14:43:13 +0100 |
commit | cfd153cc64c3212e3a19e78837f3a45884975641 (patch) | |
tree | 2e70d0804b597ec4581ede9a16c28b6506993a28 /src/clang.rs | |
parent | d5ca4e7e90a3a5ebfeff1041c7eaeb7596d9c1a5 (diff) |
Untry.
Use the ? operator instead of try, and add some more uses of it on Option<> that
were straight-forward.
Diffstat (limited to 'src/clang.rs')
-rw-r--r-- | src/clang.rs | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/clang.rs b/src/clang.rs index c0c96e5e..cb873994 100644 --- a/src/clang.rs +++ b/src/clang.rs @@ -903,8 +903,8 @@ impl Type { /// have a valid layout. pub fn fallible_layout(&self) -> Result<::ir::layout::Layout, LayoutError> { use ir::layout::Layout; - let size = try!(self.fallible_size()); - let align = try!(self.fallible_align()); + let size = self.fallible_size()?; + let align = self.fallible_align()?; Ok(Layout::new(size, align)) } |