[Lazarus] I desperately need some ideas of reducing edit, compile, debug cycle

Frank Church vfclists at gmail.com
Sat Nov 27 12:01:50 CET 2010

On 26 November 2010 20:55, Martin <lazarus at mfriebe.de> wrote:

> On 26/11/2010 19:56, Frank Church wrote:
>> One thing that has always gottem to me when using Delphi and now Lazarus
>> is the tedious edit, compile, debug cycle. It has been growing worse of late
>> that now I am beginning to dread the whole process any time I have to make
>> some changes, especially when they are just minor GUI changes.
> ....
>> Quite simply I am thinking of a way to create the application in parts, so
>> that the parts containing the new functionality can be developed separately
>> as standalone programs, perhaps even console programs.
>> This raises the question of how procedure parameters and results can be
>> passed, and these are the options that have initially come to mind.
>> 1. Find a way to automatically translate simple variables, record
>> structures, or objects into text and pass them via the command line or
>> pipes. Perhaps JSON, XML or simple name-value pairs can be used here.
>> Designing the parameters as TPersistent objects that are streamed into text
>> form may be a better option here.
>> 2. Rather than using the command line, make them network services and pass
>> the parameters that way, or may make them RESTful/XML-RPC  with all the new
>> webby stuff( I am getting into some of that stuff now)
>> 3. Design them as DLLs initially - I suspect that will bring along a
>> different set of problems.
>> Once they are well tested I can incorporate them into the main
>> executables.
> Yes splitting your project into parts is a good idea. Quite simple use
> packages.
> Then you still have one application, you still can pass data around in the
> normal pascal way.
> Each package can be tested with a small simple runner application, or even
> better a fully automated testcase.
> Testcase are especially useful, if you can extract the functional layer
> from the visual layer.
> So instead of writing something big into TForm.SaveDocumentButtonClick, you
> just have "TheDocument.Save" in there
>  => all functionality goes into a none visual object TheDocument (or
> whatever it is in your case).
> - this object takes instruction, if the user clicks something
> - it can be asked what to display.
> - it can be given callbacks, if it requires to notify the visual layer.
>  for example it can have "OnTitleChange" => which is linked to a method
> changing the forms Caption (Title)
> ....
> Martin
> --

Thanks for the reply, Martin.

Are there some code examples which use this approach, especially the package
based one?

Will it also reduce the size of the debugging exe or speed up its creation?

Sometimes I see only one file compiled, then it goes to the linking phase,
but it doesn't seem to reduce the exe size or the speed of its creation.

> _______________________________________________
> Lazarus mailing list
> Lazarus at lists.lazarus.freepascal.org
> http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus

Frank Church

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.lazarus-ide.org/pipermail/lazarus/attachments/20101127/85133141/attachment-0003.html>

More information about the Lazarus mailing list