[Dlang-internal] DIP1000 discussion and testing: RC pointer snippet

meppl via Dlang-internal dlang-internal at puremagic.com
Fri Oct 21 08:36:08 PDT 2016


On Friday, 21 October 2016 at 12:04:33 UTC, Martin Nowak wrote:
> On Friday, 21 October 2016 at 01:46:20 UTC, meppl wrote:
>> void bar( jailed T* t) @safe {
>>    func(t); // ok, compiler added hidden_scope for void func( 
>> T* t) itself
>> }
>
> As said in DIP1000 and implemented in the PR, the compiler 
> infers scope for lambda and template function parameters. Not 
> sure what you're proposing.
> For sure we want to extend any attribute inferrence to 
> functions, but how to make that work with separate compilation 
> is still undecided. Talking more about inferrence would be an 
> OT discussion though.

I just assumed that inference for DIP1000 (for non-template 
private functions) is _possible_ to implement afterwards with 
backward compatibility. I want to know, if it is possible, 
because DIP1000 tells people to scatter another keyword („scope“) 
all over the place in the code.


More information about the Dlang-internal mailing list