From: "matz (Yukihiro Matsumoto) via ruby-core" Date: 2023-10-12T08:30:15+00:00 Subject: [ruby-core:115012] [Ruby master Feature#13933] Add Range#empty? Issue #13933 has been updated by matz (Yukihiro Matsumoto). Status changed from Open to Rejected One drawback of `Range#empty?` is that we have several corner cases that cannot determine emptiness correctly (e.g., regarding exclude_end ranges or infinity). Upon the fact we don't see the real-world use-case yet, we reject the proposal for the moment. FYI, `Range#overlap?` has similar corner cases, it's better to document clearly somewhere. Matz. ---------------------------------------- Feature #13933: Add Range#empty? https://bugs.ruby-lang.org/issues/13933#change-104882 * Author: ted (Ted Johansson) * Status: Rejected * Priority: Normal ---------------------------------------- Range already responds to #size. It would be nice if it also responded to predicate #empty? :-) -- https://bugs.ruby-lang.org/ ______________________________________________ ruby-core mailing list -- ruby-core@ml.ruby-lang.org To unsubscribe send an email to ruby-core-leave@ml.ruby-lang.org ruby-core info -- https://ml.ruby-lang.org/mailman3/postorius/lists/ruby-core.ml.ruby-lang.org/