Quantcast

Character >> #isAlphabetic clashes with vb-regex

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
18 messages Options
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Character >> #isAlphabetic clashes with vb-regex

Philippe Marschall
Hi

First, sorry for the previous message. Something went wrong there.

Second, this post is about Hyper and not about Swazoo. Sorry for
posting to this list but I know Bruce reads it and I think it's of
general interest for people writing portable code.

HyUrl sends #isAlphabetic to characters and includes its own class
extension for this method. However vb-regex does the same and uses a
different definition. May I suggest to use #hyperIsAlphabetic instead?

Cheers
Philippe

------------------------------------------------------------------------------
SF.Net email is Sponsored by MIX09, March 18-20, 2009 in Las Vegas, Nevada.
The future of the web can't happen without you.  Join us at MIX09 to help
pave the way to the Next Web now. Learn more and register at
http://ad.doubleclick.net/clk;208669438;13503038;i?http://2009.visitmix.com/
_______________________________________________
Swazoo-devel mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/swazoo-devel
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Character >> #isAlphabetic clashes with vb-regex

Paolo Bonzini-2
Philippe Marschall wrote:

> Hi
>
> First, sorry for the previous message. Something went wrong there.
>
> Second, this post is about Hyper and not about Swazoo. Sorry for
> posting to this list but I know Bruce reads it and I think it's of
> general interest for people writing portable code.
>
> HyUrl sends #isAlphabetic to characters and includes its own class
> extension for this method. However vb-regex does the same and uses a
> different definition. May I suggest to use #hyperIsAlphabetic instead?

What's wrong with #isLetter?

Paolo

------------------------------------------------------------------------------
SF.Net email is Sponsored by MIX09, March 18-20, 2009 in Las Vegas, Nevada.
The future of the web can't happen without you.  Join us at MIX09 to help
pave the way to the Next Web now. Learn more and register at
http://ad.doubleclick.net/clk;208669438;13503038;i?http://2009.visitmix.com/
_______________________________________________
Swazoo-devel mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/swazoo-devel
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Character >> #isAlphabetic clashes with vb-regex

Bruce Badger
In reply to this post by Philippe Marschall
On 12/12/2008, Philippe Marschall <[hidden email]> wrote:
>  HyUrl sends #isAlphabetic to characters and includes its own class
>  extension for this method. However vb-regex does the same and uses a
>  different definition. May I suggest to use #hyperIsAlphabetic instead?

I have a few things on my Hyper to-do list.  I'll add this one.

Thanks for the suggestion :-)

--
Make the most of your skills - with OpenSkills
http://www.openskills.org/

------------------------------------------------------------------------------
SF.Net email is Sponsored by MIX09, March 18-20, 2009 in Las Vegas, Nevada.
The future of the web can't happen without you.  Join us at MIX09 to help
pave the way to the Next Web now. Learn more and register at
http://ad.doubleclick.net/clk;208669438;13503038;i?http://2009.visitmix.com/
_______________________________________________
Swazoo-devel mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/swazoo-devel
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Character >> #isAlphabetic clashes with vb-regex

Philippe Marschall
In reply to this post by Paolo Bonzini-2
2008/12/12 Paolo Bonzini <[hidden email]>:

> Philippe Marschall wrote:
>> Hi
>>
>> First, sorry for the previous message. Something went wrong there.
>>
>> Second, this post is about Hyper and not about Swazoo. Sorry for
>> posting to this list but I know Bruce reads it and I think it's of
>> general interest for people writing portable code.
>>
>> HyUrl sends #isAlphabetic to characters and includes its own class
>> extension for this method. However vb-regex does the same and uses a
>> different definition. May I suggest to use #hyperIsAlphabetic instead?
>
> What's wrong with #isLetter?

On Squeak it returns true for letters outside of ASCII.

Cheers
Philippe

------------------------------------------------------------------------------
SF.Net email is Sponsored by MIX09, March 18-20, 2009 in Las Vegas, Nevada.
The future of the web can't happen without you.  Join us at MIX09 to help
pave the way to the Next Web now. Learn more and register at
http://ad.doubleclick.net/clk;208669438;13503038;i?http://2009.visitmix.com/
_______________________________________________
Swazoo-devel mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/swazoo-devel
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Character >> #isAlphabetic clashes with vb-regex

