On Thu, Jun 27, 2013 at 02:58:15PM +0200, Hans-Peter Diettrich wrote: > > Java and C# don't count, as safe languages, they have _ONLY_ managed types. > > Their choices will be hard to backport. > > Right. The idea sounds to me like the other half-baked attempts to > introduce anonymous methods, class helpers etc. into Pascal.
Class helpers are more a solution to a Delphi problem, namely its high binary dcu usage. Class helpers help to "add" methods, even when the mother unit is dcu only. People often confuse it with mixins and other complicated runtime object systems that it is not. > > As far as the C++ bit goes, that is all fairly new. Which part of the > > standard (and which standard) do you mean exactly, and which implementation? > > All local C++ objects are destroyed when they go out of scope. Yes, but if you only aim that high, just use an editor macro that autogenerates a create-try-finally-free sequence, or JCL safeguards. > >> The management overhead is as low as for managed strings. > > > > Where did you get that information? It is easy to see that it is somewhat > > doubtful as string has copy-on-write properties in addition to ref-counting. > > That's something different. While it's possible to copy strings > automatically, the same is impossible with more complex objects. True. But my point was that makes performance comparisons somewhat odd, since there are two properties that strings have that can't be emulated easily (no nesting and copy-on-write). So I really wondered where you got the numbers on, and I note you still haven't posted anything that made that claim believable. -- _______________________________________________ Lazarus mailing list [email protected] http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus
