Community
Participate
Working Groups
OclSelf is current a special function Operation Template Parameter that must be declared. It is resolved as part of the specialization that creates the specialized signatures sometimes. Change OclSelf to a pseudo-type that then just needs one global declaration, allowing as many uses as necessary. This should allow operation specialization to be unreified; OperationCallExp.referredOperation can be to the unspecialized operation, since the sopurce and arguments provide all the true types; no need to create the specialization and clutter up an orphanage. This could simplify the pivot model so that only types have reified specializations.
Operation specializations are now eliminated in the bug branch. The second part of OclSelf is self-variant overload dispatch: e.g OclAny::=(OclSelf) rather than OclAny::(OclAny) so that Collection::=(Collection) is an invariant overload, requiring single dynamic dispatch on the common type of source and argument. This is particularly useful for numerics so that Real::+(OclSelf) : Real can be a catchall for Double::+(OclSelf) : Real Integer::+(OclSelf) : Integer Long::+(OclSelf) : Integer Int::+(OclSelf) : Integer. The dynamic dispatch for int + int will automatically invoke Int::+(OclSelf) : Integer, requiring only intelligent code to give an appropriately grown type for the result.
All symmetric binary operations are now declared using OclSelf and matched and dispatched accordingly. Numeric Plus and Minus Operations revised to have distinct Real and Integer declarations. This saves an inheritance level for each. Other operators can be tuned when IntValueImpl, LongValueImpl etc are introduced. pushed to master.
Closing all bugs resolved in Indigo.