[Issue 23805] Runtime segmentation fault when destructor access function frame
    d-bugmail at puremagic.com 
    d-bugmail at puremagic.com
       
    Tue Mar 28 12:15:56 UTC 2023
    
    
  
https://issues.dlang.org/show_bug.cgi?id=23805
RazvanN <razvan.nitu1305 at gmail.com> changed:
           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |razvan.nitu1305 at gmail.com
--- Comment #2 from RazvanN <razvan.nitu1305 at gmail.com> ---
Makes sense to me to have it error.
Another incosistency:
void fun(T)()
{
    T a;
}
If `fun` is instantiated with DontDestruct you end up with: "Error: cannot
access frame pointer of `test.main.CantDestruct`" at line "T a;". However, if
you replace it with `T a = T.init` it compiles. `T a` and `T a = T.init` are
exactly the same thing.
--
    
    
More information about the Digitalmars-d-bugs
mailing list