void ffeinfo_init_0 () { ffeinfoBasictype i; ffeinfoBasictype j; assert (FFEINFO_basictype == ARRAY_SIZE (ffeinfo_basictype_string_)); assert (FFEINFO_kind == ARRAY_SIZE (ffeinfo_kind_message_)); assert (FFEINFO_kind == ARRAY_SIZE (ffeinfo_kind_string_)); assert (FFEINFO_kindtype == ARRAY_SIZE (ffeinfo_kindtype_string_)); assert (FFEINFO_where == ARRAY_SIZE (ffeinfo_where_string_)); /* Make array that, given two basic types, produces resulting basic type. */ for (i = 0; i < FFEINFO_basictype; ++i) for (j = 0; j < FFEINFO_basictype; ++j) if ((i == FFEINFO_basictypeANY) || (j == FFEINFO_basictypeANY)) ffeinfo_combine_[i][j] = FFEINFO_basictypeANY; else ffeinfo_combine_[i][j] = FFEINFO_basictypeNONE; #define same(bt) ffeinfo_combine_[bt][bt] = bt #define use2(bt1,bt2) ffeinfo_combine_[bt1][bt2] \ = ffeinfo_combine_[bt2][bt1] = bt2 same (FFEINFO_basictypeINTEGER); same (FFEINFO_basictypeLOGICAL); same (FFEINFO_basictypeREAL); same (FFEINFO_basictypeCOMPLEX); same (FFEINFO_basictypeCHARACTER); use2 (FFEINFO_basictypeINTEGER, FFEINFO_basictypeREAL); use2 (FFEINFO_basictypeINTEGER, FFEINFO_basictypeCOMPLEX); use2 (FFEINFO_basictypeREAL, FFEINFO_basictypeCOMPLEX); #undef same #undef use2 }
void passThrough(int *p) { use2(p, compute()); // expected-note@-1 {{Passing null pointer value via 1st parameter 'ptr'}} // expected-note@-2 {{Calling 'use2'}} }