Sha256: c536591c73f1267319b6c417bfd31f184412280bbef2888f4ee02a5c8201544f
Contents?: true
Size: 573 Bytes
Versions: 80
Compression:
Stored size: 573 Bytes
Contents
# frozen_string_literal: true module ActionView # :nodoc: class Template # :nodoc: class Inline < Template # :nodoc: # This finalizer is needed (and exactly with a proc inside another proc) # otherwise templates leak in development. Finalizer = proc do |method_name, mod| # :nodoc: proc do mod.module_eval do remove_possible_method method_name end end end def compile(mod) super ObjectSpace.define_finalizer(self, Finalizer[method_name, mod]) end end end end
Version data entries
80 entries across 77 versions & 8 rubygems