On Tuesday, 30 June 2015 at 14:04:45 UTC, Etienne wrote:
On Tuesday, 30 June 2015 at 13:01:46 UTC, Steven Schveighoffer wrote:
[...]

I don't think there's a problem with destroy in the first place. The problem is that it's being advertised as calling the destructors:

http://dlang.org/library/object/type_info.destroy.html
http://dlang.org/library/object/destroy.html

The function would need a documentation section itself, since it's being advertised as a replacement for `delete` and expected to do the same wherever there's something to read about it.

We probably just need a new page in the `D Reference` about Lifetime. Documenting the general behavior and good practices of anything that manages lifetime, e.g. malloc, free, delete, destroy, new, pointers, classes, base types, etc.

Reply via email to