[SR-11358] Segmentation Fault when compiling a property wrapper with a mutating get projectedValue #53759
Labels
bug
A deviation from expected or documented behavior. Also: expected but undesirable behavior.
compiler
The Swift compiler in itself
crash
Bug: A crash, i.e., an abnormal termination of software
property wrappers
Feature: property wrappers
Attachment: Download
Environment
Xcode 11 beta 6, on mac OS mojave 10.14.5
Additional Detail from JIRA
md5: b0ae3adefac5b0119769526719ea31a4
Issue Description:
When compiling a project that defines a property wrapper with a `projectedValue` property that happens to have a `mutating` getter, I hit a segmentation fault. changing the getter to not be `mutating` (and removing any code that made `mutating` a requirement) lets the compiler continue.
To reproduce, compile the SPM package attached to this issue, including the tests, (either in Xcode itself or with `swift build --build-tests`) and you'll see the attached segfault. If you change CopyOnWrite.swift by removing mutating and commenting the mutating-required code out, the compiler succeeds.
Edit: See the comment below, this is a smaller sample that exhibits the behavior:
The text was updated successfully, but these errors were encountered: