2 new comment-like characters in Python to aid development?

BJörn Lindqvist bjourne at gmail.com
Fri Mar 9 11:59:24 CET 2007


On 9 Mar 2007 02:31:14 -0800, dbhbarton at googlemail.com
<dbhbarton at googlemail.com> wrote:
> Thanks for the thoughts.
>
> > This could be implemented without new syntax: just make your editor
> > recognize some special comments, and apply the highlighting to the
> > following block. By example,
> >
> >                 # XXX Remove this when FuruFaifa is fixed to always provide
> >                 # XXX the names in the same order
> >                 names.sort()
> >                 names.reverse()
>
> Yes I recognise that we can use existing comments for this purpose,
> and if I was suitably gifted I guess I could try to make the IDE
> recognise these 'special comments', and maybe even work out what block
> they're meant to apply to. Of course I'll still argue that the WIP
> character would be a more elegant, speedy and versatile alternative.

But you are overloading the ? character for a purpose which it totally
was not meant for. What the character means really depends on what
person you are asking. To me, it means that what precedes it is
something someone or something does not know and wants to know the
answer to. To me, it really does not mean that what follows it is work
in progress.

Even if I could intuitively tell that a question mark represents a
work in progress, that information is not very useful. Similarly to
the "under construction" animated gifs that were popular on the web in
the mid 90-ties, the symbol does not convey any useful information.
WHY is it a work in progress? Is there something wrong with it?

?def foobar():
    do stuff

The question mark does not leave me any the wiser. Now if you replace
that question mark with a comment:

# foobar() is buggy because it throws weird exceptions when x = 42.
def foobar():
    do stuff

That gives me some useful information.

-- 
mvh Björn



More information about the Python-list mailing list