summaryrefslogtreecommitdiff
path: root/astroid/helpers.py
Commit message (Collapse)AuthorAgeFilesLines
* Rename Uninferable and instantiate_class, fix broken tests, improveCeridwen2015-11-061-5/+5
| | | | | | | | | | | testing. * Rename YES to Uninferable * Rename instanciate_class to instantiate_class. * Use six in test_namedtuple_advanced_inference. * Fix test_file_from_module failure on PyPy. * Add enum34 to unittest_brain. * Add unittest_brain dependencies tox.ini.
* Update the docstring of object_type in order to make it clearer for its ↵Claudiu Popa2015-10-291-2/+4
| | | | actual purpose.
* Add support for indexing containers with instances which provides an ↵Claudiu Popa2015-10-221-0/+24
| | | | | | | | __index__ returning-int method. This patch moves _class_as_index to helpers, where it becames class_instance_as_index. Also, it instantiates its own call context, which makes certain idioms with lambdas to work.
* Add tests for aliasesCeridwen2015-08-211-1/+1
|
* Convert line endings for some files back to DOSCeridwen2015-08-151-158/+158
|
* Merge main into defaultCeridwen2015-08-141-7/+9
|\
| * Move InferenceContext and CallContext into astroid.contextClaudiu Popa2015-08-121-1/+2
| | | | | | | | | | | | | | In order to reduce circular dependencies between components, CallContext is moved into a new module, astroid.context. At the same time, for increasing the cohesion inside astroid.bases, InferenceContext was moved as well into astroid.context.
| * Move YES to astroid.util.Claudiu Popa2015-08-091-4/+5
| | | | | | | | | | | | | | YES is needed by other components of astroid, components which aren't necessarily related to astroid.bases. In order to reduce circular interdependencies between components, YES is moved into a new module, tailored for various *utilities*.
| * Return YES if no types could be deduced for the type builtin.Claudiu Popa2015-08-021-1/+1
| |
* | Node constructors almost finished except for two bugsCeridwen2015-07-081-156/+156
|/
* Add helpers.is_supertype and helpers.is_subtype, two functions for checking ↵Claudiu Popa2015-06-261-16/+77
| | | | if an object is a super/sub type of another.
* Add astroid.helpers, a module of various useful utilities which don't belong ↵Claudiu Popa2015-06-241-0/+95
yet into other components. Added *object_type*, a function which can be used to obtain the type of almost any astroid object, similar to how the builtin *type* works.