News for hackers. Stuff that matters.
Re:Garbage collected smart pointers in Rust via concurrent c... by maplant on Friday December 13, 2024 @05:50PM (#42413047)
Ah, I meant syntax rules, but syntax case is supported - there’s just no way to create syntax objects so it’s practically not useful.

My email is on my website, if you have any other questions feel free to shoot me an email.

Re:Garbage collected smart pointers in Rust via concurrent c... by maplant on Saturday December 14, 2024 @08:18PM (#42420739)
Wait, never mind, I did implement syntax objects. So yes, there is syntax case. There are couple of limitations but it mostly works
Re:Garbage collected smart pointers in Rust via concurrent c... by bjoli on Tuesday December 17, 2024 @06:01AM (#42440328)
I could't see any datum->syntax or syntax->datum anywhere.

If you have it, you know you can just implement syntax-rules in syntax-case? I do believe that is how chez, guile and racket does it.

Re:Garbage collected smart pointers in Rust via concurrent c... by maplant on Tuesday December 17, 2024 @05:01PM (#42445796)
Those two functions are indeed missing. However, you can create syntax objects with `syntax-quote`. Again, lots of missing functionality. They shouldn't be hard to implement tho, I just need to add template ids to the transformer.

If you're wondering how the hygiene works, each Identifier besides its name includes a set of "marks" (random unsigned integers). Identifiers are only equal if each name and their marks are equal. There's quite a bit more to this, but I feel you may be aware of how this works.

I do know. I haven't done that yet for no real practical reason besides some vestigial code that I have yet to remove. They are basically implemented the same already, under the hood they are both just transformers, I just haven't removed the AST code for syntax rules.