Update item2.md

This commit is contained in:
猫耳堀川雷鼓 2021-03-02 11:32:01 +08:00 committed by GitHub
parent 6fa21f8143
commit 4753623c99
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -160,10 +160,10 @@ auto createInitList()
同样在C++14的lambda函数中这样使用auto也不能通过编译
````cpp
std::vector<int> v;
...
auto resetV =
[&v](const auto& newValue){ v = newValue; }; //C++14
...
resetV({ 1, 2, 3 }); //错误!不能推导{ 1, 2, 3 }的类型
````