Skip to content

Commit

Permalink
time: make time.Weekday data type public so that it can be pattern ma…
Browse files Browse the repository at this point in the history
…tched (#57)

* time: make Weekday public

* moon info

---------

Co-authored-by: Yorkin <[email protected]>
  • Loading branch information
bikallem and Yoorkin authored Sep 23, 2024
1 parent ed9ca70 commit ef37428
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 2 deletions.
10 changes: 9 additions & 1 deletion time/time.mbti
Original file line number Diff line number Diff line change
Expand Up @@ -172,7 +172,15 @@ impl PlainTime {
with_second(Self, Int) -> Self!
}

type Weekday
pub enum Weekday {
Monday
Tuesday
Wednesday
Thursday
Friday
Saturday
Sunday
}
impl Weekday {
op_equal(Self, Self) -> Bool
to_string(Self) -> String
Expand Down
2 changes: 1 addition & 1 deletion time/weekday.mbt
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@
// See the License for the specific language governing permissions and
// limitations under the License.

enum Weekday {
pub enum Weekday {
Monday
Tuesday
Wednesday
Expand Down

0 comments on commit ef37428

Please sign in to comment.