From: "trans (Thomas Sawyer)" Date: 2012-09-20T05:29:03+09:00 Subject: [ruby-core:47603] [ruby-trunk - Feature #7019] allow `private` and `protected` keywords to take blocks Issue #7019 has been updated by trans (Thomas Sawyer). Probably not much, but it is possible. Could be "protected" instead as well. Also, other helpers can be created besides attr. My point is only that it needs to accept an array should the helper return multiple methods/symbols. Or are you thinking that `private def` would be some kind of keyword thing? ---------------------------------------- Feature #7019: allow `private` and `protected` keywords to take blocks https://bugs.ruby-lang.org/issues/7019#change-29545 Author: alexeymuranov (Alexey Muranov) Status: Open Priority: Normal Assignee: Category: core Target version: 2.0.0 =begin I like to indent my private methods one level deeper, but this indentation is inconsistent with the syntax: class C def f # end private def g # end end I think it would be nice if the (({private})) keyword could take a block, then i would write: class C def f # end private do def g # end end end =end -- http://bugs.ruby-lang.org/