shared - i need it to be useful

Guillaume Piolat spam at smam.org
Wed Oct 17 14:44:19 UTC 2018


On Wednesday, 17 October 2018 at 07:20:20 UTC, Manu wrote:
> Shared is uninteresting and mostly useless as spec-ed, everyone 
> knows this.
> Interaction with shared via barely-controlled blunt casting in
> @trusted blocks is feeble and boring. It doesn't really give us
> anything in practice that we don't have in C++. It's an 
> uninspired
> design.

+1

I'm pretty sure it's great in theory, in practice it's another 
invasive type constructor, and not a particular well-understood 
or easy to deal with one.

The fact that this _type constructor_ finds its way into 
_identifiers_ create some concern: 
https://github.com/dlang/phobos/blob/656798f2b385437c239246b59e0433148190938c/std/experimental/allocator/package.d#L642


More information about the Digitalmars-d mailing list