[LLVMbugs] [Bug 12025] New: fix-it for '->' versus '.'

bugzilla-daemon at llvm.org bugzilla-daemon at llvm.org
Thu Feb 16 17:25:27 PST 2012


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

             Bug #: 12025
           Summary: fix-it for '->' versus '.'
           Product: clang
           Version: trunk
          Platform: All
        OS/Version: All
            Status: NEW
          Severity: enhancement
          Priority: P
         Component: -New Bugs
        AssignedTo: unassignedclangbugs at nondot.org
        ReportedBy: nobled at dreamwidth.org
                CC: llvmbugs at cs.uiuc.edu
    Classification: Unclassified


class B { 
public:
int a;
int func() { return a; }
};

static B b;

int fixthis() {
B *_b = &b;
return  _b.a + _b.func() + b->a + b->func();
}

clang suggests a fixit for the first two expressions ("maybe you meant to use
'->'?"), but not the last two. It looks like
diag::err_typecheck_member_reference_suggestion is used in a few places, but
for some reason it only catches it in one direction.

-- 
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