CMP - United Business Media TechOnline
All Articles Products Courses Papers VirtuaLabs Webinars Web



 
LoginRegister
      TechOnline > Electronics Company Directory > Technical Paper
Technical Papers
Coming to Terms with C++ Templates

Click to Download
pdf logo
2007 Embedded Systems Conference
89 KB (11 pages)
April 05, 2007
 

Scott Meyers

This paper examines the use of C++ templates in embedded systems from two different viewpoints. First, it addresses the reputation that templates have for code bloat, explaining how template instantiation occurs and can be controlled, as well as describing techniques that are useful for limiting bloat. Secondly, it describes two applications of templates, one layering type-safety on top of void-based containers without adding any runtime cost, the second detecting dimensional unit type errors during compilation — behavior that cannot be implemented in C. The information in this paper is an overview of more detailed information covered in the conference presentation.

 
Rate this paper
WORSE | BETTER
1 2 3 4 5

submit a paper

Embedded Systems Conference (ESC)
   

TECH PAPER
1. System ACE Configuration Solution for Xilinx FPGAs

TECH PAPER
2. Use Rowley CrossWorks and the MAXQ3120 Evaluation Kit to Create a Light Meter Application

TECH PAPER
3. Get a Grip on Multimedia PMP Demands with the Right Processor Selection

TECH PAPER
4. Interface Products Design Guide