Thanks, but this does not solve the problem. I would need a solution which also
works more generally, e.g., for arrays nested in structs etc..
As far as I understand, the canonical way to extend serialize is to add the
prop:serializable property to the struct representing an array. But that
Here's one hack.
#lang racket/base
(require
math/array
(prefix-in rkt: racket/serialize))
(define secret-key 'array)
(define (serialize val)
(if (array? val)
(rkt:serialize (cons secret-key (array->list val)))
(rkt:serialize val)))
(define (deserialize val)
(define d
2 matches
Mail list logo