ASPN ActiveState Programmer Network
ActiveState
/ Home / Perl / PHP / Python / Tcl / XSLT /
/ Safari / My ASPN /
Cookbooks | Documentation | Mailing Lists | Modules | News Feeds | Products | User Groups


Recent Messages
List Archives
About the List
List Leaders
Subscription Options

View Subscriptions
Help

View by Topic
ActiveState
.NET Framework
Open Source
Perl
PHP
Python
Tcl
Web Services
XML & XSLT

View by Category
Database
General
SOAP
System Administration
Tools
User Interfaces
Web Programming
XML Programming


MyASPN >> Mail Archive >> python-list
python-list
exceptions
by Jacek Generowicz other posts by this author
Jun 9 2004 8:45PM messages near this date
exceptions | exceptions
hungjunglu@[...].com (Hung Jung Lu) writes:

>  Alexander Schmolck <a.schmolck@[...].net> wrote:
>  > How do younger languages like IO make this point more forcefully than lisp,
>  > smalltalk etc -- languages which have been around for decades?
>  
>  Double checked with Lisp just now. And Lisp did not allow me to
>  redefine "if", "setq", "t", etc.

I presume you mean Common Lisp. I'm pretty sure that Scheme allows you
to do this without any restriction.

>  If there are tricks in Lisp to intercept "if", "setq", etc.I'd like
>  to know.

In Common Lisp you are not allowed to rediefine any external symbols
in the COMMON-LISP package:

  http://www.lisp.org/HyperSpec/Body/sec_11-1-2-1.html

and, in particular,

  http://www.lisp.org/HyperSpec/Body/sec_11-1-2-1-2.html

... so you define your own versions in another package. If you want to
know more about the issues surrounding this, then I suggest you ask on
c.l.lisp, as this is, after all, c.l.python.

>  Same if these limitations are specific to some particular
>  implementations of Lisp.

If by "Lisp" you mean "Common Lisp": no. If by "Lisp" you mean "the
Lisp language family" and by "implementation" you mean "dialect": yes.

>  I greatly suspect that these limitations of Lisp are general, since
>  Lisp does not naturally have prototype-based scopes like
>  onion-skins, and overriding things like "if" could more easily
>  create havoc.

Python does not expose pointers to the programmer. I greatly suspect
that this limitation is general to all programming languages, as this
could easily create havoc :-)
Thread:
A Schmolck
hungjunglu
Michele Simionato
hungjunglu
peter
A Schmolck
Jacek Generowicz
Michele Simionato
Michele Simionato
hungjunglu
hungjunglu
A Schmolck
A Schmolck
hungjunglu
A Schmolck
mwh
hungjunglu
lbates
jjl
peter

Privacy Policy | Email Opt-out | Feedback | Syndication
© ActiveState Software Inc. All rights reserved