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

            Bug ID: 16676
           Summary: Crash-on-invalid with a fragile combination of typo
                    corrections and whitespace
           Product: clang
           Version: trunk
          Hardware: PC
                OS: Linux
            Status: NEW
          Severity: normal
          Priority: P
         Component: Frontend
          Assignee: [email protected]
          Reporter: [email protected]
                CC: [email protected]
    Classification: Unclassified

$ cat test.cc
struct S { int i; };
struct T { S* get_s(); };
int f(S* s) {
  T t;
  return t.get_s
      .i;
}
$ clang -fsyntax-only test.cc
test.cc:5:12: error: reference to non-static member function must be called;
did you mean to call it with no arguments?
  return t.get_s
         ~~^~~~~
                ()
/usr/local/google/home/matthewbg/test.cc:6:7: error: member reference type 'S
*' is a pointer; maybe you meant to use '->'?
clang: llvm/tools/clang/lib/Frontend/TextDiagnostic.cpp:973: void
highlightRange(const clang::CharSourceRange &, unsigned int, clang::FileID,
const <anonymous>::SourceColumnMap &, std::string &, const clang::SourceManager
&, const clang::LangOptions &): Assertion `StartColNo <= EndColNo && "Trying to
highlight whitespace??"' failed.

-- 
You are receiving this mail because:
You are on the CC list for the bug.
_______________________________________________
LLVMbugs mailing list
[email protected]
http://lists.cs.uiuc.edu/mailman/listinfo/llvmbugs

Reply via email to