# Path: pyke/pattern.py
# class pattern(object):
#     def __ne__(self, b): return not (self == b)
# 
#     def simple_match_pattern(self, bindings, my_context, pattern_b, b_context):
#         return self.match_pattern(bindings, my_context, pattern_b, b_context)
# 
#     def lookup(self, context, allow_variable_in_ans = False):
#         return self
# 
# Path: pyke/unique.py
# class unique(object):
#     def __init__(self, name): self.name = name
# 
#     def __repr__(self): return "<unique %s>" % self.name


import sys
from pyke import pattern, unique
        >>> ans                                 # doctest: +ELLIPSIS
        ($a_var, <pyke.contexts.simple_context object at ...>)
        >>> ans[1] is A_context
        True
    
    But to differentiate variables from string literals in the patterns,
    variables are special objects.  When a variable is bound as data (to
    another variable), it is bound as a variable object (again, to
    differentiate it from plain python strings).

        >>> type(ans[0])
        <class 'pyke.contexts.variable'>

    The anonymous variables have names starting with '_'.  Binding
    requests on anonymous variables are silently ignored.

        >>> anonymous('_ignored')
        $_ignored
        >>> A_context.bind('_bogus', A_context, 567)
        False
        >>> A_context.lookup_data('_bogus')
        Traceback (most recent call last):
            ...
        KeyError: '$_bogus not bound'
        >>> A_context.lookup_data('_bogus', True)
        '$_bogus'
"""




# Path: pyke/pattern.py
# class pattern(object):
#     def __ne__(self, b): return not (self == b)
# 
#     def simple_match_pattern(self, bindings, my_context, pattern_b, b_context):
#         return self.match_pattern(bindings, my_context, pattern_b, b_context)
# 
#     def lookup(self, context, allow_variable_in_ans = False):
#         return self
# 
# Path: pyke/unique.py
# class unique(object):
#     def __init__(self, name): self.name = name
# 
#     def __repr__(self): return "<unique %s>" % self.name


# Path: pyke/contexts.py
import sys
from pyke import pattern, unique

        >>> ans                                 # doctest: +ELLIPSIS
        ($a_var, <pyke.contexts.simple_context object at ...>)
        >>> ans[1] is A_context
        True
    
    But to differentiate variables from string literals in the patterns,
    variables are special objects.  When a variable is bound as data (to
    another variable), it is bound as a variable object (again, to
    differentiate it from plain python strings).

        >>> type(ans[0])
        <class 'pyke.contexts.variable'>

    The anonymous variables have names starting with '_'.  Binding
    requests on anonymous variables are silently ignored.

        >>> anonymous('_ignored')
        $_ignored
        >>> A_context.bind('_bogus', A_context, 567)
        False
        >>> A_context.lookup_data('_bogus')
        Traceback (most recent call last):
            ...
        KeyError: '$_bogus not bound'
        >>> A_context.lookup_data('_bogus', True)
        '$_bogus'
"""




_Not_found = unique.unique('Not_found')