react-native/React
Jonathan Ballerano eaac3b57ee Add a type cast to RCT_ENUM_CONVERTER for C++ compatibility
Summary:
C++ doesn't provide an implicit cast to an enum value from the enum's backing type. When a `.mm` file calls `RCT_ENUM_CONVERTER`, we end up with the following compiler error:
> Error: cannot initialize return object of type `<TypeName>` with an rvalue of type `NSInteger`

Since `RCT_ENUM_CONVERTER` is a macro, this error will appear whenever we try to expand the macro in a C++ context.

The project compiles and runs as expected when this additional cast is added 😃
Closes https://github.com/facebook/react-native/pull/14408

Reviewed By: javache

Differential Revision: D5215584

Pulled By: jballer

fbshipit-source-id: 7f4464afd7cd9dc9a014f646278bae20731f08ba
2017-06-15 19:07:21 -07:00
..
Base Add a type cast to RCT_ENUM_CONVERTER for C++ compatibility 2017-06-15 19:07:21 -07:00
CxxBridge Added RCTInspectorDevServerHelper call in FBReactJSExecutor. Added UTF8StringForSourceURL 2017-06-14 14:10:10 -07:00
CxxModule Added RCTInspectorDevServerHelper call in FBReactJSExecutor. Added UTF8StringForSourceURL 2017-06-14 14:10:10 -07:00
CxxUtils Explicitly cast to (bool) where needed on objc with folly::dynamic 2017-04-18 15:36:20 -07:00
DevSupport Make RCTSamplingProfilerPackagerMethod not depend on RCTBridge 2017-06-15 12:07:34 -07:00
Executors Remove RCTBatchedBridge rule and all uses from the tree 2017-04-19 17:00:43 -07:00
Inspector Connection management 2017-06-08 07:45:53 -07:00
Modules Make RCTSamplingProfilerPackagerMethod not depend on RCTBridge 2017-06-15 12:07:34 -07:00
Profiler Fix memory leak in RN fbsystrace support 2017-05-15 03:47:15 -07:00
React.xcodeproj Remove unused folly/File.{h,cpp} from OSS React Xcode project 2017-06-15 13:05:05 -07:00
ReactLegacy.xcodeproj Make RCTSamplingProfilerPackagerMethod not depend on RCTBridge 2017-06-15 12:07:34 -07:00
Views Scrollview updatedChildFrames data controlled by prop 2017-06-08 12:03:02 -07:00
third-party.xcconfig More attempts to fix Travis CI runs 2017-05-10 04:32:54 -07:00