[squeak-dev] Environments: Import order

Chris Muller asqueaker at gmail.com
Fri Dec 20 21:35:57 UTC 2013


Well, it's backward from how name-resolutions works in other languages
like Java, isn't it?

On Fri, Dec 20, 2013 at 3:03 PM, Frank Shearar <frank.shearar at gmail.com> wrote:
> On 20 December 2013 20:40, Chris Muller <asqueaker at gmail.com> wrote:
>> One thing I just noticed is that the #import... methods on Environment
>> seem to chain the imports in order they are added.  This means the
>> last-added is first-searched when resolving names.
>>
>> Seems like first import should be first-searched...?
>
> I think the behaviour's the correct one: adding imports is like
> wrapping a present in layers of paper: the last added layer/import is
> the outermost layer.
>
> frank
>


More information about the Squeak-dev mailing list