fixed fmt

This commit is contained in:
Shinichi Morimoto 2020-03-28 23:21:35 +09:00
parent 096f3d73be
commit f7d4a37f78
2 changed files with 7 additions and 3 deletions

View file

@ -2977,10 +2977,14 @@ class CGCollectJSONAttributesMethod(CGAbstractMethod):
ret += fill( ret += fill(
""" """
let conditions = ${conditions}; let conditions = ${conditions};
if !conditions.iter().any(|c| c.is_satisfied(SafeJSContext::from_ptr(cx), HandleObject::from_raw(obj), HandleObject::from_raw(obj))) { if !conditions.iter().any(|c|
c.is_satisfied(
SafeJSContext::from_ptr(cx),
HandleObject::from_raw(obj),
HandleObject::from_raw(obj))) {
return false; return false;
} }
rooted!(in(cx) let mut temp = UndefinedValue()); rooted!(in(cx) let mut temp = UndefinedValue());
if !get_${name}(cx, obj, this, JSJitGetterCallArgs { _base: temp.handle_mut().into() }) { if !get_${name}(cx, obj, this, JSJitGetterCallArgs { _base: temp.handle_mut().into() }) {
return false; return false;
} }

View file

@ -376,7 +376,7 @@ pub fn is_exposed_in(object: HandleObject, globals: Globals) -> bool {
let unwrapped = UncheckedUnwrapObject(object.get(), /* stopAtWindowProxy = */ 0); let unwrapped = UncheckedUnwrapObject(object.get(), /* stopAtWindowProxy = */ 0);
let dom_class = get_dom_class(unwrapped).unwrap(); let dom_class = get_dom_class(unwrapped).unwrap();
if (dom_class.global.is_empty()) && (!globals.is_empty()) { if (dom_class.global.is_empty()) && (!globals.is_empty()) {
return false return false;
} }
globals.contains(dom_class.global) globals.contains(dom_class.global)
} }