Template portablity questions. 
Author Message
 Template portablity questions.

Templates are attractive to use especially for
pointer wrapping but are often a portability
barrier and sometimes an absolute one. I want to
write standards against the non portable features
for a large project. This forum seems an ideal
place to ask for help.

So far I have.

Templates should be defined entirely in header
files to be used as a sort of macro.

Parameterize only on classes not numbers etc.

No static template objects that need to be
initialized.



Sat, 09 Feb 2002 03:00:00 GMT  
 Template portablity questions.

Quote:

> Templates are attractive to use especially for
> pointer wrapping but are often a portability
> barrier and sometimes an absolute one. I want to
> write standards against the non portable features
> for a large project. This forum seems an ideal
> place to ask for help.

> So far I have.

> Templates should be defined entirely in header
> files to be used as a sort of macro.

> Parameterize only on classes not numbers etc.

> No static template objects that need to be
> initialized.

There was a very interesting article in C/C++ users journal of
January 1997. (www.cuj.com) by Anil Admal and Chris Tarr.
They categorize some possible problems (23 problems ) and
tested the compilers availables at the moment.


Sat, 09 Feb 2002 03:00:00 GMT  
 Template portablity questions.

Quote:

> Templates are attractive to use especially for
> pointer wrapping but are often a portability
> barrier and sometimes an absolute one. I want to
> write standards against the non portable features
> for a large project. This forum seems an ideal
> place to ask for help.

> So far I have.

> Templates should be defined entirely in header
> files to be used as a sort of macro.

Not necessarily.. They can be defined in a separate source
file and included. You can also use export keyword and link
the object file..

Sree



Sun, 10 Feb 2002 03:00:00 GMT  
 Template portablity questions.

Quote:


> > Templates are attractive to use especially for
> > pointer wrapping but are often a portability
> > barrier and sometimes an absolute one. I want to
> > write standards against the non portable features
> > for a large project. This forum seems an ideal
> > place to ask for help.

> > So far I have.

> > Templates should be defined entirely in header
> > files to be used as a sort of macro.

> Not necessarily.. They can be defined in a separate source
> file and included. You can also use export keyword and link
> the object file..

And then you can give porting to g++.


Sun, 10 Feb 2002 03:00:00 GMT  
 
 [ 4 post ] 

 Relevant Pages 

1. Portablity Questions: INTEGER_8, 16, 64 and bit manipulation

2. (gulp) newbie question - portablity of python

3. Binary files vs Portablity vs Ada

4. more silly portablity problems

5. Internet application template vs. Web application template

6. New templates added to Solace Software Free template set

7. New Templates: the Internet Framework Templates - HTTP Server Edition Version 1.5

8. ABC templates... can i change an applications templates

9. A Template to Write Templates?

10. ANN: New release of S.C.A. Micro Templates (Browse Header Sort and Reverse Sort Template)

11. Clarion templates to ABC templates

12. Kit Template Nova Vida (Template para Backup ON-Line) somente para Brazileiros e Portugueses por enquanto

 

 
Powered by phpBB® Forum Software