Skip to content

Commit b7c029c

Browse files
committed
[CHANGE] Swift: use NSNumber? so you can set attributes to nil.
1 parent 63d2ac2 commit b7c029c

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

templates/machine.swift.motemplate

+2-2
Original file line numberDiff line numberDiff line change
@@ -57,10 +57,10 @@ class _<$managedObjectClassName$>: <$customSuperentity$> {
5757
<$if Attribute.hasScalarAttributeType$>
5858
<$if Attribute.isReadonly$>
5959
@NSManaged
60-
let <$Attribute.name$>: <$Attribute.scalarAttributeType$>
60+
let <$Attribute.name$>: NSNumber?
6161
<$else$>
6262
@NSManaged
63-
var <$Attribute.name$>: <$Attribute.scalarAttributeType$>
63+
var <$Attribute.name$>: NSNumber?
6464
<$endif$>
6565
<$else$>
6666
<$if Attribute.isReadonly$>

0 commit comments

Comments
 (0)