On Thu, Mar 4, 2021 at 3:24 PM Dimaugh Silvestris
wrote:
>
> On Thu, 4 Mar 2021 at 19:29, Sam Tobin-Hochstadt wrote:
>>
>> It doesn't print that way because that wouldn't turn back into the original
>> value when evaluated, since it's quoted.
>
>
> Is there any other way?
> If not, I might consi
On Thu, 4 Mar 2021 at 19:29, Sam Tobin-Hochstadt
wrote:
> It doesn't print that way because that wouldn't turn back into the
> original value when evaluated, since it's quoted.
>
Is there any other way?
If not, I might consider the possibility of having a struct type for each
of those ugens, but
Wow, so great to hear the a SuperCollider client in Racket is on the horizon:)
--
Yury Bulka
https://mamot.fr/@setthemfree
#NotOnFacebook
Dimaugh Silvestris writes:
> I have a struct defined as:
> (struct ugen sc.unit (name rate inputs)
> #:methods gen:custom-write
> [(define write-proc
I think you want to add `#:property prop:custom-print-quotable 'never`
to that struct declaration, and then it will behave as you wanted.
Sam
On Thu, Mar 4, 2021 at 11:44 AM Dimaugh Silvestris
wrote:
>
> I have a struct defined as:
> (struct ugen sc.unit (name rate inputs)
> #:methods gen:cust
I have a struct defined as:
(struct ugen sc.unit (name rate inputs)
#:methods gen:custom-write
[(define write-proc
(make-constructor-style-printer
[λ (x) (let [(rate (ugen-rate x))
(name (symbol-append (ugen-name x) ':))]
(cond [(eq? rate 'ar) name]
5 matches
Mail list logo