摘要: try { std::cout << "finish" << std::endl; throw std::out_of_range("error"); return -1; } catch (std::exception const& ex) { std::cerr << ex.what()<<st 阅读全文
posted @ 2022-09-19 21:26 风飞侠 阅读(209) 评论(0) 推荐(0)
摘要: void foo(const int& x); void foo(const int& x); void foo(int const& x); void foo(int const& x); 几种都可,常数更倾向int const,可以用理论解释 const int* bookmark; int*  阅读全文
posted @ 2022-09-19 15:59 风飞侠 阅读(19) 评论(0) 推荐(0)