diff options
author | k0kubun <k0kubun@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2017-09-26 11:50:07 +0000 |
---|---|---|
committer | k0kubun <k0kubun@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2017-09-26 11:50:07 +0000 |
commit | 9d389d6510d8dadfa2ee1e246b5e205d2eeb7de4 (patch) | |
tree | 93c736017a28dc1958ae2ddfd58e788510535538 /lib | |
parent | 054e4bc4fdcf6e0c5aa907d4fbc455ed0f3ec3af (diff) | |
download | ruby-9d389d6510d8dadfa2ee1e246b5e205d2eeb7de4.tar.gz |
erb.rb: drop unreachable method
This seems to be unreachable from first introduction at r21286.
In ERB implementation, `#empty?` is only called for each member of
return value of `String#scan`, and `ERB::Compiler::PercentLine` is never
returned from `String#scan`.
Also, in `ERB::Compiler#compile`, as it's yielded only when stag is nil,
methods called to `ERB::Compiler::PercentLine` object yielded from
`ERB::Compiler::TrimScanner#scan` are only: `#nil?`, `#==`, `to_s`.
Thus `ERB::Compiler::PercentLine#empty?` is never used.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@60032 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'lib')
-rw-r--r-- | lib/erb.rb | 4 |
1 files changed, 0 insertions, 4 deletions
diff --git a/lib/erb.rb b/lib/erb.rb index 813ff98253..74974696d7 100644 --- a/lib/erb.rb +++ b/lib/erb.rb @@ -347,10 +347,6 @@ class ERB end attr_reader :value alias :to_s :value - - def empty? - @value.empty? - end end class Scanner # :nodoc: |