fancy_abort(filename, lineno, function);
}
+/**
+ * Get the name of the current function. You can call this directly
+ * from a pass function or from any join point iterator function.
+ */
const char *
-aop_capture_function_name (struct aop_joinpoint *jp)
+aop_get_function_name (void)
{
return IDENTIFIER_POINTER (DECL_NAME (current_function_decl));
}
*/
#define AOP_DYNVAL(VAL) ATA_DYNVAL, VAL
-extern const char *aop_capture_function_name (struct aop_joinpoint *jp);
+extern const char *aop_get_function_name (void);
extern struct aop_pointcut *aop_match_function_entry ();
extern void aop_filter_by_in_param (struct aop_pointcut *pc, int n,
{
const char *name;
- name = aop_capture_function_name(jp);
+ name = aop_get_function_name();
if (name != NULL && strcmp(name, "foo") == 0) {
aop_duplicate(jp, "_distrib", AOP_TERM_ARG);
duplicated = 1;
const char *called;
struct aop_dynval *p;
- func = aop_capture_function_name(jp);
+ func = aop_get_function_name();
if (func == NULL || strcmp(func, "run_test") != 0)
return;
{
const char *name;
- name = aop_capture_function_name(jp);
+ name = aop_get_function_name();
if (name != NULL && strcmp(name, "foo") == 0) {
aop_duplicate(jp, "_distrib", AOP_TERM_ARG);
duplicated = 1;