The default compilation options on Windows NT (Visual C++) do not include the c++ compiler flag -GR. Without this flag, one cannot use a dynamic_cast construct on a G4 object pointer (fails at run-time). dynamic_cast is quite useful, not only for navigating a class's inheritance hierarchy but for easily determining the type of a pointer at runtime. We rely on it in our application built on Geant4. IMO, this option should be the default of the Visual C++ compiler (it is for most others), but since it is not, it would be helpful to include it in the defaults for building the G4 system. I have been manually changing the WIN32-VC.gmk file to include this option, and I have found no problems with building and running (i.e. no side-effects).
Although dynamic-casting is not allowed in the G4 kernel code, I introduced -GR option for WIN32-VC. The tag "config-V03-00-00" will be submitted to test and possible size/performance penalties evaluated.
Tag "config-V03-00-00" submitted to test.