variadic functions

L

Loony

Hi,

I want to use variadic functions with stl containers as arguments but
I am not sure if that is possible and if so how.

I'm using gcc 3.3 on Suse 8.2

Hope someone can help me.

Thanx in advance
 
R

Ron Natalie

Loony said:
I want to use variadic functions with stl containers as arguments but
I am not sure if that is possible and if so how.
You can not. "If the argumenta has a non-POD class type, the behavior is
undefined." 5.2.2/7.

You can pass pointers to these types however.
 
K

Kevin Goodsell

Loony said:
Hi,

I want to use variadic functions with stl containers as arguments but
I am not sure if that is possible and if so how.

I'm using gcc 3.3 on Suse 8.2

Hope someone can help me.

Thanx in advance

Use variadic functions only as a last resort. Please endeavor to find
alternatives first. Variadic functions are horribly error-prone.

-Kevin
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,764
Messages
2,569,564
Members
45,039
Latest member
CasimiraVa

Latest Threads

Top