Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Incompatible pointer to integer conversion warnings in LDEventModel.m #58

Closed
llaborcz opened this issue Aug 2, 2016 · 0 comments
Closed

Comments

@llaborcz
Copy link

llaborcz commented Aug 2, 2016

There are the following warnings in the file LDEventModel.m

LDEventModel.m:60:30: warning: incompatible pointer to integer conversion assigning to 'BOOL' (aka 'signed char') from 'id _Nullable' [-Wint-conversion]
self.featureKeyValue = [dictionary objectForKey: kFeatureKeyValueServerKey];
^ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

LDEventModel.m:61:24: warning: incompatible pointer to integer conversion assigning to 'BOOL' (aka 'signed char') from 'id _Nullable' [-Wint-conversion]
self.isDefault = [dictionary objectForKey: kIsDefaultServerKey];
^ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
2 warnings generated.

Looking at the code:

    self.featureKeyValue = [dictionary objectForKey: kFeatureKeyValueServerKey];
    self.isDefault = [dictionary objectForKey: kIsDefaultServerKey];

It can be seen that objectForKey: (which returns id) is being cast to a BOOL.

Can you please fix this so that it's explicitly setting the BOOL to YES or NO?

markpokornycos added a commit that referenced this issue Mar 15, 2018
* adds enhanced sse event handling
# Conflicts:
#	LaunchDarkly.podspec
* moves stream url method out of LDConfig and into LDClientManager
* update versions
* cleanup 2 static analyzer issues
* cleanup hello-ios static analyzer warnings
markpokornycos added a commit that referenced this issue Mar 16, 2018
* SSE Enhanced Events (#58)

* adds enhanced sse event handling
# Conflicts:
#	LaunchDarkly.podspec
* moves stream url method out of LDConfig and into LDClientManager
* update versions
* cleanup 2 static analyzer issues
* cleanup hello-ios static analyzer warnings

* updates version to 2.11.0

* Updated CHANGELOG

* adds date to change log
markpokornycos added a commit that referenced this issue Mar 8, 2019
* renames schemes and targets to LaunchDarkly

* renames test target and headers to LaunchDarkly

* renames code and test folders to LaunchDarkly

* renames xcode project to LaunchDarkly

* renames workspace to LaunchDarkly

* renames modules and sets Catamorphic Co as license holder in block header comment

* renames podfile workspace and targets to LaunchDarkly

* renames Jazzy components to LaunchDarkly

* replaces outdated variable_name rule with identifier_name to clear swiftlint warnings

* renames workspace and scheme to LaunchDarkly in circleCI

* installs CocoaPods 1.6.0

* installs DarklyEventSource 4.0.1

* installs Quick 7.3.4 and Nimble 1.3.4

* installs SwiftLint 0.30.1

* Add instructions to integrate without a package manager  (#57)

* Replaces onServerUnavailable with ErrorObserver (#58)

* Adds new logging around variationAndSource (#59)

* Install keys to model objects (#60)

* Adds Automated Tests for missing coverage (#61)

* Decompress Blocks (#62)

* Refine flag version handling (#63)

* sets beta 3 version and updates public documents

* Add Platform Names to non-iOS frameworks (#65)

* renames all schemes, targets, and non-iOS products to include the platform

* updates changelog and instructions for non-iOS platforms
markpokornycos added a commit that referenced this issue Mar 8, 2019
* renames schemes and targets to LaunchDarkly

* renames test target and headers to LaunchDarkly

* renames code and test folders to LaunchDarkly

* renames xcode project to LaunchDarkly

* renames workspace to LaunchDarkly

* renames modules and sets Catamorphic Co as license holder in block header comment

* renames podfile workspace and targets to LaunchDarkly

* renames Jazzy components to LaunchDarkly

* replaces outdated variable_name rule with identifier_name to clear swiftlint warnings

* renames workspace and scheme to LaunchDarkly in circleCI

* installs CocoaPods 1.6.0

* installs DarklyEventSource 4.0.1

* installs Quick 7.3.4 and Nimble 1.3.4

* installs SwiftLint 0.30.1

* Add instructions to integrate without a package manager  (#57)

* Replaces onServerUnavailable with ErrorObserver (#58)

* Adds new logging around variationAndSource (#59)

* Install keys to model objects (#60)

* Adds Automated Tests for missing coverage (#61)

* Decompress Blocks (#62)

* Refine flag version handling (#63)

* sets beta 3 version and updates public documents

* Add Platform Names to non-iOS frameworks (#65)

* renames all schemes, targets, and non-iOS products to include the platform

* updates changelog and instructions for non-iOS platforms

* updates items for public release

* updates pods project
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant