In C++, is it bad to pass a const bool by reference?

前端 未结 6 1663
渐次进展
渐次进展 2021-02-12 23:08

In a practical environment, using gcc or MS Visual Studio, is it bad to pass the value types which are the same size or less than an int by const reference ?

i.e. is it

6条回答
  •  梦谈多话
    2021-02-12 23:19

    It really doesn't matter, passing by value makes cleaner code thou and is therefore considered good practice.

提交回复
热议问题