Preview features status?

Mathias LANG geod24 at
Wed Jul 14 08:00:12 UTC 2021

On Wednesday, 14 July 2021 at 07:26:27 UTC, Tejas wrote:
> Does your code "just work" if you use  ```preview=in``` 
> instead? Could be a good reason to just get rid of the 
> ```rvaluerefparam``` then.

Mostly. The main source of errors is that it will complain about 
`in` and `ref` being mixed together. The second is that, since it 
behaves as `scope`, if you escape parameter they might start to 
get diagnosed correctly.
Those are the two main reasons of failure I encountered while 
using it / adapting projects. I've never seen a place where 
parameter aliasing was causing issues.

Note that there are a few more things still missing for it to be 
complete: First, it needs to work with `foreach` (currently, 
`foreach` doesn't even support `scope`, so I'll do that too when 
I get to it), and the other is that it should probably error out 
with non-`extern(D|C++)` 

More information about the Digitalmars-d mailing list