摘要: 下面几种风格都是可能的:void foo (const int &x);void foo (const int& x);void foo (int const &x);void foo (int const& x);对“常整数”而言,上面的几种用法虽然差别不大,但我们趋向于使用int const,而不使用const int。作出这个选择,主要有两个原因:首先,针对问题“什么是恒定不变的?”,int const提供了很容易理解的答案。实际上,“恒定不变部分”指的是const限定符前面的部分。例如,尽管const int N = 100;等价于:int const 阅读全文