How to use Objective-C classes with names which are keywords in Swift

不打扰是莪最后的温柔 提交于 2019-12-01 13:33:23

You have to use backticks:

fetchCondition.sqlite.`where` = @"name = 'sample1' and price > 50";

To use a reserved word as an identifier, put a backtick (`) before and after it. For example, class is not a valid identifier, but `class` is valid. The backticks are not considered part of the identifier; `x` and x have the same meaning.

The Swift Programming Language – Lexical Structure

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!