POV-Ray : Newsgroups : povray.off-topic : Visual C# .net (and XNA) first impressions : Re: Visual C# .net (and XNA) first impressions Server Time
5 Sep 2024 07:24:57 EDT (-0400)
  Re: Visual C# .net (and XNA) first impressions  
From: Darren New
Date: 12 Oct 2009 12:15:20
Message: <4ad35618$1@news.povray.org>
Warp wrote:
>   I'm not completely convinced by having the need of a specialized source
> editor in order to understand the source code better. 

You are perfectly welcome to write a second bit of source code and maintain 
it in sync with the main file when using C# also. ;-)

> If you ever need to
> develop the source in some environment where you don't have that editor
> with those fancy features, you are going to find yourself wading through
> thousands and thousands of lines of code.

It's really not a problem. I actually find it easier to find things in C# 
than in C++, exactly because I know where to look. If I want to see how 
alpha::beta is implemented, I know where to find it and I know what search 
string to put in. In C++, I'm lucky if I can figure out what header file 
it's in, let alone where in the class heirarchies it is.

That's one thing I'm finding about trying to figure out this huge 
undocumented code base I'm working with - it's almost impossible to actually 
track down where the f'ing code *is*. There's way too many things like

typedef enum {
   ... 300 lines of enums ...
} TYaddaBlow;

OK, now go grep thru half a million lines of code looking for that 
declaration to figure out what the possible values for the enum are. Don't 
forget that the same name is defined in three different layers of the 
architecture, so even when you find it, you need to read the 2000-character 
gcc line to try to figure out which .h file containing the declaration gets 
included first, so you know which enum definition that particular source 
file is using.  </rant>

>   Things like code block collapsing and code coloring are definitely
> helpful, but IMO good-quality code shouldn't rely on those editing features
> in order to keep itself understandable and maintainable. You never know
> when you will have the need to understand the code in an environment
> which lacks those features.

Then you generate the header docs from the source code and you're good to 
go. There's no reason to make maintaining two files a manual process. On the 
other hand, if you *want* to do so, you certainly can.

-- 
   Darren New, San Diego CA, USA (PST)
   I ordered stamps from Zazzle that read "Place Stamp Here".


Post a reply to this message

Copyright 2003-2023 Persistence of Vision Raytracer Pty. Ltd.