Is there a way to define a struct so that it has a field whose value is
filled in (instead of passed to the constructor) with a value derived from
other fields? For example, could you define a struct foo with two explicit
fields, x and y, plus a field called z whose value is computed as (+ x y)
ngs appear. In
> this context, some of `foo`'s lexical information is reserved so that
> `struct-out` works correctly.
> >
> > On 6/3/21 5:01 PM, flirora wrote:
> >
> >
> > Am I correct in assuming that given a definition like
> >
> > (struct f
Am I correct in assuming that given a definition like
(struct foo (x) #:constructor-name bar)
I then can't define something named foo in the same module, even though
there's no constructor called foo?
--
You received this message because you are subscribed to the Google Groups
"Racket Users"
3 matches
Mail list logo