You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I like circle($fn=6), but I don't see it in the haskell api. While it is possible to encode such optional arguments in haskell, I think a quasiquoter would be better.
hex1 d = [scad| circle(d, $fn=6) |] -- too light
hex2 d = [scad2d| circle($$d, $fn=6) |] -- too heavy
hex3 d = [scad| circle($(d), $fn=6) |] -- just right?
Activity
ovitus commentedon Aug 25, 2024
Second this. How can this be done via Haskell?
aavogt commentedon Aug 25, 2024
https://github.com/Haskell-Things/ImplicitCAD/blob/master/programs/extopenscad.hs#L168 shows how it parses scad/runs scad files. SymbolicObj3 contains functions, so the QuasiQuoter probably has to run the parser at runtime because there's no Lift instance, ie. it probably will look like:
But maybe the result doesn't have to be in IO.