From: blin Date: Wed, 1 Nov 2023 10:41:07 +0000 (+0000) Subject: calendar: do not call day-of-week twice in weekday? X-Git-Url: https://gitweb.factorcode.org/gitweb.cgi?p=factor.git;a=commitdiff_plain;h=46061a0d32251ef1bdb085dca383170a2b2f5e19 calendar: do not call day-of-week twice in weekday? --- diff --git a/basis/calendar/calendar.factor b/basis/calendar/calendar.factor index 8b326eb26e..1682001e6b 100644 --- a/basis/calendar/calendar.factor +++ b/basis/calendar/calendar.factor @@ -738,7 +738,7 @@ ALIAS: last-day-of-week saturday : december? ( timestamp -- ? ) month>> 12 = ; : weekend? ( timestamp -- ? ) day-of-week { 0 6 } member? ; -: weekday? ( timestamp -- ? ) day-of-week weekend? not ; +: weekday? ( timestamp -- ? ) weekend? not ; : same-or-next-business-day ( timestamp -- timestamp' ) dup day-of-week {