mirror of
https://github.com/servo/servo.git
synced 2025-06-17 04:44:28 +00:00
auto merge of #1791 : Ms2ger/servo/conversions, r=jdm
This commit is contained in:
commit
b8de1b3ca7
3 changed files with 36 additions and 64 deletions
|
@ -1246,7 +1246,7 @@ for (uint32_t i = 0; i < length; ++i) {
|
|||
"if (%s) {\n"
|
||||
" ${declName} = None;\n"
|
||||
"} else {\n"
|
||||
" match JSValConvertible::from_jsval(${val}) {\n"
|
||||
" match JSValConvertible::from_jsval(cx, ${val}) {\n"
|
||||
" Some(val_) => ${declName} = Some(%s),\n"
|
||||
" None => %s\n"
|
||||
" }\n"
|
||||
|
@ -1261,7 +1261,7 @@ for (uint32_t i = 0; i < length; ++i) {
|
|||
if preSuccess or postSuccess:
|
||||
successVal = preSuccess + successVal + postSuccess
|
||||
template = (
|
||||
"match JSValConvertible::from_jsval(${val}) {\n"
|
||||
"match JSValConvertible::from_jsval(cx, ${val}) {\n"
|
||||
" None => %s,\n"
|
||||
" Some(v) => %s = %s\n"
|
||||
"}" % (failureCode, dataLoc, successVal))
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue