:: Re: [DNG] Experiencing with GtkBuil…
Inizio della pagina
Delete this message
Reply to this message
Autore: Steve Litt
Data:  
To: dng
Oggetto: Re: [DNG] Experiencing with GtkBuilder
On Tue, 24 Nov 2015 06:02:42 +0100
Edward Bartolo <edbarx@???> wrote:

> Hi Aitor et al,
>
> What about directly translating the Object Pascal code into C instead
> of doing a reimplementation of the logic? I remember, once I had a
> Pascal class that took me six months to write which I translated into
> C++ within a month. I think, this is the most practical approach.
>
> There are also Pascal into C translators which I am thinking of trying
> although the translated code would still need inspection before
> deployment.
>
> Edward


Oh HELL no!

Pascal's a good language that compiles to highly efficient executables.
The point is that *Lazarus* is a drag and drop Rapid Application
Development (RAD) environment that happens to work with Pascal. But it's
optimized to be quick development, not create good Pascal algorithms.
The Pascal it creates is mostly scaffolding. So you'll be translating
incredibly de-optimized Pascal into C, and you'll end up with a huge
swarming mess of unreadable C. People will observer that it works, but
nobody will be able to modify it, because they won't be able to fathom
the fundamental design of the program from the code.

I don't see the problem with Lazarus. It's a drag and drop RAD suitable
for quick GUI development. A client to wpa_supplicant or however you're
doing this doesn't need to be lightning quick or close to the metal or
even particularly parsimonious with RAM, so what's the problem? And
once your program is done, and the user interface is perfect, THEN you
or others can use your program as a prototype and code other versions
of it.

Don't translate the Lazarus created Pascal to C. That would be a
horrible decision.

SteveT

Steve Litt 
November 2015 featured book: Troubleshooting Techniques
     of the Successful Technologist
http://www.troubleshooters.com/techniques