Is there any reason to use the 'auto' keyword in C++03?

后端 未结 10 1738
[愿得一人]
[愿得一人] 2020-11-28 02:27

Note this question was originally posted in 2009, before C++11 was ratified and before the meaning of the auto keyword was drast

10条回答
  •  北海茫月
    2020-11-28 03:11

    In old compiler, auto was one way to declare a local variable at all. You can't declare local variables in old compilers like Turbo C without the auto keyword or some such.

提交回复
热议问题