From 223f096e9146a628794cdddae1d06530a115b62b Mon Sep 17 00:00:00 2001
From: Peter Leitzen <pleitzen@gitlab.com>
Date: Thu, 12 Sep 2019 12:51:38 +0000
Subject: [PATCH] Fix code docs for RuboCop's helper methods

`(const nil :Foo)` vs `(const nil? :Foo)`
---
 rubocop/code_reuse_helpers.rb | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/rubocop/code_reuse_helpers.rb b/rubocop/code_reuse_helpers.rb
index 0929a55d90134..63019c439438d 100644
--- a/rubocop/code_reuse_helpers.rb
+++ b/rubocop/code_reuse_helpers.rb
@@ -25,7 +25,7 @@ def file_path_for_node(node)
 
     # Returns the name of a constant node.
     #
-    # Given the AST node `(const nil :Foo)`, this method will return `:Foo`.
+    # Given the AST node `(const nil? :Foo)`, this method will return `:Foo`.
     def name_of_constant(node)
       node.children[1]
     end
@@ -87,7 +87,7 @@ def in_directory?(node, directory)
 
     # Returns the receiver name of a send node.
     #
-    # For the AST node `(send (const nil :Foo) ...)` this would return
+    # For the AST node `(send (const nil? :Foo) ...)` this would return
     # `'Foo'`.
     def name_of_receiver(node)
       name_of_constant(node.children.first).to_s
-- 
GitLab