<html><head></head><body style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space; ">FYI this is failing cfe/trunk/test/Index/complete-objc-message.m on my machine.<div><br></div><div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; font: normal normal normal 11px/normal Monaco; ">cd /Volumes/Data/Users/tcare/Projects/llvm-debug/tools/clang/test && /opt/local/bin/python2.6 /Volumes/Data/Users/tcare/Projects/llvm/utils/lit/lit.py --param clang_site_config=/Volumes/Data/Users/tcare/Projects/llvm-debug/tools/clang/test/lit.site.cfg --param build_config=. -sv /Volumes/Data/Users/tcare/Projects/llvm-debug/tools/clang/test</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; font: normal normal normal 11px/normal Monaco; ">-- Testing: 2499 tests, 4 threads --</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; font: normal normal normal 11px/normal Monaco; ">Testing: 0 .. 10.. 20.. 30.. 40.</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; font: normal normal normal 11px/normal Monaco; ">FAIL: Clang :: Index/complete-objc-message.m (1157 of 2499)</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; font: normal normal normal 11px/normal Monaco; ">******************** TEST 'Clang :: Index/complete-objc-message.m' FAILED ********************</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; font: normal normal normal 11px/normal Monaco; ">Script:</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; font: normal normal normal 11px/normal Monaco; ">--</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; font: normal normal normal 11px/normal Monaco; ">c-index-test -code-completion-at=/Volumes/Data/Users/tcare/Projects/llvm-bzr/tools/clang/test/Index/complete-objc-message.m:23:19 /Volumes/Data/Users/tcare/Projects/llvm-bzr/tools/clang/test/Index/complete-objc-message.m | FileCheck -check-prefix=CHECK-CC1 /Volumes/Data/Users/tcare/Projects/llvm-bzr/tools/clang/test/Index/complete-objc-message.m</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; font: normal normal normal 11px/normal Monaco; ">c-index-test -code-completion-at=/Volumes/Data/Users/tcare/Projects/llvm-bzr/tools/clang/test/Index/complete-objc-message.m:24:8 /Volumes/Data/Users/tcare/Projects/llvm-bzr/tools/clang/test/Index/complete-objc-message.m | FileCheck -check-prefix=CHECK-CC2 /Volumes/Data/Users/tcare/Projects/llvm-bzr/tools/clang/test/Index/complete-objc-message.m</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; font: normal normal normal 11px/normal Monaco; ">c-index-test -code-completion-at=/Volumes/Data/Users/tcare/Projects/llvm-bzr/tools/clang/test/Index/complete-objc-message.m:61:16 /Volumes/Data/Users/tcare/Projects/llvm-bzr/tools/clang/test/Index/complete-objc-message.m | FileCheck -check-prefix=CHECK-CC3 /Volumes/Data/Users/tcare/Projects/llvm-bzr/tools/clang/test/Index/complete-objc-message.m</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; font: normal normal normal 11px/normal Monaco; ">c-index-test -code-completion-at=/Volumes/Data/Users/tcare/Projects/llvm-bzr/tools/clang/test/Index/complete-objc-message.m:65:16 /Volumes/Data/Users/tcare/Projects/llvm-bzr/tools/clang/test/Index/complete-objc-message.m | FileCheck -check-prefix=CHECK-CC4 /Volumes/Data/Users/tcare/Projects/llvm-bzr/tools/clang/test/Index/complete-objc-message.m</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; font: normal normal normal 11px/normal Monaco; ">c-index-test -code-completion-at=/Volumes/Data/Users/tcare/Projects/llvm-bzr/tools/clang/test/Index/complete-objc-message.m:74:9 /Volumes/Data/Users/tcare/Projects/llvm-bzr/tools/clang/test/Index/complete-objc-message.m | FileCheck -check-prefix=CHECK-CC5 /Volumes/Data/Users/tcare/Projects/llvm-bzr/tools/clang/test/Index/complete-objc-message.m</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; font: normal normal normal 11px/normal Monaco; ">c-index-test -code-completion-at=/Volumes/Data/Users/tcare/Projects/llvm-bzr/tools/clang/test/Index/complete-objc-message.m:82:8 /Volumes/Data/Users/tcare/Projects/llvm-bzr/tools/clang/test/Index/complete-objc-message.m | FileCheck -check-prefix=CHECK-CC6 /Volumes/Data/Users/tcare/Projects/llvm-bzr/tools/clang/test/Index/complete-objc-message.m</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; font: normal normal normal 11px/normal Monaco; ">c-index-test -code-completion-at=/Volumes/Data/Users/tcare/Projects/llvm-bzr/tools/clang/test/Index/complete-objc-message.m:95:8 /Volumes/Data/Users/tcare/Projects/llvm-bzr/tools/clang/test/Index/complete-objc-message.m | FileCheck -check-prefix=CHECK-CC7 /Volumes/Data/Users/tcare/Projects/llvm-bzr/tools/clang/test/Index/complete-objc-message.m</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; font: normal normal normal 11px/normal Monaco; ">c-index-test -code-completion-at=/Volumes/Data/Users/tcare/Projects/llvm-bzr/tools/clang/test/Index/complete-objc-message.m:95:17 /Volumes/Data/Users/tcare/Projects/llvm-bzr/tools/clang/test/Index/complete-objc-message.m | FileCheck -check-prefix=CHECK-CC8 /Volumes/Data/Users/tcare/Projects/llvm-bzr/tools/clang/test/Index/complete-objc-message.m</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; font: normal normal normal 11px/normal Monaco; ">c-index-test -code-completion-at=/Volumes/Data/Users/tcare/Projects/llvm-bzr/tools/clang/test/Index/complete-objc-message.m:95:24 /Volumes/Data/Users/tcare/Projects/llvm-bzr/tools/clang/test/Index/complete-objc-message.m | FileCheck -check-prefix=CHECK-CC9 /Volumes/Data/Users/tcare/Projects/llvm-bzr/tools/clang/test/Index/complete-objc-message.m</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; font: normal normal normal 11px/normal Monaco; ">c-index-test -code-completion-at=/Volumes/Data/Users/tcare/Projects/llvm-bzr/tools/clang/test/Index/complete-objc-message.m:61:11 /Volumes/Data/Users/tcare/Projects/llvm-bzr/tools/clang/test/Index/complete-objc-message.m | FileCheck -check-prefix=CHECK-CCA /Volumes/Data/Users/tcare/Projects/llvm-bzr/tools/clang/test/Index/complete-objc-message.m</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; font: normal normal normal 11px/normal Monaco; ">c-index-test -code-completion-at=/Volumes/Data/Users/tcare/Projects/llvm-bzr/tools/clang/test/Index/complete-objc-message.m:103:6 /Volumes/Data/Users/tcare/Projects/llvm-bzr/tools/clang/test/Index/complete-objc-message.m | FileCheck -check-prefix=CHECK-CCB /Volumes/Data/Users/tcare/Projects/llvm-bzr/tools/clang/test/Index/complete-objc-message.m</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; font: normal normal normal 11px/normal Monaco; ">c-index-test -code-completion-at=/Volumes/Data/Users/tcare/Projects/llvm-bzr/tools/clang/test/Index/complete-objc-message.m:116:14 /Volumes/Data/Users/tcare/Projects/llvm-bzr/tools/clang/test/Index/complete-objc-message.m | FileCheck -check-prefix=CHECK-CCC /Volumes/Data/Users/tcare/Projects/llvm-bzr/tools/clang/test/Index/complete-objc-message.m</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; font: normal normal normal 11px/normal Monaco; ">c-index-test -code-completion-at=/Volumes/Data/Users/tcare/Projects/llvm-bzr/tools/clang/test/Index/complete-objc-message.m:116:23 /Volumes/Data/Users/tcare/Projects/llvm-bzr/tools/clang/test/Index/complete-objc-message.m | FileCheck -check-prefix=CHECK-CCD /Volumes/Data/Users/tcare/Projects/llvm-bzr/tools/clang/test/Index/complete-objc-message.m</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; font: normal normal normal 11px/normal Monaco; ">c-index-test -code-completion-at=/Volumes/Data/Users/tcare/Projects/llvm-bzr/tools/clang/test/Index/complete-objc-message.m:116:30 /Volumes/Data/Users/tcare/Projects/llvm-bzr/tools/clang/test/Index/complete-objc-message.m | FileCheck -check-prefix=CHECK-CCE /Volumes/Data/Users/tcare/Projects/llvm-bzr/tools/clang/test/Index/complete-objc-message.m</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; font: normal normal normal 11px/normal Monaco; ">c-index-test -code-completion-at=/Volumes/Data/Users/tcare/Projects/llvm-bzr/tools/clang/test/Index/complete-objc-message.m:61:11 /Volumes/Data/Users/tcare/Projects/llvm-bzr/tools/clang/test/Index/complete-objc-message.m | FileCheck -check-prefix=CHECK-CCF /Volumes/Data/Users/tcare/Projects/llvm-bzr/tools/clang/test/Index/complete-objc-message.m</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; font: normal normal normal 11px/normal Monaco; ">c-index-test -code-completion-at=/Volumes/Data/Users/tcare/Projects/llvm-bzr/tools/clang/test/Index/complete-objc-message.m:120:6 /Volumes/Data/Users/tcare/Projects/llvm-bzr/tools/clang/test/Index/complete-objc-message.m | FileCheck -check-prefix=CHECK-CCG /Volumes/Data/Users/tcare/Projects/llvm-bzr/tools/clang/test/Index/complete-objc-message.m</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; font: normal normal normal 11px/normal Monaco; ">c-index-test -code-completion-at=/Volumes/Data/Users/tcare/Projects/llvm-bzr/tools/clang/test/Index/complete-objc-message.m:121:14 /Volumes/Data/Users/tcare/Projects/llvm-bzr/tools/clang/test/Index/complete-objc-message.m | FileCheck -check-prefix=CHECK-CCG /Volumes/Data/Users/tcare/Projects/llvm-bzr/tools/clang/test/Index/complete-objc-message.m</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; font: normal normal normal 11px/normal Monaco; ">c-index-test -code-completion-at=/Volumes/Data/Users/tcare/Projects/llvm-bzr/tools/clang/test/Index/complete-objc-message.m:122:7 /Volumes/Data/Users/tcare/Projects/llvm-bzr/tools/clang/test/Index/complete-objc-message.m | FileCheck -check-prefix=CHECK-CCH /Volumes/Data/Users/tcare/Projects/llvm-bzr/tools/clang/test/Index/complete-objc-message.m</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; font: normal normal normal 11px/normal Monaco; ">c-index-test -code-completion-at=/Volumes/Data/Users/tcare/Projects/llvm-bzr/tools/clang/test/Index/complete-objc-message.m:134:6 /Volumes/Data/Users/tcare/Projects/llvm-bzr/tools/clang/test/Index/complete-objc-message.m | FileCheck -check-prefix=CHECK-CCI /Volumes/Data/Users/tcare/Projects/llvm-bzr/tools/clang/test/Index/complete-objc-message.m</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; font: normal normal normal 11px/normal Monaco; ">--</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; font: normal normal normal 11px/normal Monaco; ">Exit Code: 1</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; font: normal normal normal 11px/normal Monaco; ">Command Output (stderr):</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; font: normal normal normal 11px/normal Monaco; ">--</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; font: normal normal normal 11px/normal Monaco; ">/Volumes/Data/Users/tcare/Projects/llvm-bzr/tools/clang/test/Index/complete-objc-message.m:24:3:{24:3-24:11}: warning: method '-xx' not found (return type defaults to 'id')</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; font: normal normal normal 11px/normal Monaco; ">/Volumes/Data/Users/tcare/Projects/llvm-bzr/tools/clang/test/Index/complete-objc-message.m:24:3:{24:3-24:11}: warning: method '-xx' not found (return type defaults to 'id')</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; font: normal normal normal 11px/normal Monaco; ">/Volumes/Data/Users/tcare/Projects/llvm-bzr/tools/clang/test/Index/complete-objc-message.m:24:3:{24:3-24:11}: warning: method '-xx' not found (return type defaults to 'id')</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; font: normal normal normal 11px/normal Monaco; ">/Volumes/Data/Users/tcare/Projects/llvm-bzr/tools/clang/test/Index/complete-objc-message.m:55:1: warning: incomplete implementation</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; font: normal normal normal 11px/normal Monaco; ">/Volumes/Data/Users/tcare/Projects/llvm-bzr/tools/clang/test/Index/complete-objc-message.m:34:1: note: method definition for 'MySubInstMethod' not found</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; font: normal normal normal 11px/normal Monaco; ">/Volumes/Data/Users/tcare/Projects/llvm-bzr/tools/clang/test/Index/complete-objc-message.m:24:3:{24:3-24:11}: warning: method '-xx' not found (return type defaults to 'id')</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; font: normal normal normal 11px/normal Monaco; ">/Volumes/Data/Users/tcare/Projects/llvm-bzr/tools/clang/test/Index/complete-objc-message.m:55:1: warning: incomplete implementation</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; font: normal normal normal 11px/normal Monaco; ">/Volumes/Data/Users/tcare/Projects/llvm-bzr/tools/clang/test/Index/complete-objc-message.m:34:1: note: method definition for 'MySubInstMethod' not found</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; font: normal normal normal 11px/normal Monaco; ">/Volumes/Data/Users/tcare/Projects/llvm-bzr/tools/clang/test/Index/complete-objc-message.m:24:3:{24:3-24:11}: warning: method '-xx' not found (return type defaults to 'id')</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; font: normal normal normal 11px/normal Monaco; ">/Volumes/Data/Users/tcare/Projects/llvm-bzr/tools/clang/test/Index/complete-objc-message.m:55:1: warning: incomplete implementation</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; font: normal normal normal 11px/normal Monaco; ">/Volumes/Data/Users/tcare/Projects/llvm-bzr/tools/clang/test/Index/complete-objc-message.m:34:1: note: method definition for 'MySubInstMethod' not found</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; font: normal normal normal 11px/normal Monaco; ">/Volumes/Data/Users/tcare/Projects/llvm-bzr/tools/clang/test/Index/complete-objc-message.m:24:3:{24:3-24:11}: warning: method '-xx' not found (return type defaults to 'id')</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; font: normal normal normal 11px/normal Monaco; ">/Volumes/Data/Users/tcare/Projects/llvm-bzr/tools/clang/test/Index/complete-objc-message.m:55:1: warning: incomplete implementation</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; font: normal normal normal 11px/normal Monaco; ">/Volumes/Data/Users/tcare/Projects/llvm-bzr/tools/clang/test/Index/complete-objc-message.m:34:1: note: method definition for 'MySubInstMethod' not found</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; font: normal normal normal 11px/normal Monaco; ">/Volumes/Data/Users/tcare/Projects/llvm-bzr/tools/clang/test/Index/complete-objc-message.m:24:3:{24:3-24:11}: warning: method '-xx' not found (return type defaults to 'id')</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; font: normal normal normal 11px/normal Monaco; ">/Volumes/Data/Users/tcare/Projects/llvm-bzr/tools/clang/test/Index/complete-objc-message.m:55:1: warning: incomplete implementation</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; font: normal normal normal 11px/normal Monaco; ">/Volumes/Data/Users/tcare/Projects/llvm-bzr/tools/clang/test/Index/complete-objc-message.m:34:1: note: method definition for 'MySubInstMethod' not found</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; font: normal normal normal 11px/normal Monaco; ">/Volumes/Data/Users/tcare/Projects/llvm-bzr/tools/clang/test/Index/complete-objc-message.m:24:3:{24:3-24:11}: warning: method '-xx' not found (return type defaults to 'id')</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; font: normal normal normal 11px/normal Monaco; ">/Volumes/Data/Users/tcare/Projects/llvm-bzr/tools/clang/test/Index/complete-objc-message.m:24:3:{24:3-24:11}: warning: method '-xx' not found (return type defaults to 'id')</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; font: normal normal normal 11px/normal Monaco; ">/Volumes/Data/Users/tcare/Projects/llvm-bzr/tools/clang/test/Index/complete-objc-message.m:55:1: warning: incomplete implementation</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; font: normal normal normal 11px/normal Monaco; ">/Volumes/Data/Users/tcare/Projects/llvm-bzr/tools/clang/test/Index/complete-objc-message.m:34:1: note: method definition for 'MySubInstMethod' not found</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; font: normal normal normal 11px/normal Monaco; ">/Volumes/Data/Users/tcare/Projects/llvm-bzr/tools/clang/test/Index/complete-objc-message.m:24:3:{24:3-24:11}: warning: method '-xx' not found (return type defaults to 'id')</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; font: normal normal normal 11px/normal Monaco; ">/Volumes/Data/Users/tcare/Projects/llvm-bzr/tools/clang/test/Index/complete-objc-message.m:55:1: warning: incomplete implementation</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; font: normal normal normal 11px/normal Monaco; ">/Volumes/Data/Users/tcare/Projects/llvm-bzr/tools/clang/test/Index/complete-objc-message.m:34:1: note: method definition for 'MySubInstMethod' not found</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; font: normal normal normal 11px/normal Monaco; ">/Volumes/Data/Users/tcare/Projects/llvm-bzr/tools/clang/test/Index/complete-objc-message.m:24:3:{24:3-24:11}: warning: method '-xx' not found (return type defaults to 'id')</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; font: normal normal normal 11px/normal Monaco; ">/Volumes/Data/Users/tcare/Projects/llvm-bzr/tools/clang/test/Index/complete-objc-message.m:55:1: warning: incomplete implementation</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; font: normal normal normal 11px/normal Monaco; ">/Volumes/Data/Users/tcare/Projects/llvm-bzr/tools/clang/test/Index/complete-objc-message.m:34:1: note: method definition for 'MySubInstMethod' not found</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; font: normal normal normal 11px/normal Monaco; ">/Volumes/Data/Users/tcare/Projects/llvm-bzr/tools/clang/test/Index/complete-objc-message.m:24:3:{24:3-24:11}: warning: method '-xx' not found (return type defaults to 'id')</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; font: normal normal normal 11px/normal Monaco; ">/Volumes/Data/Users/tcare/Projects/llvm-bzr/tools/clang/test/Index/complete-objc-message.m:55:1: warning: incomplete implementation</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; font: normal normal normal 11px/normal Monaco; ">/Volumes/Data/Users/tcare/Projects/llvm-bzr/tools/clang/test/Index/complete-objc-message.m:34:1: note: method definition for 'MySubInstMethod' not found</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; font: normal normal normal 11px/normal Monaco; ">/Volumes/Data/Users/tcare/Projects/llvm-bzr/tools/clang/test/Index/complete-objc-message.m:24:3:{24:3-24:11}: warning: method '-xx' not found (return type defaults to 'id')</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; font: normal normal normal 11px/normal Monaco; ">/Volumes/Data/Users/tcare/Projects/llvm-bzr/tools/clang/test/Index/complete-objc-message.m:24:3:{24:3-24:11}: warning: method '-xx' not found (return type defaults to 'id')</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; font: normal normal normal 11px/normal Monaco; ">/Volumes/Data/Users/tcare/Projects/llvm-bzr/tools/clang/test/Index/complete-objc-message.m:55:1: warning: incomplete implementation</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; font: normal normal normal 11px/normal Monaco; ">/Volumes/Data/Users/tcare/Projects/llvm-bzr/tools/clang/test/Index/complete-objc-message.m:34:1: note: method definition for 'MySubInstMethod' not found</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; font: normal normal normal 11px/normal Monaco; ">/Volumes/Data/Users/tcare/Projects/llvm-bzr/tools/clang/test/Index/complete-objc-message.m:116:39: error: use of undeclared identifier 'ovl'</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; font: normal normal normal 11px/normal Monaco; ">/Volumes/Data/Users/tcare/Projects/llvm-bzr/tools/clang/test/Index/complete-objc-message.m:24:3:{24:3-24:11}: warning: method '-xx' not found (return type defaults to 'id')</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; font: normal normal normal 11px/normal Monaco; ">/Volumes/Data/Users/tcare/Projects/llvm-bzr/tools/clang/test/Index/complete-objc-message.m:55:1: warning: incomplete implementation</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; font: normal normal normal 11px/normal Monaco; ">/Volumes/Data/Users/tcare/Projects/llvm-bzr/tools/clang/test/Index/complete-objc-message.m:34:1: note: method definition for 'MySubInstMethod' not found</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; font: normal normal normal 11px/normal Monaco; ">/Volumes/Data/Users/tcare/Projects/llvm-bzr/tools/clang/test/Index/complete-objc-message.m:116:39: error: use of undeclared identifier 'ovl'</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; font: normal normal normal 11px/normal Monaco; ">/Volumes/Data/Users/tcare/Projects/llvm-bzr/tools/clang/test/Index/complete-objc-message.m:120:31: error: use of undeclared identifier 'ovl'</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; font: normal normal normal 11px/normal Monaco; ">/Volumes/Data/Users/tcare/Projects/llvm-bzr/tools/clang/test/Index/complete-objc-message.m:24:3:{24:3-24:11}: warning: method '-xx' not found (return type defaults to 'id')</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; font: normal normal normal 11px/normal Monaco; ">/Volumes/Data/Users/tcare/Projects/llvm-bzr/tools/clang/test/Index/complete-objc-message.m:55:1: warning: incomplete implementation</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; font: normal normal normal 11px/normal Monaco; ">/Volumes/Data/Users/tcare/Projects/llvm-bzr/tools/clang/test/Index/complete-objc-message.m:34:1: note: method definition for 'MySubInstMethod' not found</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; font: normal normal normal 11px/normal Monaco; ">/Volumes/Data/Users/tcare/Projects/llvm-bzr/tools/clang/test/Index/complete-objc-message.m:116:39: error: use of undeclared identifier 'ovl'</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; font: normal normal normal 11px/normal Monaco; ">/Volumes/Data/Users/tcare/Projects/llvm-bzr/tools/clang/test/Index/complete-objc-message.m:120:31: error: use of undeclared identifier 'ovl'</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; font: normal normal normal 11px/normal Monaco; ">/Volumes/Data/Users/tcare/Projects/llvm-bzr/tools/clang/test/Index/complete-objc-message.m:121:4:{121:4-121:13}: warning: method '-blarg' not found (return type defaults to 'id')</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; font: normal normal normal 11px/normal Monaco; ">/Volumes/Data/Users/tcare/Projects/llvm-bzr/tools/clang/test/Index/complete-objc-message.m:121:39: error: use of undeclared identifier 'ovl'</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; font: normal normal normal 11px/normal Monaco; ">/Volumes/Data/Users/tcare/Projects/llvm-bzr/tools/clang/test/Index/complete-objc-message.m:237:15: error: expected string not found in input</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; font: normal normal normal 11px/normal Monaco; ">// CHECK-CCH: ObjCClassMethodDecl:{ResultType int}{TypedText Method:}{Placeholder (float)f}{HorizontalSpace }{Text Arg1:}{Placeholder (int)i1}{HorizontalSpace }{Text OtherArg:}{Placeholder (id)obj}</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; font: normal normal normal 11px/normal Monaco; ">              ^</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; font: normal normal normal 11px/normal Monaco; "><stdin>:7:181: note: scanning from here</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; font: normal normal normal 11px/normal Monaco; ">ObjCClassMethodDecl:{ResultType int}{TypedText Method:}{Placeholder (float)f}{HorizontalSpace }{Text Arg1:}{Placeholder (int)i1}{HorizontalSpace }{Text Arg2:}{Placeholder (int)i2} (20)</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; font: normal normal normal 11px/normal Monaco; ">                                                                                                                                                                                    ^</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; font: normal normal normal 11px/normal Monaco; "><stdin>:8:1: note: possible intended match here</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; font: normal normal normal 11px/normal Monaco; ">ObjCClassMethodDecl:{ResultType int}{TypedText Method:}{Placeholder (float)f}{HorizontalSpace }{Text SomeArg:}{Placeholder (int)i1}{HorizontalSpace }{Text OtherArg:}{Placeholder (id)obj} (20)</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; font: normal normal normal 11px/normal Monaco; ">^</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; font: normal normal normal 11px/normal Monaco; ">--</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; font: normal normal normal 11px/normal Monaco; min-height: 15px; "><br></div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; font: normal normal normal 11px/normal Monaco; ">********************</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; font: normal normal normal 11px/normal Monaco; ">Testing: 0 .. 10.. 20.. 30.. 40.. 50.. 60.. 70.. 80.. 90.. </div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; font: normal normal normal 11px/normal Monaco; ">Testing Time: 81.47s</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; font: normal normal normal 11px/normal Monaco; ">********************</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; font: normal normal normal 11px/normal Monaco; ">Failing Tests (1):</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; font: normal normal normal 11px/normal Monaco; ">    Clang :: Index/complete-objc-message.m</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; font: normal normal normal 11px/normal Monaco; min-height: 15px; "><br></div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; font: normal normal normal 11px/normal Monaco; ">  Expected Passes    : 2479</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; font: normal normal normal 11px/normal Monaco; ">  Expected Failures  : 19</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; font: normal normal normal 11px/normal Monaco; ">  Unexpected Failures: 1</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; font: normal normal normal 11px/normal Monaco; "><br></div><div><div>On Aug 25, 2010, at 3:15 PM, Douglas Gregor wrote:</div><br class="Apple-interchange-newline"><blockquote type="cite"><div>Author: dgregor<br>Date: Wed Aug 25 17:15:42 2010<br>New Revision: 112095<br><br>URL: <a href="http://llvm.org/viewvc/llvm-project?rev=112095&view=rev">http://llvm.org/viewvc/llvm-project?rev=112095&view=rev</a><br>Log:<br>Move the sorting of code-completion results out of the main path and<br>into the clients, e.g., the printing code-completion consumer and<br>c-index-test. Clients may want to re-sort the results anyway.<br><br>Modified:<br>    cfe/trunk/lib/Frontend/ASTUnit.cpp<br>    cfe/trunk/lib/Sema/CodeCompleteConsumer.cpp<br>    cfe/trunk/lib/Sema/SemaCodeComplete.cpp<br>    cfe/trunk/test/Index/code-completion.cpp<br>    cfe/trunk/test/Index/complete-method-decls.m<br>    cfe/trunk/test/Index/complete-objc-message.m<br>    cfe/trunk/tools/c-index-test/c-index-test.c<br>    cfe/trunk/tools/libclang/CIndexCodeCompletion.cpp<br><br>Modified: cfe/trunk/lib/Frontend/ASTUnit.cpp<br>URL: <a href="http://llvm.org/viewvc/llvm-project/cfe/trunk/lib/Frontend/ASTUnit.cpp?rev=112095&r1=112094&r2=112095&view=diff">http://llvm.org/viewvc/llvm-project/cfe/trunk/lib/Frontend/ASTUnit.cpp?rev=112095&r1=112094&r2=112095&view=diff</a><br>==============================================================================<br>--- cfe/trunk/lib/Frontend/ASTUnit.cpp (original)<br>+++ cfe/trunk/lib/Frontend/ASTUnit.cpp Wed Aug 25 17:15:42 2010<br>@@ -1678,9 +1678,7 @@<br>     Next.ProcessCodeCompleteResults(S, Context, Results, NumResults);<br>     return;<br>   }<br>-<br>-  // Sort the completion results before passing them on to the actual consumer.<br>-  std::stable_sort(AllResults.begin(), AllResults.end());<br>+  <br>   Next.ProcessCodeCompleteResults(S, Context, AllResults.data(),<br>                                   AllResults.size());<br><br><br>Modified: cfe/trunk/lib/Sema/CodeCompleteConsumer.cpp<br>URL: <a href="http://llvm.org/viewvc/llvm-project/cfe/trunk/lib/Sema/CodeCompleteConsumer.cpp?rev=112095&r1=112094&r2=112095&view=diff">http://llvm.org/viewvc/llvm-project/cfe/trunk/lib/Sema/CodeCompleteConsumer.cpp?rev=112095&r1=112094&r2=112095&view=diff</a><br>==============================================================================<br>--- cfe/trunk/lib/Sema/CodeCompleteConsumer.cpp (original)<br>+++ cfe/trunk/lib/Sema/CodeCompleteConsumer.cpp Wed Aug 25 17:15:42 2010<br>@@ -443,6 +443,8 @@<br>                                                  CodeCompletionContext Context,<br>                                                  CodeCompletionResult *Results,<br>                                                          unsigned NumResults) {<br>+  std::stable_sort(Results, Results + NumResults);<br>+  <br>   // Print the results.<br>   for (unsigned I = 0; I != NumResults; ++I) {<br>     OS << "COMPLETION: ";<br>@@ -660,6 +662,11 @@<br>   if (cmp)<br>     return cmp < 0;<br><br>+  // If case-insensitive comparison fails, try case-sensitive comparison.<br>+  cmp = XStr.compare(YStr);<br>+  if (cmp)<br>+    return cmp < 0;<br>+<br>   // Non-hidden names precede hidden names.<br>   if (X.Hidden != Y.Hidden)<br>     return !X.Hidden;<br>@@ -695,7 +702,7 @@<br>                                                        unsigned NumCandidates) {<br>   for (unsigned I = 0; I != NumCandidates; ++I) {<br>     WriteUnsigned(OS, CXCursor_NotImplemented);<br>-    WriteUnsigned(OS, /*Priority=*/0);<br>+    WriteUnsigned(OS, /*Priority=*/I);<br>     WriteUnsigned(OS, /*Availability=*/CXAvailability_Available);<br>     CodeCompletionString *CCS<br>       = Candidates[I].CreateSignatureString(CurrentArg, SemaRef);<br><br>Modified: cfe/trunk/lib/Sema/SemaCodeComplete.cpp<br>URL: <a href="http://llvm.org/viewvc/llvm-project/cfe/trunk/lib/Sema/SemaCodeComplete.cpp?rev=112095&r1=112094&r2=112095&view=diff">http://llvm.org/viewvc/llvm-project/cfe/trunk/lib/Sema/SemaCodeComplete.cpp?rev=112095&r1=112094&r2=112095&view=diff</a><br>==============================================================================<br>--- cfe/trunk/lib/Sema/SemaCodeComplete.cpp (original)<br>+++ cfe/trunk/lib/Sema/SemaCodeComplete.cpp Wed Aug 25 17:15:42 2010<br>@@ -2277,8 +2277,6 @@<br>                                       CodeCompletionContext Context,<br>                                       CodeCompletionResult *Results,<br>                                       unsigned NumResults) {<br>-  std::stable_sort(Results, Results + NumResults);<br>-<br>   if (CodeCompleter)<br>     CodeCompleter->ProcessCodeCompleteResults(*S, Context, Results, NumResults);<br><br><br>Modified: cfe/trunk/test/Index/code-completion.cpp<br>URL: <a href="http://llvm.org/viewvc/llvm-project/cfe/trunk/test/Index/code-completion.cpp?rev=112095&r1=112094&r2=112095&view=diff">http://llvm.org/viewvc/llvm-project/cfe/trunk/test/Index/code-completion.cpp?rev=112095&r1=112094&r2=112095&view=diff</a><br>==============================================================================<br>--- cfe/trunk/test/Index/code-completion.cpp (original)<br>+++ cfe/trunk/test/Index/code-completion.cpp Wed Aug 25 17:15:42 2010<br>@@ -60,8 +60,8 @@<br> // RUN: c-index-test -code-completion-at=%s:37:10 %s | FileCheck -check-prefix=CHECK-EXPR %s<br> // CHECK-EXPR: NotImplemented:{TypedText int} (65)<br> // CHECK-EXPR: NotImplemented:{TypedText long} (65)<br>-// CHECK-EXPR: FieldDecl:{ResultType double}{TypedText member} (10)<br> // CHECK-EXPR: FieldDecl:{ResultType int}{Text X::}{TypedText member} (5)<br>+// CHECK-EXPR: FieldDecl:{ResultType double}{TypedText member} (10)<br> // CHECK-EXPR: FieldDecl:{ResultType float}{Text Y::}{TypedText member} (11)<br> // CHECK-EXPR: FunctionDecl:{ResultType void}{TypedText memfunc}{LeftParen (}{Optional {Placeholder int i}}{RightParen )} (22)<br> // CHECK-EXPR: NotImplemented:{TypedText N}{Text ::} (75)<br><br>Modified: cfe/trunk/test/Index/complete-method-decls.m<br>URL: <a href="http://llvm.org/viewvc/llvm-project/cfe/trunk/test/Index/complete-method-decls.m?rev=112095&r1=112094&r2=112095&view=diff">http://llvm.org/viewvc/llvm-project/cfe/trunk/test/Index/complete-method-decls.m?rev=112095&r1=112094&r2=112095&view=diff</a><br>==============================================================================<br>--- cfe/trunk/test/Index/complete-method-decls.m (original)<br>+++ cfe/trunk/test/Index/complete-method-decls.m Wed Aug 25 17:15:42 2010<br>@@ -113,13 +113,13 @@<br> // CHECK-CCC: ObjCInstanceMethodDecl:{TypedText first}{Colon :}{LeftParen (}{Text int}{RightParen )}{Text x}{HorizontalSpace  }{Text second2}{Colon :}{LeftParen (}{Text float}{RightParen )}{Text y}{HorizontalSpace  }{Text third}{Colon :}{LeftParen (}{Text double}{RightParen )}{Text z} (30)<br> // RUN: c-index-test -code-completion-at=%s:56:21 %s | FileCheck -check-prefix=CHECK-CCD %s<br> // FIXME: These results could be more precise.<br>-// CHECK-CCD: ObjCInstanceMethodDecl:{ResultType id}{Informative first:}{TypedText second2:}{Text (float)y2}{HorizontalSpace  }{Text third:}{Text (double)z} (20)<br> // CHECK-CCD: ObjCInstanceMethodDecl:{ResultType int}{Informative first:}{TypedText second2:}{Text (float)y}{HorizontalSpace  }{Text third:}{Text (double)z} (5)<br>+// CHECK-CCD: ObjCInstanceMethodDecl:{ResultType id}{Informative first:}{TypedText second2:}{Text (float)y2}{HorizontalSpace  }{Text third:}{Text (double)z} (20)<br> // CHECK-CCD: ObjCInstanceMethodDecl:{ResultType void *}{Informative first:}{TypedText second3:}{Text (float)y3}{HorizontalSpace  }{Text third:}{Text (double)z} (20)<br> // CHECK-CCD: ObjCInstanceMethodDecl:{ResultType int}{Informative first:}{TypedText second:}{Text (float)y}{HorizontalSpace  }{Text third:}{Text (double)z} (5)<br> // RUN: c-index-test -code-completion-at=%s:56:38 %s | FileCheck -check-prefix=CHECK-CCE %s<br>-// CHECK-CCE: ObjCInstanceMethodDecl:{ResultType id}{Informative first:}{Informative second2:}{TypedText third:}{Text (double)z} (20)<br> // CHECK-CCE: ObjCInstanceMethodDecl:{ResultType int}{Informative first:}{Informative second2:}{TypedText third:}{Text (double)z} (5)<br>+// CHECK-CCE: ObjCInstanceMethodDecl:{ResultType id}{Informative first:}{Informative second2:}{TypedText third:}{Text (double)z} (20)<br> // RUN: c-index-test -code-completion-at=%s:60:4 %s | FileCheck -check-prefix=CHECK-CCF %s<br> // CHECK-CCF: ObjCInterfaceDecl:{TypedText A} (65)<br> // CHECK-CCF: ObjCInterfaceDecl:{TypedText B} (65)<br><br>Modified: cfe/trunk/test/Index/complete-objc-message.m<br>URL: <a href="http://llvm.org/viewvc/llvm-project/cfe/trunk/test/Index/complete-objc-message.m?rev=112095&r1=112094&r2=112095&view=diff">http://llvm.org/viewvc/llvm-project/cfe/trunk/test/Index/complete-objc-message.m?rev=112095&r1=112094&r2=112095&view=diff</a><br>==============================================================================<br>--- cfe/trunk/test/Index/complete-objc-message.m (original)<br>+++ cfe/trunk/test/Index/complete-objc-message.m Wed Aug 25 17:15:42 2010<br>@@ -209,20 +209,23 @@<br> // CHECK-CCF: {ResultType Class}{TypedText self}<br> // CHECK-CCF: {TypedText super}<br> // RUN: c-index-test -code-completion-at=%s:120:6 %s | FileCheck -check-prefix=CHECK-CCG %s<br>-// CHECK-CCG: ObjCInstanceMethodDecl:{ResultType id}{TypedText categoryInstanceMethod}<br>-// CHECK-CCG: ObjCInstanceMethodDecl:{ResultType id}{TypedText instanceMethod1}<br>-// CHECK-CCG: ObjCInstanceMethodDecl:{ResultType int}{TypedText Method}<br>-// CHECK-CCG: ObjCInstanceMethodDecl:{ResultType int}{TypedText Method:}{Placeholder (int)i}<br>-// CHECK-CCG: ObjCInstanceMethodDecl:{ResultType int}{TypedText Method:}{Placeholder (float)f}{HorizontalSpace  }{Text Arg1:}{Placeholder (int)i1}{HorizontalSpace  }{Text Arg2:}{Placeholder (int)i2}<br>-// CHECK-CCG: ObjCInstanceMethodDecl:{ResultType int}{TypedText Method:}{Placeholder (float)f}{HorizontalSpace  }{Text Arg1:}{Placeholder (int)i1}{HorizontalSpace  }{Text OtherArg:}{Placeholder (id)obj}<br>-// CHECK-CCG: ObjCInstanceMethodDecl:{ResultType int}{TypedText Method:}{Placeholder (float)f}{HorizontalSpace  }{Text SomeArg:}{Placeholder (int)i1}{HorizontalSpace  }{Text OtherArg:}{Placeholder (id)obj}<br>-// CHECK-CCG: ObjCInstanceMethodDecl:{ResultType int}{TypedText MyInstMethod:}{Placeholder (id)x}{HorizontalSpace  }{Text second:}{Placeholder (id)y}<br>-// CHECK-CCG: ObjCInstanceMethodDecl:{ResultType int}{TypedText MyPrivateInstMethod}<br>-// CHECK-CCG: ObjCInstanceMethodDecl:{ResultType int}{TypedText MySubInstMethod}<br>-// CHECK-CCG: ObjCInstanceMethodDecl:{ResultType int}{TypedText MySubInstMethod:}{Placeholder (id)obj}<br>-// CHECK-CCG: ObjCInstanceMethodDecl:{ResultType int}{TypedText OtherMethod:}{Placeholder (float)f}{HorizontalSpace  }{Text Arg1:}{Placeholder (int)i1}{HorizontalSpace  }{Text Arg2:}{Placeholder (int)i2}<br>-// CHECK-CCG: ObjCInstanceMethodDecl:{ResultType id}{TypedText protocolInstanceMethod:}{Placeholder (int)value}<br>-// CHECK-CCG: ObjCInstanceMethodDecl:{ResultType int}{TypedText secondProtocolInstanceMethod}<br>+// CHECK-CCG: ObjCInstanceMethodDecl:{ResultType id}{TypedText categoryInstanceMethod} (20)<br>+// CHECK-CCG: ObjCInstanceMethodDecl:{ResultType id}{TypedText instanceMethod1} (20)<br>+// CHECK-CCG: ObjCInstanceMethodDecl:{ResultType int}{TypedText Method} (20)<br>+// CHECK-CCG: ObjCInstanceMethodDecl:{ResultType int}{TypedText Method:}{Placeholder (int)i} (20)<br>+// CHECK-CCG: ObjCInstanceMethodDecl:{ResultType int}{TypedText Method:}{Placeholder (float)f}{HorizontalSpace  }{Text Arg1:}{Placeholder (int)i1}{HorizontalSpace  }{Text Arg2:}{Placeholder (int)i2} (20)<br>+// CHECK-CCG: ObjCInstanceMethodDecl:{ResultType int}{TypedText Method:}{Placeholder (float)f}{HorizontalSpace  }{Text Arg1:}{Placeholder (int)i1}{HorizontalSpace  }{Text OtherArg:}{Placeholder (id)obj} (20)<br>+// CHECK-CCG: ObjCInstanceMethodDecl:{ResultType int}{TypedText Method:}{Placeholder (float)f}{HorizontalSpace  }{Text SomeArg:}{Placeholder (int)i1}{HorizontalSpace  }{Text OtherArg:}{Placeholder (id)obj} (20)<br>+// CHECK-CCG: ObjCInstanceMethodDecl:{ResultType int}{TypedText MyInstMethod:}{Placeholder (id)x}{HorizontalSpace  }{Text second:}{Placeholder (id)y} (20)<br>+// CHECK-CCG: ObjCInstanceMethodDecl:{ResultType int}{TypedText MyPrivateInstMethod} (20)<br>+// CHECK-CCG: ObjCInstanceMethodDecl:{ResultType int}{TypedText MySubInstMethod} (20)<br>+// CHECK-CCG: ObjCInstanceMethodDecl:{ResultType int}{TypedText MySubInstMethod:}{Placeholder (id)obj} (20)<br>+// CHECK-CCG: ObjCInstanceMethodDecl:{ResultType int}{TypedText OtherMethod:}{Placeholder (float)f}{HorizontalSpace  }{Text Arg1:}{Placeholder (int)i1}{HorizontalSpace  }{Text Arg2:}{Placeholder (int)i2} (20)<br>+// CHECK-CCG: ObjCInstanceMethodDecl:{ResultType id}{TypedText protocolInstanceMethod:}{Placeholder (int)value} (20)<br>+// CHECK-CCG: ObjCInstanceMethodDecl:{ResultType int}{TypedText secondProtocolInstanceMethod} (20)<br>+// CHECK-CCG: ObjCInstanceMethodDecl:{ResultType int}{TypedText SentinelMethod:}{Placeholder (int)i}{Placeholder , ...}{Text , nil} (20)<br>+<br>+                    <br> // RUN: c-index-test -code-completion-at=%s:121:14 %s | FileCheck -check-prefix=CHECK-CCG %s<br> // RUN: c-index-test -code-completion-at=%s:122:7 %s | FileCheck -check-prefix=CHECK-CCH %s<br> // CHECK-CCH: ObjCClassMethodDecl:{ResultType id}{TypedText categoryClassMethod}<br><br>Modified: cfe/trunk/tools/c-index-test/c-index-test.c<br>URL: <a href="http://llvm.org/viewvc/llvm-project/cfe/trunk/tools/c-index-test/c-index-test.c?rev=112095&r1=112094&r2=112095&view=diff">http://llvm.org/viewvc/llvm-project/cfe/trunk/tools/c-index-test/c-index-test.c?rev=112095&r1=112094&r2=112095&view=diff</a><br>==============================================================================<br>--- cfe/trunk/tools/c-index-test/c-index-test.c (original)<br>+++ cfe/trunk/tools/c-index-test/c-index-test.c Wed Aug 25 17:15:42 2010<br>@@ -1,6 +1,7 @@<br> /* c-index-test.c */<br><br> #include "clang-c/Index.h"<br>+#include <ctype.h><br> #include <stdlib.h><br> #include <stdio.h><br> #include <string.h><br>@@ -895,6 +896,84 @@<br>   fprintf(file, "\n");<br> }<br><br>+int my_stricmp(const char *s1, const char *s2) {<br>+  while (*s1 && *s2) {<br>+    int c1 = tolower(*s1), c2 = tolower(*s2);<br>+    if (c1 < c2)<br>+      return -1;<br>+    else if (c1 > c2)<br>+      return 1;<br>+    <br>+    ++s1;<br>+    ++s2;<br>+  }<br>+  <br>+  if (*s1)<br>+    return 1;<br>+  else if (*s2)<br>+    return -1;<br>+  return 0;<br>+}<br>+<br>+int compare_completion_string(const void *xv, const void *yv) {<br>+  CXCompletionString x = ((CXCompletionResult *)xv)->CompletionString;<br>+  CXCompletionString y = ((CXCompletionResult *)yv)->CompletionString;<br>+  CXString xText, yText;<br>+  int I, N;<br>+  int result;<br>+  int FoundXText = 0, FoundYText = 0;<br>+  <br>+  /* Find the typed text in x. */<br>+  for (I = 0, N = clang_getNumCompletionChunks(x); I != N; ++I) {<br>+    if (clang_getCompletionChunkKind(x, I) == CXCompletionChunk_TypedText) {<br>+      xText = clang_getCompletionChunkText(x, I);<br>+      FoundXText = 1;<br>+      break;<br>+    }<br>+  }<br>+  <br>+  /* Find the typed text in x. */<br>+  for (I = 0, N = clang_getNumCompletionChunks(y); I != N; ++I) {<br>+    if (clang_getCompletionChunkKind(y, I) == CXCompletionChunk_TypedText) {<br>+      yText = clang_getCompletionChunkText(y, I);<br>+      FoundYText = 1;<br>+      break;<br>+    }<br>+  }<br>+  <br>+  if (!FoundXText || !FoundYText) {<br>+    /* At least one of the results is missing a TypedText chunk. */<br>+    if (FoundXText)<br>+      clang_disposeString(xText);<br>+    if (FoundYText)<br>+      clang_disposeString(xText);<br>+    <br>+    if (FoundXText || FoundYText)<br>+      return FoundXText? -1 : 1;<br>+  } else {<br>+    /* First, try case-insensitive comparisons. */<br>+    result = my_stricmp(clang_getCString(xText), clang_getCString(yText));<br>+<br>+    /* If that fails, try case-sensitive comparison. */<br>+    if (!result)<br>+      result = strcmp(clang_getCString(xText), clang_getCString(yText));<br>+    <br>+    clang_disposeString(xText);<br>+    clang_disposeString(yText);<br>+    if (result)<br>+      return result;<br>+  }<br>+  <br>+  /* The completion strings appear to be the same; try to order based on<br>+     priority. */<br>+  if (clang_getCompletionPriority(x) < clang_getCompletionPriority(y))<br>+    return -1;<br>+  else if (clang_getCompletionPriority(x) > clang_getCompletionPriority(y))<br>+    return 1;<br>+  <br>+  return 0;<br>+}<br>+<br> int perform_code_completion(int argc, const char **argv, int timing_only) {<br>   const char *input = argv[1];<br>   char *filename = 0;<br>@@ -950,9 +1029,14 @@<br><br>   if (results) {<br>     unsigned i, n = results->NumResults;<br>-    if (!timing_only)<br>+    if (!timing_only) {      <br>+      /* Sort the code-completion results based on the typed text. */<br>+      mergesort(results->Results, results->NumResults, <br>+                sizeof(CXCompletionResult), &compare_completion_string);<br>+<br>       for (i = 0; i != n; ++i)<br>         print_completion_result(results->Results + i, stdout);<br>+    }<br>     n = clang_codeCompleteGetNumDiagnostics(results);<br>     for (i = 0; i != n; ++i) {<br>       CXDiagnostic diag = clang_codeCompleteGetDiagnostic(results, i);<br><br>Modified: cfe/trunk/tools/libclang/CIndexCodeCompletion.cpp<br>URL: <a href="http://llvm.org/viewvc/llvm-project/cfe/trunk/tools/libclang/CIndexCodeCompletion.cpp?rev=112095&r1=112094&r2=112095&view=diff">http://llvm.org/viewvc/llvm-project/cfe/trunk/tools/libclang/CIndexCodeCompletion.cpp?rev=112095&r1=112094&r2=112095&view=diff</a><br>==============================================================================<br>--- cfe/trunk/tools/libclang/CIndexCodeCompletion.cpp (original)<br>+++ cfe/trunk/tools/libclang/CIndexCodeCompletion.cpp Wed Aug 25 17:15:42 2010<br>@@ -582,6 +582,8 @@<br>         AllocatedResults.Results[I].CompletionString = StoredCompletion;<br>       }<br>     }<br>+    <br>+    // FIXME: Add ProcessOverloadCandidates?<br>   };<br> }<br><br><br><br>_______________________________________________<br>cfe-commits mailing list<br><a href="mailto:cfe-commits@cs.uiuc.edu">cfe-commits@cs.uiuc.edu</a><br>http://lists.cs.uiuc.edu/mailman/listinfo/cfe-commits<br></div></blockquote></div><br></div></body></html>