Question & Answer
Question
Why is no forward declaration generated for class having object with multiplicity grater than 1?
Answer
Prior to Rhapsody 7.4 it was possible to generate the forward declaration for class having object with multiplicity greater than 1. However, since IBM Rational Rhapsody 7.5, it is not generated due to the new C language standard.
According to the new standard: if there is a class under a package then generation of forward declaration for the object should contain include for class file which will result in circular dependency as the class file already includes package information.
Hence the suggested approach is:
- Override and check property CG:Package:GenerateExternDeclarationForObjectArray.
- Change the model so files will not use those objects.
Product Synonym
Rational Rhapsody
Was this topic helpful?
Document Information
Modified date:
27 May 2022
UID
swg21407796