Bruce Badger
On 12/12/2008, Philippe Marschall <[hidden email]> wrote:

> 2008/12/12 Paolo Bonzini <[hidden email]>:
>
> > Philippe Marschall wrote:
>  >> HyUrl sends #isAlphabetic to characters and includes its own class
>  >> extension for this method. However vb-regex does the same and uses a
>  >> different definition. May I suggest to use #hyperIsAlphabetic instead?
>  >
>  > What's wrong with #isLetter?
>
> On Squeak it returns true for letters outside of ASCII.

Don't we need >>isASCIIAphabetic  (or >>isASCIILetter), then, to be explicit?

--
Make the most of your skills - with OpenSkills
http://www.openskills.org/

------------------------------------------------------------------------------
SF.Net email is Sponsored by MIX09, March 18-20, 2009 in Las Vegas, Nevada.
The future of the web can't happen without you.  Join us at MIX09 to help
pave the way to the Next Web now. Learn more and register at
http://ad.doubleclick.net/clk;208669438;13503038;i?http://2009.visitmix.com/
_______________________________________________
Swazoo-devel mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/swazoo-devel
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Character >> #isAlphabetic clashes with vb-regex

Philippe Marschall
2008/12/12, Bruce Badger <[hidden email]>:

> On 12/12/2008, Philippe Marschall <[hidden email]> wrote:
>> 2008/12/12 Paolo Bonzini <[hidden email]>:
>>
>> > Philippe Marschall wrote:
>>  >> HyUrl sends #isAlphabetic to characters and includes its own class
>>  >> extension for this method. However vb-regex does the same and uses a
>>  >> different definition. May I suggest to use #hyperIsAlphabetic instead?
>>  >
>>  > What's wrong with #isLetter?
>>
>> On Squeak it returns true for letters outside of ASCII.
>
> Don't we need >>isASCIIAphabetic  (or >>isASCIILetter), then, to be
> explicit?

And probably even #hyperIsASCIIAphabetic to avoid clashes. But since
it has only one sender it might be less trouble to simply inline it.

Cheers
Philippe

------------------------------------------------------------------------------
SF.Net email is Sponsored by MIX09, March 18-20, 2009 in Las Vegas, Nevada.
The future of the web can't happen without you.  Join us at MIX09 to help
pave the way to the Next Web now. Learn more and register at
http://ad.doubleclick.net/clk;208669438;13503038;i?http://2009.visitmix.com/
_______________________________________________
Swazoo-devel mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/swazoo-devel
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Character >> #isAlphabetic clashes with vb-regex

Philippe Marschall
In reply to this post by Philippe Marschall
2008/12/12, Philippe Marschall <[hidden email]>:

> Hi
>
> First, sorry for the previous message. Something went wrong there.
>
> Second, this post is about Hyper and not about Swazoo. Sorry for
> posting to this list but I know Bruce reads it and I think it's of
> general interest for people writing portable code.
>
> HyUrl sends #isAlphabetic to characters and includes its own class
> extension for this method. However vb-regex does the same and uses a
> different definition. May I suggest to use #hyperIsAlphabetic instead?

There are some more issues I came across, in Squeak the following
methods are not implemented:
- #entityOctetsUpToEnd
- #initialContext
- #on:new:

Additionally you shouldn't use #match: and 16r7f doesn't work as a
literal in Squeak.

Cheers
Philippe

------------------------------------------------------------------------------
SF.Net email is Sponsored by MIX09, March 18-20, 2009 in Las Vegas, Nevada.
The future of the web can't happen without you.  Join us at MIX09 to help
pave the way to the Next Web now. Learn more and register at
http://ad.doubleclick.net/clk;208669438;13503038;i?http://2009.visitmix.com/
_______________________________________________
Swazoo-devel mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/swazoo-devel
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Character >> #isAlphabetic clashes with vb-regex

Bruce Badger
On 12/12/2008, Philippe Marschall <[hidden email]> wrote:

