Skip to content

getCalleeDecl() returns NULL in edge case. #11176

@llvmbot

Description

@llvmbot
Bugzilla Link 10804
Version trunk
OS Linux
Reporter LLVM Bugzilla Contributor
CC @jryans

Extended Description

getCalleeDecl() returns NULL in a function call to a method pointer, if the method pointer is passed as a template parameter. For example:

template<void (UnFoo::*methptr)()>
class MCaller {
public:
static void call_method_ptr(UnFoo *f) {
// FIXME: Possible Clang bug:
// getCalleeDecl() returns NULL in the following case:
(f->*methptr)();
}
};

void call_method_ptr_inst(UnFoo* f) {
MCaller<&UnFoo::foo>::call_method_ptr(f);
}

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugzillaIssues migrated from bugzillaclang:frontendLanguage frontend issues, e.g. anything involving "Sema"

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions