doug-moen / openscad2

better abstraction mechanisms for OpenSCAD
Boost Software License 1.0
25 stars 3 forks source link

Definitions and Scoping #2

Closed gwadej closed 9 years ago

gwadej commented 9 years ago

In the section Unified Definition Syntax, you show two styles of function definition:

hypot = function(x,y) sqrt(x^2 + y^2);

and hypot(x,y) = sqrt(x^2 + y^2);

Why two? What is the purpose of the first one? The only thing I can think of is anonymous functions/lambdas. Is this the intent?

gwadej commented 9 years ago

This is clarified in the "Functions" RFC. A reference to that section might be in order.