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

Suppress keyword arguments warning for Ruby 2.7.0 #511

Merged
merged 1 commit into from
Jan 15, 2020

Conversation

koic
Copy link
Contributor

@koic koic commented Jan 15, 2020

This PR suppresses the following keyword arguments warning for Ruby 2.7.0.

% bundle exec rspec spec/hashie/extensions/mash/symbolize_keys_spec.rb
(snip)

/Users/koic/src/github.com/hahie/hashie/spec/hashie/extensions/mash/symbolize_keys_spec.rb:29:
warning: Using the last argument as keyword parameters is
deprecated; maybe ** should be added to the call
/Users/koic/src/github.com/hahie/hashie/spec/hashie/extensions/mash/symbolize_keys_spec.rb:21:
warning: The called method `call' is defined here

For Ruby 2.8.0-dev (Ruby 3.0) the warning will be ArgumentError.
ruby/ruby#2794

This PR suppresses the following keyword arguments warning for Ruby 2.7.0.

```console
% bundle exec rspec spec/hashie/extensions/mash/symbolize_keys_spec.rb
(snip)

/Users/koic/src/github.com/hahie/hashie/spec/hashie/extensions/mash/symbolize_keys_spec.rb:29:
warning: Using the last argument as keyword parameters is
deprecated; maybe ** should be added to the call
/Users/koic/src/github.com/hahie/hashie/spec/hashie/extensions/mash/symbolize_keys_spec.rb:21:
warning: The called method `call' is defined here
```

For Ruby 2.8.0-dev (Ruby 3.0) the warning will be `ArgumentError`.
ruby/ruby#2794
@koic koic force-pushed the suppress_kwargs_warning_for_ruby_2_7_0 branch from 7c52c7d to 5704097 Compare January 15, 2020 03:54
@dblock dblock merged commit ac15574 into hashie:master Jan 15, 2020
@dblock
Copy link
Member

dblock commented Jan 15, 2020

👍

@koic koic deleted the suppress_kwargs_warning_for_ruby_2_7_0 branch January 16, 2020 01:41
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

Successfully merging this pull request may close these issues.

2 participants