mirror of
https://github.com/servo/servo.git
synced 2025-07-22 23:03:42 +01:00
Update bool pattern matching into if-else
This commit is contained in:
parent
65370f17c9
commit
abd577bfd4
5 changed files with 50 additions and 49 deletions
|
@ -6399,13 +6399,10 @@ class CGDictionary(CGThing):
|
|||
conversion = (
|
||||
"{\n"
|
||||
" rooted!(in(cx) let mut rval = UndefinedValue());\n"
|
||||
" match r#try!(get_dictionary_property(cx, object.handle(), \"%s\", rval.handle_mut())) {\n"
|
||||
" true => {\n"
|
||||
" if r#try!(get_dictionary_property(cx, object.handle(), \"%s\", rval.handle_mut())) {\n"
|
||||
"%s\n"
|
||||
" },\n"
|
||||
" false => {\n"
|
||||
" } else {\n"
|
||||
"%s\n"
|
||||
" },\n"
|
||||
" }\n"
|
||||
"}") % (member.identifier.name, indent(conversion), indent(default))
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue