class_docstr: ``PlaceholderType`` is a ``ComplexType`` that involves placeholders, and thus its type
  resolution is context sensitive. This is an abstract class for all placeholder types like
  reverse, and, or, argmax, etc.
  
  Note that ANY_TYPE in NLTK's type system doesn't work like a wild card. Once the type of a
  variable gets resolved to a specific type, NLTK changes the type of that variable to that
  specific type. Hence, what NLTK calls "ANY_TYPE", is essentially a "yet-to-be-decided" type.
  This is a problem because we may want the same variable to bind to different types within a
  logical form, and using ANY_TYPE for this purpose will cause a resolution failure. For example
  the count function may apply to both rows and cells in the same logical form, and making count
  of type ``ComplexType(ANY_TYPE, DATE_NUM_TYPE)`` will cause a resolution error. This class lets
  you define ``ComplexType`` s with placeholders that are actually wild cards.
  
  The subclasses of this abstract class need to do three things
  1) Override the property ``_signature`` to define the type signature (this is just the
  signature's string representation and will not affect type inference or checking). You will see
  this signature in action sequences.
  2) Override ``resolve`` to resolve the type appropriately (see the docstring in ``resolve`` for
  more information).
  3) Override ``get_application_type`` which returns the return type when this type is applied as
  a function to an argument of a specified type.  For example, if you defined a reverse type by
  inheriting from this class, ``get_application_type`` gets an argument of type ``<a,b>``, it
  should return ``<b,a>`` .
class_docstr_tok: ["``","PlaceholderType","``","is","a","``","ComplexType","``","that","involves","placeholders",",","and","thus","its","type","resolution","is","context","sensitive",".","This","is","an","abstract","class","for","all","placeholder","types","like","reverse",",","and",",","or",",","argmax",",","etc",".","Note","that","ANY_TYPE","in","NLTK","'s","type","system","does","n't","work","like","a","wild","card",".","Once","the","type","of","a","variable","gets","resolved","to","a","specific","type",",","NLTK","changes","the","type","of","that","variable","to","that","specific","type",".","Hence",",","what","NLTK","calls","``","ANY_TYPE","''",",","is","essentially","a","``","yet-to-be-decided","''","type",".","This","is","a","problem","because","we","may","want","the","same","variable","to","bind","to","different","types","within","a","logical","form",",","and","using","ANY_TYPE","for","this","purpose","will","cause","a","resolution","failure",".","For","example","the","count","function","may","apply","to","both","rows","and","cells","in","the","same","logical","form",",","and","making","count","of","type","``","ComplexType","(","ANY_TYPE",",","DATE_NUM_TYPE",")","``","will","cause","a","resolution","error",".","This","class","lets","you","define","``","ComplexType","``","s","with","placeholders","that","are","actually","wild","cards",".","The","subclasses","of","this","abstract","class","need","to","do","three","things","1",")","Override","the","property","``","_signature","``","to","define","the","type","signature","(","this","is","just","the","signature","'s","string","representation","and","will","not","affect","type","inference","or","checking",")",".","You","will","see","this","signature","in","action","sequences",".","2",")","Override","``","resolve","``","to","resolve","the","type","appropriately","(","see","the","docstring","in","``","resolve","``","for","more","information",")",".","3",")","Override","``","get_application_type","``","which","returns","the","return","type","when","this","type","is","applied","as","a","function","to","an","argument","of","a","specified","type",".","For","example",",","if","you","defined","a","reverse","type","by","inheriting","from","this","class",",","``","get_application_type","``","gets","an","argument","of","type","``","<","a",",","b",">","``",",","it","should","return","``","<","b",",","a",">","``","."]
code: def matches(self, other):
      # self == ANY_TYPE = True iff self.first == ANY_TYPE and self.second == ANY_TYPE.
      return self == other or self == ANY_TYPE or other == ANY_TYPE
  
imports: from __future__ import absolute_import
  from collections import defaultdict
  from nltk.sem.logic import Expression, ApplicationExpression, ConstantExpression, LogicParser, Variable
  from nltk.sem.logic import Type, BasicType, ComplexType, ANY_TYPE
  from allennlp.common.util import START_SYMBOL
label_desc: Use image node_id 5 for calling the PlaceholderType obj's underlying member method code with example usage: obj.matches(other) and returns: unknown