diff options
author | Jeremy Evans <code@jeremyevans.net> | 2019-05-11 16:32:00 -0700 |
---|---|---|
committer | Jeremy Evans <code@jeremyevans.net> | 2019-05-30 18:34:45 -0700 |
commit | 1cd93f1cdfbe6f7e71b05b3f8e707f21d70e94ba (patch) | |
tree | a1741805f80749f90f35d21f0f646148b41dd610 /NEWS | |
parent | 856593cc4972562d2ab0a59a61f38fe3a4a863ab (diff) | |
download | ruby-1cd93f1cdfbe6f7e71b05b3f8e707f21d70e94ba.tar.gz |
Allow DelegateClass() to module_eval given block
Methods that return classes often module_eval the given block
(e.g. Class.new and Struct.new). This allows DelegateClass to
work similarly. This makes it easier to use DelegateClass
directly without subclassing, so as not to create an unnecessary
subclass.
Implements [Feature #15842]
Diffstat (limited to 'NEWS')
-rw-r--r-- | NEWS | 5 |
1 files changed, 5 insertions, 0 deletions
@@ -118,6 +118,11 @@ Date:: new Japanese era as an informal extension, until the new JIS X 0301 is issued. [Feature #15742] +Delegate:: + + * Object#DelegateClass accepts a block and module_evals it in the context + of the returned class, similar to Class.new and Struct.new. + ERB:: * Prohibit marshaling ERB instance. |