Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > Python > Re: Style question...

Reply
Thread Tools

Re: Style question...

 
 
rzed
Guest
Posts: n/a
 
      08-28-2003
Peter Hansen wrote:
> "U. N. Owen" wrote:
>>
>> For the moment I work on (a small part of) a project
>> that has hundreds of thousands of lines, almost
>> eveything in Python (and some in C and Fortran),
>> and when you have a loop several pages long, or
>> nested blocks to 8 levels or more, I may say
>> it's *very* convenient to see where the end
>> of a block exactly is. It's convenient to
>> have some long variable names too.

>
> I use Scite, which provides a graphical means of representation
> the indentation, with vertical lines that extend down at every
> indent level. (It would have to be later in the day for me to
> be coherent enough to describe it better.) Suffice to say that
> it provides more than adequate (for me) visual indication of the
> end of a block that stretches too far.
>
> A better point I'd make however is that if you have a loop several
> pages long, or a nested block 8 levels deep, the code needs
> refactoring! Saying this occurs in a large project does nothing
> to excuse it: the more code you have, the greater the need for
> structuring it well.
>


The only times I've seen the lack of a block delimiter as a problem is
when somebody plops some sample code in a usenet message and uses tabs
for indenting. OE strips out the leading tabs for some reason, so
everything winds up flush to the left margin. Once in awhile it is not
possible to recreate the proper indention, and for that reason I try
to include comment delimiters in code I send. When I don't forget, at
least. A better solution might be to physically restrain the posters
of tab-infested code from doing that, but there are only so many hours
in the day. And if OE wouldn't do what it does ... but then, where
would be the fund in that?

--
rzed


 
Reply With Quote
 
 
 
 
Alex Martelli
Guest
Posts: n/a
 
      08-29-2003
Steve Lamb wrote:

> On 2003-08-28, rzed <(E-Mail Removed)> wrote:
>> A better solution might be to physically restrain the posters of
>> tab-infested code from doing that, but there are only so many hours in
>> the day. And if OE wouldn't do what it does ... but then, where would
>> be the fund in that?

>
> Well, actually, a better solution would be to skip OE for something
> sensible, no?


OE is far from the only news user-agent that doesn't display tabs the
way you might like -- KDE's KNode has similar issues, for example.


Alex

 
Reply With Quote
 
 
 
 
rzed
Guest
Posts: n/a
 
      08-29-2003
Steve Lamb wrote:
> On 2003-08-28, rzed <(E-Mail Removed)> wrote:
>> A better solution might be to physically restrain the posters of
>> tab-infested code from doing that, but there are only so many
>> hours in the day. And if OE wouldn't do what it does ... but then,
>> where would be the fund in that?

>
> Well, actually, a better solution would be to skip OE for
> something sensible, no?


On my own hook, I'm doing that, but here in the office I don't have
the choice. I do have the choice to spell "fun" correctly, though I
see I opted not to.

--
rzed


 
Reply With Quote
 
 
 
Reply

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
DataGrid header style inconsistent with sortable column style cedoucette@alum.rpi.edu ASP .Net 0 10-14-2005 12:13 AM
All style tags after the first 30 style tags on an HTML page are not applied in Internet Explorer Rob Nicholson ASP .Net 3 05-28-2005 03:11 PM
Need help with Style conversion from Style object to Style key/value collection. Ken Varn ASP .Net Building Controls 0 04-26-2004 07:06 PM
Javascript Style Switcher that remebers current site style in use Hardeep Rakhra HTML 8 01-15-2004 08:00 PM
Style sheets, include one style within another (not inheritance) foldface@yahoo.co.uk HTML 1 11-24-2003 01:37 PM



Advertisments