void test_coords_and_neighbors( const Triangul& T, const typename Triangul::Geom_traits::Point_3& p, const typename Triangul::Geom_traits::Vector_3& n, const typename Triangul::Geom_traits::FT& tolerance, const int& version ) { CGAL::Set_ieee_double_precision pfr; typedef std::pair<typename Triangul::Geom_traits::Point_3, typename Triangul::Geom_traits::FT > Point_coord_pair; std::vector<Point_coord_pair > coords; typename Triangul::Geom_traits::FT norm; norm = test_coords(T, p, n,version, std::back_inserter(coords)).second; assert(test_norm( coords.begin(), coords.end(),norm)); assert(test_barycenter(coords.begin(), coords.end(),norm,p, tolerance)); //All function testing surface neighbors are // grouped together: std::vector< typename Triangul::Geom_traits::Point_3 > neighbors; test_neighbors(T, p, n,version, std::back_inserter(neighbors)); assert(compare_neighbors(coords.begin(), coords.end(),neighbors.begin(), neighbors.end(), T.geom_traits())); //done }
int main() { try { boost::locale::localization_backend_manager mgr = boost::locale::localization_backend_manager::global(); mgr.select("winapi"); boost::locale::localization_backend_manager::global(mgr); std::cout << "Testing char" << std::endl; test_char<char>(); std::cout << "Testing wchar_t" << std::endl; test_char<wchar_t>(); std::cout << "Testing Unicode normalization" << std::endl; test_norm("\xEF\xAC\x81","\xEF\xAC\x81",boost::locale::norm_nfd); /// ligature fi test_norm("\xEF\xAC\x81","\xEF\xAC\x81",boost::locale::norm_nfc); #if defined(_WIN32_NT) && _WIN32_NT >= 0x600 test_norm("\xEF\xAC\x81","fi",boost::locale::norm_nfkd); test_norm("\xEF\xAC\x81","fi",boost::locale::norm_nfkc); #endif test_norm("ä","ä",boost::locale::norm_nfd); // ä to a and accent test_norm("ä","ä",boost::locale::norm_nfc); } catch(std::exception const &e) { std::cerr << "Failed " << e.what() << std::endl; return EXIT_FAILURE; } FINALIZE(); }
void main(void) { simif= (__xdata char *)0xffff; serial_init(9600); test_32div16(0); test_32sdiv16(0); test_16div16(0); test_16sdiv16(0); test_16mul16(0); test_16smul16(0); test_norm(0); test_lshift(0); test_ashift(0); *simif= 's'; while (1) { } }