|
|
|
|
|
by javafu2
4512 days ago
|
|
For most of the used programming languages, a lambda captures values (like in Java or Python), and closure capture variables or scope (like in Scheme or Ruby), hence the name, a closure close (bind) the free variable of the closure to the ones of the lexical scope. The lack of checked exception transparency is for me something that goes in the right direction. The hidden message is 'Use checked exception only for IOs and please don't create your own exceptions, use already existing ones !' |
|
Closures come in two primary flavors, bind by value or bind by reference. Some languages implement only one of these, some implement both, some bind in completely different ways (e.g. lazy binding in Haskell).