Xcode 使用 FIXME、TODO、???,? [英] Xcode using FIXME, TODO, ???,?

查看:31
本文介绍了Xcode 使用 FIXME、TODO、???,?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我已经开始使用FIXMETODO???!!!标签XCode 但我发现当标签在函数中时它无法识别标签很痛苦.标签仅在给定函数之外被识别.

I have started to use the FIXME, TODO, ??? and !!! tags in XCode but have am finding it painful that it does not recognise the tags when they are within a function. The tags are only recognised outside a given function.

如何在函数中识别这些标签(因为这是错误所在)?

How can I get these tags recognised within a function (as this is where the bugs are)?

推荐答案

2016-02-02编辑

Xcode 现在支持//MARK:、//TODO: 和//FIXME: 地标来注释您的代码并在跳转栏中列出它们.

Xcode now supports //MARK:, //TODO: and //FIXME: landmarks to annotate your code and lists them in the jump bar.

要查找那些特殊标记(实际上是您指定的任何标记),您可以使用搜索导航器,输入以下字符串,然后选择在项目中,匹配正则表达式...",忽略大小写":

To find those special markups (and actually any markups you specify yourself), you can use the search navigator, enter the following string and then choose "In Project, matching regex "...", ignore case":

(//FIXME|//!!!|//???|//TODO)

这将在您的项目中搜索所有这些特殊标记.您甚至可以添加任何您想要的标记,例如//审查:请审查以下代码".这将是以下搜索字符串:

This will search your project for all those special markups. You can even add any markup you would like to, e.g. "//REVIEW: please review the following code". This would then be the following search string:

(//FIXME|//!!!|//???|//TODO|//REVIEW)

我在我的工作区中创建了一个选项卡,它始终打开搜索导航器,并填充此字符串.不幸的是,XCode 有时会从搜索框中删除此字符串,因此您必须在需要时将其复制和粘贴.

I created a tab in my workspace which has the search navigator always open, filled with this string. Unfortunately, XCode will sometimes remove this string from the searchbox, so you have to have it copy&paste ready whenever you need it.

这篇关于Xcode 使用 FIXME、TODO、???,?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