On Wed, 12 Jan 2005 10:16:14 -0800, Guido van Rossum <gvanrossum at gmail.com> wrote: > But now, since I am still in favor of automatic "combined" adaptation > *as a last resort*, I ask you to consider that Python is not C++, and > that perhaps we can make the experience in Python better than it was > in C++. Perhaps allowing more control over when automatic adaptation > is acceptable? > > For example, inteface B (or perhaps this should be a property of the > adapter for B->C?) might be marked so as to allow or disallow its > consideration when looking for multi-step adaptations. We could even > make the default "don't consider", so only people who have to deal > with the multiple A's and/or multiple C's all adaptable via the same B > could save themselves some typing by turning it on. +1. BTW, I _do_ use adaptation, including the 'lossy' one described in this scenario (where the mapping is imperfect, or incomplete). So having some way to tell the adaptation framework that a particular adapter is not suited to use in a transitive chain is a good thing IMHO. Generically speaking, anything that puts some control on the hands of the programmer - as long it does not stand in the way between him and the problem - is good. -- Carlos Ribeiro Consultoria em Projetos blog: http://rascunhosrotos.blogspot.com blog: http://pythonnotes.blogspot.com mail: carribeiro at gmail.com mail: carribeiro at yahoo.com
RetroSearch is an open source project built by @garambo | Open a GitHub Issue
Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo
HTML:
3.2
| Encoding:
UTF-8
| Version:
0.7.4