You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
| Getter accessors | Yes, via `get<name>`. Boolean properties that start with `is` or `has` are remapped directly to a getter method using their original name. For structs only |
169
-
| Setter accessors | Yes, via `set<name>`. For structs only |
176
+
| Getter accessors | Yes, via `get<name>`. Boolean properties that start with `is` or `has` are remapped directly to a getter method using their original name. For structs and classes only |
177
+
| Setter accessors | Yes, via `set<name>`. For structs and classes only |
Swift classes that are marked as `final` are also marked `final` in C++.
667
+
Swift classes that are not marked as `final` should not be derived from in C++.
668
+
629
669
## Accessing Properties In C++
630
670
631
671
Swift allows structures and classes to define stored and computed properties. Stored properties store constant and variable values as part of an instance, whereas computed properties calculate (rather than store) a value. The stored and the computed properties from Swift types are bridged over as getter `get...` and setter `set...` methods in C++. Setter methods are not marked as `const` and should only be invoked on non `const` instances of the bridged types.
0 commit comments