1 /* { dg-do compile } */ 2 /* { dg-options "-fgnu-tm" } */ 3 4 struct list { 5 void (*compare)(); 6 } *listPtr; 7 8 static void (*compare)(); 9 10 __attribute__((transaction_safe)) func()11static void func () { 12 listPtr->compare(); /* { dg-error "unsafe indirect function call" } */ 13 compare(); /* { dg-error "unsafe function call" } */ 14 } 15