提交 54b5596a 编写于 作者: A amitkumarsuroliya

Correcting `NameError` error message in `mattr_reader` method. Since this...

Correcting `NameError` error message in `mattr_reader` method. Since this commit https://github.com/rails/rails/commit/7dfbd91b0780fbd6a1dd9bfbc176e10894871d2d, `NameError` includes attribute_name also in error message [ci skip]

 
上级 77370f27
......@@ -19,9 +19,9 @@ class Module
# The attribute name must be a valid method name in Ruby.
#
# module Foo
# mattr_reader :"1_Badname "
# mattr_reader :"1_Badname"
# end
# # => NameError: invalid attribute name
# # => NameError: invalid attribute name: 1_Badname
#
# If you want to opt out the creation on the instance reader method, pass
# <tt>instance_reader: false</tt> or <tt>instance_accessor: false</tt>.
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册