A RetroSearch Logo

Home - News ( United States | United Kingdom | Italy | Germany ) - Football scores

Search Query:

Showing content from http://mail.python.org/pipermail/python-dev/2001-February/012920.html below:

[Python-Dev] SyntaxError for illegal literals

[Python-Dev] SyntaxError for illegal literals [Python-Dev] SyntaxError for illegal literalsTim Peters tim.one@home.com
Thu, 15 Feb 2001 04:07:38 -0500
[Ka-Ping Yee]
> ...
> The only exceptions that don't currently conform, as far as i
> know, have to do with invalid literals.

Pretty much, but nothing's *that* easy.

Other examples:

+ If there are too many nested blocks, it raises SystemError(!).

+ MemoryError is raised if a dotted name is too long.

+ OverflowError is raised if a string is too long.

Note that those don't have to do with syntax, they're arbitrary
implementation limits.  So that's the rule:  raise

    SystemError if something is bigger than 20
    MemoryError if it's bigger than 1000
    OverflowError if it's bigger than an int

Couldn't be clearer <wink>.

+ SystemErrors are raised in many other places in the role of internal
assertions failing.  Those needn't be changed.




RetroSearch is an open source project built by @garambo | Open a GitHub Issue

Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo

HTML: 3.2 | Encoding: UTF-8 | Version: 0.7.4