projects
/
cycript.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
0fe4a14
)
Fix @bool .valueOf() to return boolean, not number.
author
Jay Freeman (saurik)
<saurik@saurik.com>
Thu, 13 Sep 2012 08:52:14 +0000
(
01:52
-0700)
committer
Jay Freeman (saurik)
<saurik@saurik.com>
Thu, 13 Sep 2012 08:52:14 +0000
(
01:52
-0700)
ObjectiveC/Library.mm
patch
|
blob
|
blame
|
history
diff --git
a/ObjectiveC/Library.mm
b/ObjectiveC/Library.mm
index 1749d88d60a41270a50c51eb9685014a314bc30a..a113779c0beafbbc092d0ad705da238f62c7dbcc 100644
(file)
--- a/
ObjectiveC/Library.mm
+++ b/
ObjectiveC/Library.mm
@@
-959,7
+959,7
@@
NSObject *CYCopyNSObject(apr_pool_t *pool, JSContextRef context, JSValueRef valu
}
- (JSValueRef) cy$valueOfInContext:(JSContextRef)context { CYObjectiveTry_(context) {
- return [self cy$JSType] != kJSTypeBoolean ? CYCastJSValue(context, [self doubleValue]) : CYCastJSValue(context,
[self boolValue]
);
+ return [self cy$JSType] != kJSTypeBoolean ? CYCastJSValue(context, [self doubleValue]) : CYCastJSValue(context,
static_cast<bool>([self boolValue])
);
} CYObjectiveCatch }
@end