[LLVMbugs] [Bug 8744] New: Assert when code completing a #include

bugzilla-daemon at llvm.org bugzilla-daemon at llvm.org
Mon Dec 6 03:01:40 PST 2010


http://llvm.org/bugs/show_bug.cgi?id=8744

           Summary: Assert when code completing a #include
           Product: clang
           Version: unspecified
          Platform: All
        OS/Version: Windows NT
            Status: NEW
          Severity: normal
          Priority: P
         Component: Frontend
        AssignedTo: unassignedclangbugs at nondot.org
        ReportedBy: plc at rowley.co.uk
                CC: llvmbugs at cs.uiuc.edu


clang will AV when trying to code complete at the opening < of an #include
directive that has no closing >.  (Not sure about whether additional tokens
will do this either...)

Repro:

> c-index-test -code-completion-at=foo1.c:1:11 foo1.c

foo1.c:

#include <

void foo(void)
{
}

Also attached foo1.c.  It seems as if clang is not expecting the code
completion token in this case.  Can't say I blame it, but the code completion
token can probably pop up anywhere.  There is no documented API restriction on
*where* the token can appear, but just some words on where you'd expect to call
code completion.

I can guess at a fix; however, my clang skills are still being sharpened, so
time to let the pros have a bash.

-- 
Configure bugmail: http://llvm.org/bugs/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are on the CC list for the bug.



More information about the llvm-bugs mailing list