>  > HyUrl sends #isAlphabetic to characters and includes its own class
>  > extension for this method. However vb-regex does the same and uses a
>  > different definition. May I suggest to use #hyperIsAlphabetic instead?
>
>
> There are some more issues I came across, in Squeak the following
>  methods are not implemented:
>  - #entityOctetsUpToEnd
>  - #initialContext
>  - #on:new:
>
>  Additionally you shouldn't use #match: and 16r7f doesn't work as a
>  literal in Squeak.

On the first point, isAlphabetic is implemented on Character in a base
VisualWorks image and used that in a recent change to Hyper.  I've not
checked this version of Hyper out in GemStone yet ... and there I see
that there is *no* implementation of isAlphabetic on Character.  So,
yes I need to do something about this ... but (;-)) I deny having
created a Hyper specific extension to the Character class.

I'm behind on a number of things Philippe (Life. Don't talk to me
about life) but getting the latest version of Hyper running in
GemStone is important for OpenSkills and I've promised this for Dale
from GemStone, and now you need things addressing too.  So I'll look
at this very soon.

Thanks,
    Bruce
--
Make the most of your skills - with OpenSkills
http://www.openskills.org/

------------------------------------------------------------------------------
SF.Net email is Sponsored by MIX09, March 18-20, 2009 in Las Vegas, Nevada.
The future of the web can't happen without you.  Join us at MIX09 to help
pave the way to the Next Web now. Learn more and register at
http://ad.doubleclick.net/clk;208669438;13503038;i?http://2009.visitmix.com/
_______________________________________________
Swazoo-devel mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/swazoo-devel
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Character >> #isAlphabetic clashes with vb-regex

Bruce Badger
Philippe & Co.,

To address the >>isAlphabetic issue I have added a new class to Hyper
which is responsible for knowing the constants defined in RFC 2616
(e.g. ALPHA (c.f. RFC 2616 pp 2.2)).  This means that in the latest
version of Hyper, to be released as soon as I have run through all the
tests and become happy that all is well with my code, will no longer
use >>isAlphabetic at all.

There you go,
    Bruce
--
Make the most of your skills - with OpenSkills
http://www.openskills.org/

------------------------------------------------------------------------------
_______________________________________________
Swazoo-devel mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/swazoo-devel
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Character >> #isAlphabetic clashes with vb-regex

Philippe Marschall
In reply to this post by Philippe Marschall
2008/12/12, Philippe Marschall <[hidden email]>:

> Hi
>
> First, sorry for the previous message. Something went wrong there.
>
> Second, this post is about Hyper and not about Swazoo. Sorry for
> posting to this list but I know Bruce reads it and I think it's of
> general interest for people writing portable code.
>
> HyUrl sends #isAlphabetic to characters and includes its own class
> extension for this method. However vb-regex does the same and uses a
> different definition. May I suggest to use #hyperIsAlphabetic instead?

There is a second problem with Hyper, it sends #readIntegerFrom:radix:
 to Number with is not present in Squeak.

Cheers
Philippe

------------------------------------------------------------------------------
_______________________________________________
Swazoo-devel mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/swazoo-devel
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Character >> #isAlphabetic clashes with vb-regex

Bruce Badger
On 01/01/2009, Philippe Marschall <[hidden email]> wrote:
> There is a second problem with Hyper, it sends #readIntegerFrom:radix:
>   to Number with is not present in Squeak.

The latest version uses:

  SpEnvironment readIntegerFrom: hexDigitsReadStream radix: 16.

So Sport should absorb that difference for Hyper in this case - at
least in the version just published to the public Store.

All the best,
    Bruce
--
Make the most of your skills - with OpenSkills
http://www.openskills.org/

------------------------------------------------------------------------------
_______________________________________________
Swazoo-devel mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/swazoo-devel
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Character >> #isAlphabetic clashes with vb-regex

Philippe Marschall
2009/1/2, Bruce Badger <[hidden email]>:

> On 01/01/2009, Philippe Marschall <[hidden email]> wrote:
>> There is a second problem with Hyper, it sends #readIntegerFrom:radix:
>>   to Number with is not present in Squeak.
>
> The latest version uses:
>
>   SpEnvironment readIntegerFrom: hexDigitsReadStream radix: 16.
>
> So Sport should absorb that difference for Hyper in this case - at
> least in the version just published to the public Store.

Is there any mechanism in place for getting this to all the other
supported dialects and for finding out which dialect supports which
version of SPort?

