class documentation

Class that represents a function application category. Consists of argument and result categories, together with an application direction.

Method __init__ Undocumented
Method __str__ Undocumented
Method arg Undocumented
Method can_unify Returns None if they cannot be unified
Method dir Undocumented
Method is_function Returns true if the category is a function application.
Method is_primitive Returns true if the category is primitive.
Method is_var Returns true if the category is a variable.
Method res Undocumented
Method substitute Takes a set of (var, category) substitutions, and replaces every occurrence of the variable with the corresponding category.
Instance Variable _arg Undocumented
Instance Variable _comparison_key Undocumented
Instance Variable _dir Undocumented
Instance Variable _res Undocumented

Inherited from AbstractCCGCategory:

Method __eq__ Undocumented
Method __hash__ Undocumented
Method __lt__ Undocumented
Method __ne__ Undocumented
Instance Variable _hash Undocumented
def __init__(self, res, arg, dir): (source)

Undocumented

def __str__(self): (source)
def arg(self): (source)

Undocumented

def can_unify(self, other): (source)

Determines whether two categories can be unified.
  • Returns None if they cannot be unified
  • Returns a list of necessary substitutions if they can.

def dir(self): (source)

Undocumented

def is_function(self): (source)

Returns true if the category is a function application.

def is_primitive(self): (source)

Returns true if the category is primitive.

def is_var(self): (source)

Returns true if the category is a variable.

def res(self): (source)

Undocumented

def substitute(self, subs): (source)

Takes a set of (var, category) substitutions, and replaces every occurrence of the variable with the corresponding category.

Undocumented

_comparison_key = (source)

Undocumented

Undocumented

Undocumented