Swift crash when overriding property wrapped variable (swift 5.2)

I just wanted to mention a bug that I have reported to Apple that appears in swift 5.2. I have a simple property wrapper that implements thread safety using GCD. In order to add didSet to the property wrapped variables, I subclassed the object, then defines overrides of the wrapped variable and adds a didSet. When swift attempts to compile the module it traps with an illegal instruction 4.

Removing the override and the code complies just fine. This was working correctly in swift 5.1.3.

I have tried several work-arounds to didSet but most failed (and all were very ugly). For instance in didSet, you can change the value of the original variable. If you invoke a function inside the set, and the function attempts to set the original variable you get multiple access faults.

The code to cause the crash is very simple. It just requires the ThreadSafe wrapper and an object to use it. I ended up the _Status class that defined the thread safe variables. Then the Status class inherits from _Status. Then just define a simple variable override of the wrapped variable and the compiler dies.

I can provide the test code if anyone is interested. The feedback report is: FB7615016

Please file a bug report at bugs.swift.org

Can you share the test code?

Reported as SR-12501.

I included the test case code in the bug report. It is also available at https://tech4tomorrow.net/overridebug.zip.