Last active
August 29, 2015 14:02
-
-
Save jspahrsummers/a0fb1abbb71f598d712f to your computer and use it in GitHub Desktop.
Workaround for “unimplemented IR generation feature non-fixed class layout”
This file contains 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
class ObjectWrapper<T> { | |
let backingVar: T[] | |
var value: T { | |
get { | |
return backingVar[0] | |
} | |
set(newValue) { | |
backingVar[0] = newValue | |
} | |
} | |
init(_ value: T) { | |
self.backingVar = [value] | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment