// ---------------------------------------------------------------------- // // countbad.cc - Test for the (incorrect) presence of old-style count(). // // History: // 24-Jun-1999 WEB Initial draft // 01-Jul-1999 WEB Fix omitted namespace qualifier // 25-Apr-2001 WEB s//"ISOcxx\/ISOcxxSyntax.hh"/ // // ---------------------------------------------------------------------- #include "ISOcxx/ISOcxxSyntax.hh" #include int main() { int a[] = { 1, 2, 3, 4, 5, 4, 3, 2, 1, 0 }; int n( 0 ); std::count( a, a+sizeof(a)/sizeof(a[0]), 3, n ); return n; // this program ought never compile! } // main()