<< Previous Message Main Index Next Message >>
<< Previous Message in Thread This Month Next Message in Thread >>
Date   : Wed, 23 Sep 2009 11:44:48 +0100
From   : ats@... (Adam Sampson)
Subject: Beeb, this was your grandma!

Philip Pemberton <philpem@...> writes:

> Interestingly Pascal seems to be the only language that supports
> this...

Nope -- they were in ALGOL, so many ALGOL-inspired languages have nested
functions as well: occam, Ada, Modula-2, etc. They're usually available
in modern dynamic languages like Perl and Python, most functional
languages have them, and there's even a GCC extension that lets you use
them in C.

I use them all the time myself, but most programmers seem to be
blissfully unaware of how useful they are. The only downside I've found
is that writing unit tests for them is a pain...

-- 
Adam Sampson <ats@...      >                         <http://offog.org/>
<< Previous Message Main Index Next Message >>
<< Previous Message in Thread This Month Next Message in Thread >>