You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
auto x4{27} 在书中称 auto 推导出 std::initializer_list<int>。然而,在 N3922 之后,将会推导出 int。
auto x1 = {3}; // x1 is std::initializer_list<int>auto x2{1, 2}; // error: not a single elementauto x3{3}; // x3 is int// (before N3922 x2 and x3 were both std::initializer_list<int>)
auto x4{27}
在书中称auto
推导出std::initializer_list<int>
。然而,在 N3922 之后,将会推导出int
。在作者的网站中也指出了这一点:
有许多同学用这本书入门,建议标注出这一点。
参考资料:
The text was updated successfully, but these errors were encountered: