| 2980 | } |
| 2981 | |
| 2982 | void functionArgs16() { // #9591 |
| 2983 | const char code[] = |
| 2984 | "struct A { int var; };\n" |
| 2985 | "void foo(int x, decltype(A::var) *&p) {}"; |
| 2986 | GET_SYMBOL_DB(code); |
| 2987 | ASSERT(db); |
| 2988 | const Scope *scope = db->functionScopes.front(); |
| 2989 | const Function *func = scope->function; |
| 2990 | ASSERT_EQUALS(2, func->argCount()); |
| 2991 | const Variable *arg2 = func->getArgumentVar(1); |
| 2992 | ASSERT_EQUALS("p", arg2->name()); |
| 2993 | ASSERT(arg2->isPointer()); |
| 2994 | ASSERT(arg2->isReference()); |
| 2995 | } |
| 2996 | |
| 2997 | void functionArgs17() { |
| 2998 | const char code[] = "void f(int (*fp)(), int x, int y) {}"; |
nothing calls this directly
no test coverage detected