From: "jeremyevans0 (Jeremy Evans)" Date: 2022-07-29T23:06:58+00:00 Subject: [ruby-dev:51188] [Ruby master Bug#18946] Time#to_date returns incorrect date Issue #18946 has been updated by jeremyevans0 (Jeremy Evans). `Time#to_datetime` does not operate the same way, which seems like an undesirable inconsistency: ```ruby Time.local(1499, 12, 27).to_datetime => # Time.local(1499, 12, 27).to_date => # ``` ---------------------------------------- Bug #18946: Time#to_date returns incorrect date https://bugs.ruby-lang.org/issues/18946#change-98527 * Author: kei-p (Keisuke Ishizawa) * Status: Open * Priority: Normal * ruby -v: 3.1.2 * Backport: 2.7: UNKNOWN, 3.0: UNKNOWN, 3.1: UNKNOWN ---------------------------------------- Time#to_date returns incorrect date. Actual Behavior: ``` Time.local(1499, 12, 27).to_date => # ``` Expected Behavior: ``` Time.local(1499, 12, 27).to_date => # ``` -- https://bugs.ruby-lang.org/