[Tutor] Is there python editor or plugin for a python editor for curly brackets around code blocks?
vishwajeet singh
dextrous85 at gmail.com
Wed Aug 13 07:42:00 CEST 2008
try typing this on your python shell : *from __future__ import braces*
check the output:* SyntaxError: not a chance (<pyshell#0>, line 1)*
On Wed, Aug 13, 2008 at 10:15 AM, xbmuncher <xboxmuncher at gmail.com> wrote:
> Yes I think python is great in its simplicity in typing code but not in its
> absence of curly brackets to surround code blocks. Personally, it helps me
> visually see the code blocks as well as saves me constant pain when the
> compiler complains about broken/missing indents in the code.* I think it
> would be great if there was an editor for python or a plugin for an existing
> program to be able to use curly brackets { } when defining code blocks, and
> then maybe with a push of a button it can convert the curly bracket style
> code that ignores indents to the indent sensitive code that the python
> compiler wants. *It would save me a lot of headache in the way too many
> times I'm constantly trying to hunt down indentation problems in code
> (usually other people's code). I tried getting different editors with
> "auto-identing" as it is listed in the recommend python editors in the
> python website. However, these don't suffice in fixing most indenation
> problems... They sometimes even make it worse!
>
> Even visually a lot of people write their lines like this:
> def funcName(arg):
> bla bla bla
> more content of function
> if (this == that)
> do this
>
> Simple indentation errors can be a nightmare in determining whether if
> statements and other code blocks are inside of another code block or not....
> when all that seperates them is a single bad indent, which could be the
> error you're looking for, or what it that way in the begg!
>
>
> *So if you know of a plugin for a python editor, let me know. :)*
> Also, another idea is to edit the compiler somehow or create soem kind of
> process/script that all scripts with teh curly brackets will get removed
> before being processed... I'd settle for this solution as well if it
> exists...
>
> I"m sure I'm not the only one that has contemplated a curly bracket
> workaround for python before. :)
>
> _______________________________________________
> Tutor maillist - Tutor at python.org
> http://mail.python.org/mailman/listinfo/tutor
>
>
--
Cheers,
Vishwajeet
http://www.singhvishwajeet.com
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/tutor/attachments/20080813/25be1701/attachment-0001.htm>
More information about the Tutor
mailing list