Skip to content

Commit

Permalink
Merge pull request #8943 from koic/update_doc_for_flip_flop
Browse files Browse the repository at this point in the history
Update doc for `Lint/FlipFlop`
  • Loading branch information
koic committed Oct 27, 2020
2 parents fd65a6b + d5b2229 commit 51cda39
Show file tree
Hide file tree
Showing 2 changed files with 16 additions and 4 deletions.
10 changes: 8 additions & 2 deletions docs/modules/ROOT/pages/cops_lint.adoc
Expand Up @@ -1565,8 +1565,14 @@ end
| -
|===

This cop looks for uses of flip-flop operator.
flip-flop operator is deprecated since Ruby 2.6.0.
This cop looks for uses of flip-flop operator
based on the Ruby Style Guide.

Here is the history of flip-flops in Ruby.
flip-flop operator is deprecated in Ruby 2.6.0 and
the deprecation has been reverted by Ruby 2.7.0 and
backported to Ruby 2.6.
See: https://bugs.ruby-lang.org/issues/5400

=== Examples

Expand Down
10 changes: 8 additions & 2 deletions lib/rubocop/cop/lint/flip_flop.rb
Expand Up @@ -3,8 +3,14 @@
module RuboCop
module Cop
module Lint
# This cop looks for uses of flip-flop operator.
# flip-flop operator is deprecated since Ruby 2.6.0.
# This cop looks for uses of flip-flop operator
# based on the Ruby Style Guide.
#
# Here is the history of flip-flops in Ruby.
# flip-flop operator is deprecated in Ruby 2.6.0 and
# the deprecation has been reverted by Ruby 2.7.0 and
# backported to Ruby 2.6.
# See: https://bugs.ruby-lang.org/issues/5400
#
# @example
# # bad
Expand Down

0 comments on commit 51cda39

Please sign in to comment.