Guido van Rossum sagte: > [Walter Doerwald] >> For me '@' looks like something that the compiler shouldn't see. > > I don't understand. Why? Is that what @ means in other languages? Not > in JDK 1.5 -- the compiler definitely sees it. @ has no meaning in current Python and is seldom used in normal text, so it seems to be perfect for an escape character that is used by a documentation extractor or preprocessor, i.e. for markup that is somehow "orthogonal" to the program source. But as part of a normal Python source it feels like a wart. >> How about: >> >> def foobar(self, arg): >> .author = AuthorInfo(author="GvR", version="1.0", > copyright="GPL", ...) >> .deprecated = True > > No, I want to reserve the leading dot for attribute assignment to a > special object specified by a 'with' statement, e.g. > > with self: > .foo = [1, 2, 3] > .bar(4, .foo) I know, but inside a function the leading dot could default to function attribute assigment in the absence of a with statement. That makes me wonder, what a leading dot should mean at class or module scope. Bye, Walter Dörwald
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