[Pharo-project] interesting source code inconsistency

Eliot Miranda eliot.miranda at gmail.com
Sun Mar 11 18:36:40 EDT 2012


On Sun, Mar 11, 2012 at 3:33 PM, Eliot Miranda <eliot.miranda at gmail.com>wrote:

> Hi Pavel,
>
>     I presume they are found by the following:
>
> SystemNavigation new browseAllSelect:
> [:m|
>  m literals anySatisfy:
> [:l|
> l isVariableBinding
>  and: [l key isSymbol "avoid class-side methodClass literals"
> and: [(m methodClass bindingOf: l key) isNil]]]]
>
> This could be a "browse unbound", and could be included in release tests
> via e.g.
>
> SystemNavigation>methodsWithUnboundGlobals
> ^self allSelect:
>  [:m|
>  m literals anySatisfy:
>  [:l|
>  l isVariableBinding
>   and: [l key isSymbol "avoid class-side methodClass literals"
>   and: [(m methodClass bindingOf: l key) isNil]]]]
>
> (or whereever Pharo puts browsing queries these days)
>

and I suppose it should exclude Undeclared variables, so this is better:

SystemNavigation new browseAllSelect:
[:m|
m literals anySatisfy:
[:l|
l isVariableBinding
and: [l key isSymbol "avoid class-side methodClass literals"
and: [(m methodClass bindingOf: l key) isNil
and: [(Undeclared includesAssociation: l) not]]]]]


>
> On Sun, Mar 11, 2012 at 10:43 AM, Pavel Krivanek <pavel.krivanek at gmail.com
> > wrote:
>
>> Hi,
>>
>> the method DefaultSettingStyle>>#load includes several obsolete
>> classes (RBProgramNode, RBConfigurableFormatter,
>> RefactoryChangeManager). It is interesting that this inconsistency is
>> not reported by Undeclared nor obsoleteClasses (so release tests are
>> green). The literals array contains associations to nil pointed only
>> from the literal array of this method.
>>
>> http://code.google.com/p/pharo/issues/detail?id=5463
>>
>> Cheers,
>> -- Pavel
>>
>>
>
>
> --
> best,
> Eliot
>
>


-- 
best,
Eliot
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.pharo.org/pipermail/pharo-dev_lists.pharo.org/attachments/20120311/95431ad7/attachment-0001.html>


More information about the Pharo-dev mailing list