On Sep 2, 2013, at 4:41 , Goubier Thierry <thierry.goub...@cea.fr> wrote:
> Le 02/09/2013 16:07, Stéphane Ducasse a écrit : >> what we could do is to not deprecate now the methods? >> Then we can deprecate them when we release 3.0 > > When starting pharo4? That would be perfect :) > > I just noticed that Smalltalk os exist in 1.4 and 2.0. So my code should work > on an old image, isn't it? It would also work on 2.0 and 1.4, no? > > (or something like (Smalltalk respondsTo: #os) ifTrue: [Smalltalk os name]) > > When was Smalltalk>>os introduced ? > > Thierry 3.5 years ago ;) http://forum.world.st/Worth-reading-discussion-on-Smalltalk-vs-SmalltalkImage-td1576291.html#a1576588 It's been included since Pharo 1.1/Squeak 4.1, so it's a reasonable default path. Though, better use Smalltalk os platformName (which should work in all versions since the above mentioned), writing a test for whether #name is the "correct" method to use ala 3.0 would be an interesting exercise since it's also implemented for older returns of Smalltalk os, but with a different meaning. *cough* find a better selector for 3.0? *cough* I think OSPlatform is one of those packages which tries to work on Squeak 3.6 and up, and in that case you still need more fallbacks. Cheers, Henry
signature.asc
Description: Message signed with OpenPGP using GPGMail