C/C++ Compiler (cl.hlp) (Table of Contents; Topic list)
Important Notice
The pages on this site contain documentation for very old MS-DOS software, purely for historical purposes. If you're looking for up-to-date documentation, particularly for programming, you should not rely on the information found here, as it will be woefully out of date.
C2385
                                             Up Contents Index Back
────────────────────────────────────────────────────────────────────────────
 
     Compiler error C2385
 
     'class::member' is ambiguous
 
     The specified member was derived from more than one object.
 
     This error is caused by referencing a member of an object that was
     inherited from more than one object. Make the member unambigous by
     providing a cast or by changing the name of the offending members
     of the base classes.
 
     Warning C4385 is generated in conjunction with this error, and
     provides additional information about the ambiguity.
 
     The following is an example of this error:
 
          struct A { int x; };
          struct B { int x; };
          struct C : A, B {};
          void func ()
          {
             C aC;
             aC.x = 9;        // error
          }
                                    -♦-