mirror of
https://github.com/servo/servo.git
synced 2025-07-23 23:33:43 +01:00
Use specific negative assertion for DOM globalscope
This commit is contained in:
parent
5475059df7
commit
1ba2b67b00
1 changed files with 1 additions and 1 deletions
|
@ -610,6 +610,6 @@ fn timestamp_in_ms(time: Timespec) -> u64 {
|
|||
unsafe fn global_scope_from_global(global: *mut JSObject) -> DomRoot<GlobalScope> {
|
||||
assert!(!global.is_null());
|
||||
let clasp = get_object_class(global);
|
||||
assert!(((*clasp).flags & (JSCLASS_IS_DOMJSCLASS | JSCLASS_IS_GLOBAL)) != 0);
|
||||
assert_ne!(((*clasp).flags & (JSCLASS_IS_DOMJSCLASS | JSCLASS_IS_GLOBAL)), 0);
|
||||
root_from_object(global).unwrap()
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue