Product Documentation
Cadence SKILL++ Object System Reference
Product Version IC23.1, June 2023

ilGenerateSpecializer

ilGenerateSpecializer( 
g_genericFunctionObj
S_specSymbol
l_argList
)
=> g_expression

Description

Returns a SKILL expression that makes an instance of the given specializer class and optionally set the slots. In the generated SKILL expression, l_argList can be used to initialize the slots.

Arguments

g_genericFunctionObj

An instance of the ilGenericFunction class or a proxy class derived from it. Using proxy classes is one way of associating custom specializers with generic functions. The SKILL Language User Guide describes how to define proxy classes to define a group of generic functions to use common specializers.

S_specSymbol

The symbol or string used as the first entry in defmethod to trigger the custom specializer.

l_argList

The remaining arguments to the specializer. If more than one argument is given, this is a list of all the arguments.

Value Returned

g_expression

A SKILL expression that is to be evaluated inside defmethod.

Examples

An example of ilGenerateSpecializer using an eqv specializer to match the expected symbol. Since the generic function object is not used, it is prefixed with an underscore to prevent any impact on the SKILL Lint score and to indicate that it is unused.

defmethod(ilGenerateSpecializer (_gf (_spec (eqv 'abDbFig)) args
   makeInstance('abDbFigSpecializer ?objType car(args))

Another way of implementing this is to return the code needed to generate the instance:

defmethod(ilGenerateSpecializer (_gf (_spec (eqv 'abDbFig)) args)
   `makeInstance('abDbFigSpecializer ?objType ,car(args))

Related Topics

Generic Specializers

Examples of How to use Custom Specializers in SKILL++ Methods


Return to top
 ⠀
X