<html><head><meta http-equiv="Content-Type" content="text/html charset=us-ascii"></head><body style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space;">Oops. This is not quite right. I need to leave single character commands completely alone.<div>- Fariborz</div><div><br><div><div>On May 9, 2013, at 9:22 AM, Fariborz Jahanian <<a href="mailto:fjahanian@apple.com">fjahanian@apple.com</a>> wrote:</div><br class="Apple-interchange-newline"><blockquote type="cite"><div style="letter-spacing: normal; orphans: auto; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; widows: auto; word-spacing: 0px; -webkit-text-stroke-width: 0px;">Author: fjahanian<br>Date: Thu May 9 11:22:31 2013<br>New Revision: 181517<br><br>URL:<span class="Apple-converted-space"> </span><a href="http://llvm.org/viewvc/llvm-project?rev=181517&view=rev">http://llvm.org/viewvc/llvm-project?rev=181517&view=rev</a><br>Log:<br>[doc parsing]: don't attempt to fix single character<br>commands (\t \n are common). \\<span class="Apple-converted-space"> </span><a href="rdar://12381408">rdar://12381408</a><span class="Apple-converted-space"> </span><br><br>Modified:<br> cfe/trunk/lib/AST/CommentCommandTraits.cpp<br> cfe/trunk/test/Sema/warn-documentation-fixits.cpp<br><br>Modified: cfe/trunk/lib/AST/CommentCommandTraits.cpp<br>URL:<span class="Apple-converted-space"> </span><a href="http://llvm.org/viewvc/llvm-project/cfe/trunk/lib/AST/CommentCommandTraits.cpp?rev=181517&r1=181516&r2=181517&view=diff">http://llvm.org/viewvc/llvm-project/cfe/trunk/lib/AST/CommentCommandTraits.cpp?rev=181517&r1=181516&r2=181517&view=diff</a><br>==============================================================================<br>--- cfe/trunk/lib/AST/CommentCommandTraits.cpp (original)<br>+++ cfe/trunk/lib/AST/CommentCommandTraits.cpp Thu May 9 11:22:31 2013<br>@@ -49,6 +49,10 @@ HelperTypoCorrectCommandInfo(SmallVector<br> const unsigned MaxEditDistance = 1;<br> unsigned BestEditDistance = MaxEditDistance + 1;<br> StringRef Name = Command->Name;<br>+ // Don't attempt trying to typo fix single character commands.<br>+ // \t and \n are very common<br>+ if (Name.size() <= 1)<br>+ return;<br><br> unsigned MinPossibleEditDistance = abs((int)Name.size() - (int)Typo.size());<br> if (MinPossibleEditDistance > 0 &&<br><br>Modified: cfe/trunk/test/Sema/warn-documentation-fixits.cpp<br>URL:<span class="Apple-converted-space"> </span><a href="http://llvm.org/viewvc/llvm-project/cfe/trunk/test/Sema/warn-documentation-fixits.cpp?rev=181517&r1=181516&r2=181517&view=diff">http://llvm.org/viewvc/llvm-project/cfe/trunk/test/Sema/warn-documentation-fixits.cpp?rev=181517&r1=181516&r2=181517&view=diff</a><br>==============================================================================<br>--- cfe/trunk/test/Sema/warn-documentation-fixits.cpp (original)<br>+++ cfe/trunk/test/Sema/warn-documentation-fixits.cpp Thu May 9 11:22:31 2013<br>@@ -67,6 +67,9 @@ int FooBar();<br>/// \fooba bbb IS_DOXYGEN_END<br>int gorf();<br><br>+/// \t bbb IS_DOXYGEN_END<br>+int Bar();<br>+<br>// CHECK: fix-it:"{{.*}}":{5:12-5:22}:"a"<br>// CHECK: fix-it:"{{.*}}":{9:12-9:15}:"aaa"<br>// CHECK: fix-it:"{{.*}}":{13:13-13:23}:"T"<br><br><br>_______________________________________________<br>cfe-commits mailing list<br><a href="mailto:cfe-commits@cs.uiuc.edu">cfe-commits@cs.uiuc.edu</a><br><a href="http://lists.cs.uiuc.edu/mailman/listinfo/cfe-commits">http://lists.cs.uiuc.edu/mailman/listinfo/cfe-commits</a></div></blockquote></div><br></div></body></html>