Ignore:
Timestamp:
Jun 2, 2015, 2:24:10 PM (10 years ago)
Author:
[email protected]
Message:

JavaScriptCore: JSExport protocol with an NSInteger property converts negative values to 18446744073709552000
https://bugs.webkit.org/show_bug.cgi?id=145563

Patch by Keith Miller <[email protected]> on 2015-06-02
Reviewed by Darin Adler.

The Objective-C bindings were improperly converting negative
long long/NSIntegers to 18446744073709552000 because they
were converted to unsigned numbers.

  • API/ObjcRuntimeExtras.h:

(parseObjCType):

  • API/tests/testapi.mm:

(testObjectiveCAPIMain):
(checkNegativeNSIntegers):
(testObjectiveCAPI):

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/Source/JavaScriptCore/API/ObjcRuntimeExtras.h

    r174386 r185122  
    165165        return DelegateType::template typeInteger<long>();
    166166    case 'q':
    167         return DelegateType::template typeDouble<unsigned long long>();
     167        return DelegateType::template typeDouble<long long>();
    168168    case 'C':
    169169        return DelegateType::template typeInteger<unsigned char>();
Note: See TracChangeset for help on using the changeset viewer.