Source

pypy / pypy / rpython / ootypesystem / rpbc.py

Author Commit Message Labels Comments Date
Benjamin Peterson
base call_location specialization off the call operation
Branches
unroll-if-alt
Amaury Forgeot d'Arc
Merge from trunk: -r79741:79790
Branches
fast-forward
Antonio Cuni
make MultipleFrozenPBC immutable on ootype too
Antonio Cuni
this fixes the failing test, though I'm not sure it's 100% correct. All relevant tests seem to pass.
Carl Friedrich Bolz
continue the move of pypy.annotation.pairtype to pypy.tool.pairtype: fix imports and kill the import forwarding file.
Antonio Cuni
append _variant0 to method names only when necessary
Antonio Cuni
new translation option that makes ootype not to mangle the names of the attributes. Might be useful for a general purpose rpython-compiler.
Antonio Cuni
Sanity check.
Armin Rigo
Fix and test for 'rtype_is_None(none_frozen_pbc_repr)'.
Antonio Cuni
Factored two helper functions out of MethodsPBCRepr.call.
Antonio Cuni
(antocuni, nik, arigo) Fixed a cornercase for ootypesytem, where methods defined in superclass are only called in subclasses.
Antonio Cuni
(antocuni, nik, arigo) Generalized the instantiation of classes: now the two typesystems shares most of the code, and as a bonus a failing test now passes.
Antonio Cuni
(antocuni, nikh) Fixed a bug that prevented assertion to work. Don't longer skip some tests that make use of 'assert'.
Armin Rigo
Pass test_disjoint_pbcs. The repr of SomePBC is a (breath here) MultipleUnrelatedFrozenPBCRepr for frozen PBCs with no common attribute access set. This is an Address in the lltypesystem, and an instance of the empty base PBCROOT class in the ootypesystem.
Niklaus Haldimann
(pedronis, nik) fixed __del__ support in ootypesystem. __del__ is simply rtyped with a flag "finalizer", the backends are responsible for taking appropriate measures. fixed a horribly subtle bug in annotation, where emulated calls to __del__ methods were not correctly recorded.
Niklaus Haldimann
(pedronis, nik) made specialized methods work for ootype with surprisingly little hair-pulling. all method names are now mangled, so that all specialized variants have distinct names (even if there is only one variant).
Niklaus Haldimann
(pedronis, nik) made specialized functions work for ootype by factoring out an abstract FunctionsPBCRepr. fixed a test about frozen methods that wasn't testing what it thought it was (no _freeze_ method!). discovered by accident a different failing tests for specialized methods with ootype, disabled for now.
Niklaus Haldimann
(pedronis, nik) merge class attributes branch r23804:r23855 back into trunk. class attributes now work with ootype.
Niklaus Haldimann
(nik, mwh, pedronis around a bit) Move MethodOfFrozenPBCRepr up into rpython.rpbc. Simplify quite a bit the handling of 'is' in the ootypesytem. Enable more rpbc tests for the ootypesystem.
Niklaus Haldimann
(mwh, pedronis, nik) refactored MultipleFrozenPBCRepr to share code between the two type systems.
Niklaus Haldimann
(mwh, nik, pedronis around) made one test about MultipleFrozenPBCRepr pass with ootypesystem. needs refactoring to share code with lltype.
Niklaus Haldimann
(pedronis, mwh, nik) make simple_call/call_args work for ClassesPBCRepr.
Niklaus Haldimann
(pedronis, nik) added __init__ support with keywords. only partial, missing the same for runtimenew.
Niklaus Haldimann
(pedronis, nik) added call_args llop to ootype methods. a bit of generalizing to share code with lltype. but the various simple_call/call_args implementations are still a bit too similar (and obscure).
Niklaus Haldimann
(pedronis, nik) change rpython/test_rpbc to run tests with both lltypesystem and ootypesystem (only some for now, ultimately all of them). add simple_call __init__ support to ootype.
Niklaus Haldimann
copied test over from lltype, made it pass on ootype. all Instances now have the superclass ROOT, ROOT has None as the superclass.
Armin Rigo
ootyper: * more operations needed by ll helpers ("oo helpers"?) on OOInstanceReprs: 'is' and truth-value testing. * introduced a NULL run-time class reference, returned by type(x) if x is an instance that turns out to be None. This supports the RPython style 'if type(x) is W_SuchAndSuch:...' * annotator support: SomeOOClass(None) for this NULL run-time class reference. * more annotator support:…
Armin Rigo
Mangle attribute and method names to avoid clashes with attributes like _TYPE. Temporarily, it looks like a good idea to mangle names systematically to trap bugs related to a confusion between mangled and non-mangled names. Later a more subtle mangling that doesn't modify common names would be better.
Michael Hudson-Doyle
(boria, mwh, bert, samuele, arigo, anyone else who wants some credit/blame :) * move a large part of lltypesystem.rpbc.MethodsPBCRepr back into rpbc as AbstractMethodsPBCRepr and have what's left inherit from this. * implement ootypesystem.rpbc.MethodsPBCRepr. * extend ootypesystem.rclass.InstanceRepr to have some support for methods (no support for overriding yet). * enable a simple test that calls a method.
Boris Feigin
(pedronis, boria) * Further work on ootypesystem. * Initial support for classes. * test_simple_empty_base() in ootypesystem/test/test_ooclean.py now passes.