[sv-ec] constant expression in call to new

From: Rich, Dave <Dave_Rich_at_.....>
Date: Wed Nov 15 2006 - 08:28:31 PST
Section 6.3.5 about const constants says "The arguments to the new
method must be constant expressions."

 

Can anybody think of a reason why we need this rule? Why single out new
from any other function call? 

 

Any variable declaration initialization, const or non-const will have
problems if you reference other variables.

 

 

The reason I ask is I would like to be able to do things like

 

const classname foo= new($test$plusargs("switch"));

 

Dave

 
Received on Wed Nov 15 08:28:40 2006

This archive was generated by hypermail 2.1.8 : Wed Nov 15 2006 - 08:29:00 PST