summaryrefslogtreecommitdiff
path: root/spec/ruby/core/array/constructor_spec.rb
diff options
context:
space:
mode:
authorJeremy Evans <code@jeremyevans.net>2019-08-11 13:14:38 -0700
committerHiroshi SHIBATA <hsbt@ruby-lang.org>2020-03-06 20:54:33 +0900
commite79fc05a4ca672816c6b737d00a85fea4aa6c2b7 (patch)
tree41d17c47d1322b1920ad4706b056d586d0730a80 /spec/ruby/core/array/constructor_spec.rb
parent2630757fb53f955d45bb67ccf8187d41b581bca1 (diff)
[ruby/prime] Fix Prime.include?
Previously, it would be an infinite loop if passed a non-prime integer. Also, Prime.include? should also provide similar results to Module#include? if passed a Module, so handle that. For consistency with Enumerable#include?, return false if passed other object types. Fixes Ruby Bug 10167. https://github.com/ruby/prime/commit/55dda6aa7f
Diffstat (limited to 'spec/ruby/core/array/constructor_spec.rb')
0 files changed, 0 insertions, 0 deletions