Issue #16969 has been reported by deivid (David Rodr=EDguez). ---------------------------------------- Bug #16969: False positive for warning against `public` without arguments i= nside method https://bugs.ruby-lang.org/issues/16969 * Author: deivid (David Rodr=EDguez) * Status: Open * Priority: Normal * ruby -v: ruby 2.7.1p83 (2020-03-31 revision a0c7c23c9c) [x86_64-linux] * Backport: 2.5: UNKNOWN, 2.6: UNKNOWN, 2.7: UNKNOWN ---------------------------------------- Hi! When running the following code: ```ruby def setup # make public so we can test it Admin::UsersController.send(:public, *Admin::UsersController.protected_= instance_methods) end ``` I'm getting the following warning: ``` warning: calling public without arguments inside a method may not have the = intended effect ``` It looks like a false positive to me. I'm guessing it's a bug in https://bugs.ruby-lang.org/projects/ruby-master/= repository/git/revisions/2993b24a1ecc5fa3cc9f140bfd80669c3a3b7b9c. -- = https://bugs.ruby-lang.org/ Unsubscribe: <mailto:ruby-core-request / ruby-lang.org?subject=3Dunsubscribe> <http://lists.ruby-lang.org/cgi-bin/mailman/options/ruby-core>