Most important things about C++ templates… lesson learned

前端 未结 12 1728
暗喜
暗喜 2021-01-30 18:52

What are most important things you know about templates: hidden features, common mistakes, best and most useful practices, tips...common mistakes/oversight/assumptions

12条回答
  •  半阙折子戏
    2021-01-30 19:31

    Read Meyers's Effective STL and C++ books, and Alexandrescu's Modern C++ Design.

    Meyers will give you the basics on easy mistakes to make and how to avoid them. Alexandrescu introduces you to a template-based programming model that should have you asking "Is this really a good idea?" the entire book.

提交回复
热议问题