Allocate object memory statically; intialize it dynamically? I have an object whose constructor gets passed a parameter. If I know the parameter value at compile time, I can construct the object statically:

static FOOOBJ foo(3);

(I understand that it isn't really done statically, i.e. by the compiler, but is actually done during setup).

But if I don't know the parameter value at compile time, I'd still like to pre-allocate space for the object but construct the object in that space at run time. Can it be done without a separate .initialize() method?
You can use placement syntax to specify an existing allocation in which to instantiate the class.

FOOOBJ foo(0);

 ...

  FOOOBJ *f = new (foo) FOOOBJ(3);