[Geany-devel] Ideas on increasing quality of plugins

Frank Lanitz frank at xxxxx
Fri Mar 11 23:06:22 UTC 2011

On Thu, 10 Mar 2011 12:15:03 +1100
Lex Trotman <elextr at gmail.com> wrote:

> On 10 March 2011 11:57, Thomas Martitz
> <thomas.martitz at student.htw-berlin.de> wrote:
> > Returning an aggregate is exactly the same as manually allocating
> > the aggregate and passing a pointer to the function (in order to
> > let it fill the aggregate) on most if not all ABIs. Without any
> > difference in performance.
> Exactly, summarised beautifully.
> >
> > Of course the latter has the advantage that you can additionally
> > return a failure indicating value (-1 or NULL) so this is why you
> > generally don't see functions returning aggregates.
> Yes, its the habit created by the standard libraries, and they did it
> that way because C doesn't have an out-of-band signaling mechanism to
> handle errors.  So its all K&Rs fault... :-)

Its not a fault. Its planned to be like that as C was intended to bring
down easter block.... :)


-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 836 bytes
Desc: not available
URL: <http://lists.geany.org/pipermail/devel/attachments/20110312/68d7c48d/attachment.pgp>

More information about the Devel mailing list