官术网_书友最值得收藏!

  • Mastering C++ Programming
  • Jeganathan Swaminathan
  • 167字
  • 2021-07-02 18:28:47

Summary

In this chapter, you got to know interesting new features introduced in C++17. You learned the super simple C++17 nested namespace syntax. You also learned datatype detection with a braced initializer list and the new rule imposed in the C++17 standard.

You also noticed that static_assert can be done without assert failure messages. Also, using std::invoke(), you can now invoke global functions, function pointers, member functions, and static class member functions. And, using structured binding, you could now initialize multiple variables with a return value.

You also learned that the if and switch statements can have a local-scoped variable right before the if condition and switch statements. You learned about auto type detection of class templates. Lastly, you used inline variables.

There are many more C++17 features, but this chapter attempts to cover the most useful features that might be required for most of the developers.  In the next chapter, you will be learning about the Standard Template Library.

主站蜘蛛池模板: 鄂托克旗| 广宗县| 襄樊市| 大连市| 博客| 延边| 涪陵区| 墨脱县| 武隆县| 太仆寺旗| 大渡口区| 宿松县| 唐山市| 泰宁县| 枣强县| 平湖市| 青神县| 岳西县| 德格县| 奇台县| 泸溪县| 清水河县| 永善县| 太保市| 阜新市| 潼关县| 肥乡县| 姜堰市| 乌兰县| 定边县| 卢龙县| 开鲁县| 太原市| 云林县| 洱源县| 钟山县| 安顺市| 苍山县| 连城县| 手游| 林周县|