diff options
author | bors-servo <lbergstrom+bors@mozilla.com> | 2017-01-27 11:04:55 -0800 |
---|---|---|
committer | GitHub <noreply@github.com> | 2017-01-27 11:04:55 -0800 |
commit | 7d995d75e07798c1527d5ea3dd8a647ed79fe209 (patch) | |
tree | 83e736e1e2f2d48aa8ce9807be05595546b4ad75 | |
parent | 33df99a73784c1846b62f97ebff3848cdd76c3b1 (diff) | |
parent | d4f772b83ab0ed5d957ab51dbd096dec1d88076d (diff) |
Auto merge of #452 - emilio:dont-assert, r=fitzgenv0.20.5
Remove recently-added assertion that can legitimately trigger
This fails under BaseErrorResult in Stylo builds.
I have no idea right now why that isn't whitelisted (should be, given we're
calling it from TErrorResult's code generation).
Let's disable this pending further investigation since I don't have time to dig
into it right now.
r? @fitzgen
-rw-r--r-- | Cargo.lock | 2 | ||||
-rw-r--r-- | Cargo.toml | 2 | ||||
-rw-r--r-- | src/codegen/mod.rs | 7 |
3 files changed, 8 insertions, 3 deletions
@@ -1,6 +1,6 @@ [root] name = "bindgen" -version = "0.20.4" +version = "0.20.5" dependencies = [ "aster 0.38.0 (registry+https://github.com/rust-lang/crates.io-index)", "cexpr 0.2.0 (registry+https://github.com/rust-lang/crates.io-index)", @@ -13,7 +13,7 @@ name = "bindgen" readme = "README.md" repository = "https://github.com/servo/rust-bindgen" documentation = "https://docs.rs/bindgen" -version = "0.20.4" +version = "0.20.5" build = "build.rs" [badges] diff --git a/src/codegen/mod.rs b/src/codegen/mod.rs index db17a3d1..7af70e98 100644 --- a/src/codegen/mod.rs +++ b/src/codegen/mod.rs @@ -287,7 +287,12 @@ impl CodeGenerator for Item { } debug!("<Item as CodeGenerator>::codegen: self = {:?}", self); - assert!(whitelisted_items.contains(&self.id())); + if !whitelisted_items.contains(&self.id()) { + // TODO(emilio, #453): Figure out what to do when this happens + // legitimately, we could track the opaque stuff and disable the + // assertion there I guess. + error!("Found non-whitelisted item in code generation: {:?}", self); + } result.set_seen(self.id()); |