I have a build error when trying to subclass a custom Objective-C class (a subclass of UIViewController) in Swift.
When I try to subclass in Swift, I get the build errors in the picture below. All of them relate to the use of the word class
as an argument in the OCMapper library (where I've opened an issue as well).
Some more notes:
- In the project, I both import and use Objective-C code in the Swift code and import and use Swift code in the Objective-C code.
- I import the compiled
Module-Swift.h
only in.m
and.mm
files and forward declare classes that I need in.h
files. - I've attempted to create a
Module-Swift-Fixed.h
class where I forward declare and/or import the custom Objective-C class headers (as recommended here), but that hasn't made a difference.
Has anyone seen anything like this before or have a solution?