Re:Contracts For CoffeeScript
by clyfe on Tuesday August 30, 2011 @05:18AM
(#2940674)
Can't this be implemented as a DSL? https://gist.github.com/1180516
I think this can be extended to custom types too.
[ Parent
| on HN ]
First, I don't think what you show is a DSL -- it's just some functions. Rather, what Tim has implemented is a DSL.
Second, you need proxies to handle things like functions and mutable arrays.
Third, that there's a DSL for describing contracts is, I think, a large part of the point.