Python syntax in Lisp and Scheme
Doug Tolton
doug at nospam.com
Thu Oct 9 16:34:35 EDT 2003
Andrew Dalke wrote:
> Me:
>
>>>Note that I did not at all make reference to macros. Your statements
>>>to date suggest that your answer to the first is "no."
>
>
> Doug Tolton:
>
>>That's not exactly my position, rather my position is that just about
>>anything can and will be abused in some way shape or fashion. It's a
>>simple fact of working in teams. However I would rather err on the side
>>of abstractability and re-usability than on the side of forced
>
> restrictions.
>
> You are correct. I misremembered "Tolton" as "Tilton" and confused
> you with someone else. *blush*
Heh, yeah I've noticed that a couple of times. Poor Kenny keeps getting
blamed for things I've said. D'oh!
>
> My answer, btw, that the macro preprocessor in C is something
> which is useful and too easily prone to misuse. Eg, my original
> C book was "C for native speakers of Pascal" and included in
> the first section a set of macros like
>
> #define BEGIN {
> #define END }
I agree the C macro system is constantly abused. Then again, I haven't
ever been a really big fan of the C macro system, primarily because even
if it's used correctly it has always struck me as an ugly hack. I don't
think that's because it's overly expressive and powerful though, rather
I think it's because of it's limitations and foreign feeling syntax.
>
> It's not possible to get rid of cpp for C because the language
> is too weak, but it is something which takes hard experience to
> learn when not to use.
>
> As for a language feature which should never be used. Alex Martelli
> gave an example of changing the default definition for == between
> floats, which broke other packages, and my favorite is "OPTION
> BASE 1" in BASIC or its equivalent in Perl and other langauges.
> That is, on a per-program (or even per-module) basis, redefine
> the 0 point offset for an array.
Again, I can see setting corporate wide policies that specify if you
change the OPTION BASE, we are going to take you out behind the shed and
beat you silly. I don't think the existence of OPTION BASE is a
problem, personally I think it's when someone decides they want to
change the OPTION BASE to 0 while everyone else is still using 1. That
doesn't necessarily imply that OPTION BASE is by itself and evil construct.
--
Doug Tolton
(format t "~a@~a~a.~a" "dtolton" "ya" "hoo" "com")
More information about the Python-list
mailing list