Also are there any tests for SPort?

Cheers
Philippe

------------------------------------------------------------------------------
_______________________________________________
Swazoo-devel mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/swazoo-devel
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Character >> #isAlphabetic clashes with vb-regex

Bruce Badger
On 02/01/2009, Philippe Marschall <[hidden email]> wrote:
>
> Is there any mechanism in place for getting this to all the other
>  supported dialects and for finding out which dialect supports which
>  version of SPort?
>
>  Also are there any tests for SPort?

The information about dialects and who does what is here:
  http://wiki.openskills.org/OpenSkills/Sport

There are indeed Sport SUnit tests.  Leandro Caniglia did the work to
get these set up, and you can see them in the VW implimentation.

As Sport is cross dialect, the preferred discussion forum for Sport
issues is cls.

All the best,
    Bruce
--
Make the most of your skills - with OpenSkills
http://www.openskills.org/

------------------------------------------------------------------------------
_______________________________________________
Swazoo-devel mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/swazoo-devel
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Character >> #isAlphabetic clashes with vb-regex

Philippe Marschall
2009/1/2, Bruce Badger <[hidden email]>:

> On 02/01/2009, Philippe Marschall <[hidden email]> wrote:
>>
>> Is there any mechanism in place for getting this to all the other
>>  supported dialects and for finding out which dialect supports which
>>  version of SPort?
>>
>>  Also are there any tests for SPort?
>
> The information about dialects and who does what is here:
>   http://wiki.openskills.org/OpenSkills/Sport

Sorry but I can't find any information there about the status of the
implementation on each platform.

> There are indeed Sport SUnit tests.  Leandro Caniglia did the work to
> get these set up, and you can see them in the VW implimentation.

"It's done in VW" doesn't really help me since I'm on Squeak. If I
have to do all the porting and implantation myself this gives me the
impression that the only really supported platform is VW.

Cheers
Philippe

------------------------------------------------------------------------------
_______________________________________________
Swazoo-devel mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/swazoo-devel
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Character >> #isAlphabetic clashes with vb-regex

Bruce Badger
On 02/01/2009, Philippe Marschall <[hidden email]> wrote:
>  > The information about dialects and who does what is here:
>  >   http://wiki.openskills.org/OpenSkills/Sport
> Sorry but I can't find any information there about the status of the
>  implementation on each platform.

You'd check the respective repository, e.g. the public Store.

>  > There are indeed Sport SUnit tests.  Leandro Caniglia did the work to
>  > get these set up, and you can see them in the VW implimentation.
> "It's done in VW" doesn't really help me since I'm on Squeak. If I
>  have to do all the porting and implantation myself this gives me the
>  impression that the only really supported platform is VW.

Each implementation of Sport is distinct and the listed individual
drives it.  The tests set up by Leandro were done in Visual Smalltalk.
 I implemented them in Visual Works.  The named individual would do it
for each platform.

Sport is not a 'supported product'.  It's a project which has been of
value to many, and I hope it will be for you too.  I'm sorry to hear
you are having problems on Squeak.  Perhaps we should wait to hear
what Janko has to say about the current status of the Squeak
implementation.

All the best,
    Bruce

--
Make the most of your skills - with OpenSkills
http://www.openskills.org/

------------------------------------------------------------------------------
_______________________________________________
Swazoo-devel mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/swazoo-devel
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Character >> #isAlphabetic clashes with vb-regex

Janko Mivšek
Bruce Badger wrote:

> On 02/01/2009, Philippe Marschall <[hidden email]> wrote:

>>  > The information about dialects and who does what is here:
>>  >   http://wiki.openskills.org/OpenSkills/Sport

>> Sorry but I can't find any information there about the status of the
>>  implementation on each platform.

> You'd check the respective repository, e.g. the public Store.

>>  > There are indeed Sport SUnit tests.  Leandro Caniglia did the work to
>>  > get these set up, and you can see them in the VW implimentation.
>> "It's done in VW" doesn't really help me since I'm on Squeak. If I
>>  have to do all the porting and implantation myself this gives me the
>>  impression that the only really supported platform is VW.

> Each implementation of Sport is distinct and the listed individual
> drives it.  The tests set up by Leandro were done in Visual Smalltalk.
>  I implemented them in Visual Works.  The named individual would do it
> for each platform.

