If you mean:
```D
auto ref T[] assumeSafeAppend(T)(auto ref T[] arr)
{
    _d_arrayshrinkfit(typeid(T[]), *(cast(void[]*)&arr)); 
    return arr;
}
```

Then it doesn't work. If arr is passed by value, the "return arr" will notice an lvalue, and try to return that by ref, resulting in an escaping local.

If you meant something else... well... did you have something in mind?