Commit 7953975
committed
clang-wrapper.cc: fix clang_getCalleeName
The callee declaration can be, e.g. a parameter declaration if the call
expression is a parameter callback, which is not a derived type of
FunctionDecl, and thus can't be casted to it. Only deal with
FunctionDecl (and FunctionTemplateDecl) type derivations and return an
empty strings for the other cases.1 parent 063e627 commit 7953975
1 file changed
+13
-6
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
487 | 487 | | |
488 | 488 | | |
489 | 489 | | |
490 | | - | |
491 | | - | |
492 | | - | |
493 | | - | |
494 | | - | |
495 | | - | |
| 490 | + | |
| 491 | + | |
| 492 | + | |
| 493 | + | |
| 494 | + | |
| 495 | + | |
| 496 | + | |
| 497 | + | |
| 498 | + | |
| 499 | + | |
| 500 | + | |
| 501 | + | |
| 502 | + | |
496 | 503 | | |
497 | 504 | | |
498 | 505 | | |
| |||
0 commit comments