[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Fire defun by typing keyword

From: Emanuel Berg
Subject: Re: Fire defun by typing keyword
Date: Tue, 05 Nov 2013 23:38:14 +0100
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/23.4 (gnu/linux)

Kai Gro├čjohann <> writes:

> for (int i=0; i<10; i++) {
>     _
> }
> You could create an abbrev that reads a type (int), a
> variable (i), an initial value (0), a final value
> (10), and then produces the above, where _ indicates
> the position of the cursor.

Wow! I actually had that exact same thought a couple of
years ago:

Back then I thought there was basically no thinking at
all to programming, it was just a matter of finger
habits, eye-hand coordination, eye-brain interpretation
(as opposed to the crude "reading"), etc., all physical
in one way or another. Typing and everything should be
so fast so it could "keep up" with the thinking (which
was trivial in a pleasant, not boring, sense).

While I still think this aspect is grossly overlooked, I
don't think it is "all about that" anymore. I certainly
have the time to write a for loop now and then without
my mind beaming away in some other direction, hopelessly
lost forever after.

But it is an amazing thought - imagine to have an entire
programming language coded anew like that, with every
construct just a short abbrev away. It would make for
"parametric" programming if there ever was one.

Emanuel Berg, programmer-for-rent. CV, projects, etc at uXu
underground experts united:

reply via email to

[Prev in Thread] Current Thread [Next in Thread]