Templates across API boundaries: Powerful but problematic
Stephen Cross, Undo Software
Embedded.com (March 07, 2016)
C++ is controversial. For every discussion about it, a certain percentage of people will love it and another substantial group will hate it. Above all, one feature highlights this divide: templates. Templates have many problems: they slow compile times, force implementations to be specified in headers and can bloat generated code. However they’re also a powerful mechanism for programming against generic types.
There can be no doubt that templates are a key part of the C++ language; the standard library relies on them heavily and they’ve been adopted throughout libraries such as Boost. This series of articles explains the problems with C++ templates and outlines new and exciting approaches for enhancing their capabilities and eliminating their drawbacks. In this first part, I define templates and discuss problems engineers have faced in dealing with templates across API boundaries.
E-mail This Article | Printer-Friendly Page |
|
Related Articles
- Transaction Analysis and Debug across Language Boundaries and between Abstraction Levels
- The complete series of high-end DDR IP solutions of Innosilicon is industry-leading and across major foundry processes
- IoT Security: Exploring Risks and Countermeasures Across Industries
- CAN FD: Anything But Automotive Only
- System Verilog Macro: A Powerful Feature for Design Verification Projects
New Articles
Most Popular
- System Verilog Assertions Simplified
- System Verilog Macro: A Powerful Feature for Design Verification Projects
- Synthesis Methodology & Netlist Qualification
- Enhancing VLSI Design Efficiency: Tackling Congestion and Shorts with Practical Approaches and PnR Tool (ICC2)
- Demystifying MIPI C-PHY / DPHY Subsystem