-
Notifications
You must be signed in to change notification settings - Fork 357
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
Fix warnings #418
Merged
Merged
Fix warnings #418
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Compiled (eval'd) definitions for <=> and == were giving warnings. This is more efficient anyway and removes a stdlib dependency.
Simplify method lookup instead of depending on method_missing.
Avoid undefined variable warnings
avit
force-pushed
the
fix-warnings
branch
2 times, most recently
from
September 16, 2017 19:03
7ff22f2
to
21c41fc
Compare
Avoids warnings for already-defined methods. DRY locales path definition for loading I18n should be lazy-loaded in order to require it later in order after ActiveSupport. It appears that I18n is better at detecting already-defined core extension methods on ruby classes.
Avoid traversing rules twice, just check them all since single occurrences are terminating. Terminating is true as implied for .all? on empty sets.
The poorly-documented YAML coder allows us to tell YAML to use our Hash representation when encoding. This avoids warnings that `to_yaml` was redefined from the default Object implementation.
Until specs can be adjusted to reference IceCube objects explicitly, this permits lookup for the commonly used IceCube constants only, without polluting the global Object namespace with all methods and constants from IceCube.
Instead of traversing the string to replace multiple options, use built-in ruby methods to interpolate string templates in a single pass.
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Update code and specs to silence warnings. One valid warning remains for:
This final warning should be addressed for #407.