> Sport is not a 'supported product'.  It's a project which has been of
> value to many, and I hope it will be for you too.  I'm sorry to hear
> you are having problems on Squeak.  Perhaps we should wait to hear
> what Janko has to say about the current status of the Squeak
> implementation.

Squeak port is based on VW one from two years ago or so. I'm not aware
of any Sport changes on VW in that time. Also, because Sport is now
ported to almost all Smalltalks, any change must be much more carefully
planned and announced. Only that way it has a chance to be successfully
propagated around all ports. And if I understand correctly, in current
case there is only one method in question? If so, this is surely not a
reason big enough to start such upgrade. It is better just to extend
this method in your package.

Best regards
Janko



--
Janko Mivšek
AIDA/Web
Smalltalk Web Application Server
http://www.aidaweb.si

------------------------------------------------------------------------------
_______________________________________________
Swazoo-devel mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/swazoo-devel
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Character >> #isAlphabetic clashes with vb-regex

Bruce Badger
On 02/01/2009, Janko Mivšek <[hidden email]> wrote:
> And if I understand correctly, in current
>  case there is only one method in question? If so, this is surely not a
>  reason big enough to start such upgrade. It is better just to extend
>  this method in your package.

Actually, the >>isAlphabetic thing is addressed in Hyper (just as you
suggest), rather than by adding anything to Sport.

One thing I would like to add to Sport is UDP socket facilities,
specifically for Syslog.   But that's another story and something I'll
discuss on cls when I have my act together.

Thanks for responding Janko.

All the best,
    Bruce
--
Make the most of your skills - with OpenSkills
http://www.openskills.org/
------------------------------------------------------------------------------
_______________________________________________
Swazoo-devel mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/swazoo-devel
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Character >> #isAlphabetic clashes with vb-regex

Philippe Marschall
In reply to this post by Janko Mivšek
2009/1/2, Janko Mivšek <[hidden email]>:

> Bruce Badger wrote:
>
>> On 02/01/2009, Philippe Marschall <[hidden email]> wrote:
>
>>>  > The information about dialects and who does what is here:
>>>  >   http://wiki.openskills.org/OpenSkills/Sport
>
>>> Sorry but I can't find any information there about the status of the
>>>  implementation on each platform.
>
>> You'd check the respective repository, e.g. the public Store.
>
>>>  > There are indeed Sport SUnit tests.  Leandro Caniglia did the work to
>>>  > get these set up, and you can see them in the VW implimentation.
>>> "It's done in VW" doesn't really help me since I'm on Squeak. If I
>>>  have to do all the porting and implantation myself this gives me the
>>>  impression that the only really supported platform is VW.
>
>> Each implementation of Sport is distinct and the listed individual
>> drives it.  The tests set up by Leandro were done in Visual Smalltalk.
>>  I implemented them in Visual Works.  The named individual would do it
>> for each platform.
>
>> Sport is not a 'supported product'.  It's a project which has been of
>> value to many, and I hope it will be for you too.  I'm sorry to hear
>> you are having problems on Squeak.  Perhaps we should wait to hear
>> what Janko has to say about the current status of the Squeak
>> implementation.
>
> Squeak port is based on VW one from two years ago or so. I'm not aware
> of any Sport changes on VW in that time. Also, because Sport is now
> ported to almost all Smalltalks, any change must be much more carefully
> planned and announced. Only that way it has a chance to be successfully
> propagated around all ports. And if I understand correctly, in current
> case there is only one method in question?

No, there are five methods missing that I know of not counting the
methods that are there but not implemented which are about six
additional methods. The fact that even you are unaware of this
highlights the seriousness of the problem. Without a specification and
tests nobody can be sure what should be implemented, what is there,
what is missing, what works and doesn't. If you have to look at the
SPort of each platform to find out what is supported and what isn't
you can as well just ignore SPort and use the native classes, it's the
same effort.

> If so, this is surely not a
> reason big enough to start such upgrade. It is better just to extend
> this method in your package.

I hope you don't suggest I should fix SPort.

Cheers
Philippe
------------------------------------------------------------------------------
_______________________________________________
Swazoo-devel mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/swazoo-devel
Loading...