gregor icon indicating copy to clipboard operation
gregor copied to clipboard

Feature request: serializable periods

Open LiberalArtist opened this issue 3 years ago • 0 comments

Most of gregor's values work with racket/serialize, but periods currently do not:

$ racket
Welcome to Racket v7.9 [cs].
> (require gregor/period racket/serialize)
> (serialize (hours 1))
; serialize: contract violation
;   expected: serializable?
;   given: #<period of 1 hour>

Hopefully adding support would be as simple as using serializable-struct at https://github.com/97jaz/gregor/blob/76f1c593f475e9847d25f9d014d41289f16d3393/gregor-lib/gregor/private/period.rkt#L59

LiberalArtist avatar Jan 29 '21 21:01 LiberalArtist