Skip to content

Commit a22539b

Browse files
committed
Implement has_dtor method in TypeContents
1 parent 4cb3bd5 commit a22539b

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

src/librustc/middle/ty.rs

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2012,6 +2012,10 @@ impl TypeContents {
20122012
pub fn inverse(&self) -> TypeContents {
20132013
TypeContents { bits: !self.bits }
20142014
}
2015+
2016+
pub fn has_dtor(&self) -> bool {
2017+
self.intersects(TC::OwnsDtor)
2018+
}
20152019
}
20162020

20172021
impl ops::BitOr<TypeContents,TypeContents> for TypeContents {

0 commit comments

Comments
 (0)