Created
April 30, 2025 21:34
-
-
Save jacobsapps/787ad8e4726a0e4cf7376855cb046bb2 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
struct Container { | |
private var backingString: String = "Hello" | |
var value: String { | |
get { | |
backingString | |
} | |
_modify { | |
yield &backingString | |
} | |
} | |
} | |
var container = Container() | |
container.value.append(", world") |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment