Xcode C++ and Objective-C refactoring
Is there a way to refactor mixed C++/Objective-C code in Xcode ?? I am writing a game using Cocos2D and Box2D, and the Box2D is written on C++, so every class I write should have .mm extension and therefore when I try to e.g. rename the variable, I got a message like "Xcode can only refactor C and Objective-C code".
答案
Xcode is VERY limited with refactoring, even with plain Obj-C. It's basically renaming and it can't even rename in comments. If it says it can't do something, then it probably can't. The only way to rename is using Of course, the problem is that find & replace doesn't know the programming language and sometimes can add some extra replace or forget to replace something, therefore be extra careful. Clean build is neccessary after every refactoring to check everything got renamed correctly. You can also use command line tools (e.g. |
|||||||||||||||||||||
|
最新文章
- nodejs创建http服务器
- 关于CAShapeLayer的一些实用案例和技巧【转】
- 关于Android真机调测Profiler
- failed jobs because of past close date,关工单报错
- R语言绘图高质量输出
- eclipse系列: Cannot change version of project facet Dynamic web的解决方法
- 升级OSX 10.9 Mavericks后,会导致Finder始终无响应的一个问题
- (转)js 中{},[]中括号,大括号使用详解
- Markdown常用编辑器
- 关于echarts、layer.js和jqGrid的知识点
- 源码中的哲学——通过构建者模式创建SparkSession
- [LeetCode] Next Greater Element I 下一个较大的元素之一
- jinji2
- Vuex笔记
- 配置Tree Shaking来减少JavaScript的打包体积
- ==、===和Object.is()的区别
- 25-Python3 错误和异常
- WEB应用从服务器主动推送Data到客户端有那些方式?
- aused by: org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'sessionFactory' defined in class path resource [applicationContext.xml]: Invocation of init method fai
- Django 2.0.1 官方文档翻译: 文档目录 (Page 1)