# HG changeset patch # User Paul Boddie # Date 1485043941 -3600 # Node ID 82a420510d632594d7bcced3db09a38b068b9a28 # Parent 87a9ae235e7abc368b35c6895758c6dcf16e509d Fixed accesses with static initial bases despite any initial instance accessor. diff -r 87a9ae235e7a -r 82a420510d63 deducer.py --- a/deducer.py Sun Jan 22 01:09:26 2017 +0100 +++ b/deducer.py Sun Jan 22 01:12:21 2017 +0100 @@ -3,7 +3,7 @@ """ Deduce types for usage observations. -Copyright (C) 2014, 2015, 2016 Paul Boddie +Copyright (C) 2014, 2015, 2016, 2017 Paul Boddie This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software @@ -1991,7 +1991,14 @@ # First attribute accessed at a known position via the accessor. - if base or dynamic_base: + # Static bases support object-relative accesses only. + + if base: + first_method = "relative-object" + + # Dynamic bases support either object- or class-relative accesses. + + elif dynamic_base: first_method = "relative" + (object_relative and "-object" or "") + \ (class_relative and "-class" or "")