method multi

Documentation for method multi assembled from the following types:

class Routine

From Routine

(Routine) method multi

method multi(Routine:D: --> Bool:D)

Returns True if the routine is a multi sub or method. Note that the name of a multi sub refers to its proto and this method would return false if called on it. It needs to be called on the candidates themselves:

multi foo ($, $) {};
say &foo.multi;             # OUTPUT: «False␤» 
say &foo.candidates».multi# OUTPUT: «(True)␤»