Symbol>>#value:

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
8 messages Options
Reply | Threaded
Open this post in threaded view
|

Symbol>>#value:

Sean P. DeNigris
Administrator
When I "git clone https://github.com/NicolasPetton/amber.git", I get a version of Amber with a Symbol class that implements #value:, which I use extensively in my imported code (e.g. ... collect: #name). But when I "amber init", the class is not there. What's going on here?
Cheers,
Sean
Reply | Threaded
Open this post in threaded view
|

Re: Symbol>>#value:

Herby Vojčík
NicolasPetton/amber.git is not an official address of amber, it's amber-smalltalk/amber.git.

The aforementioned one is probably not updated for a long time...

Herby

Sean P. DeNigris wrote:

> When I "git clone https://github.com/NicolasPetton/amber.git", I get a
> version of Amber with a Symbol class that implements #value:, which I use
> extensively in my imported code (e.g. ... collect: #name). But when I "amber
> init", the class is not there. What's going on here?
>
>
>
> -----
> Cheers,
> Sean
> --
> View this message in context: http://forum.world.st/Symbol-value-tp4754932.html
> Sent from the Amber Smalltalk mailing list archive at Nabble.com.
>

--
You received this message because you are subscribed to the Google Groups "amber-lang" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
For more options, visit https://groups.google.com/d/optout.
Reply | Threaded
Open this post in threaded view
|

Re: Symbol>>#value:

Sean P. DeNigris
Administrator
Herby Vojčík wrote
NicolasPetton/amber.git is not an official address of amber
Ah, thanks... must've found some old instructions
Cheers,
Sean
Reply | Threaded
Open this post in threaded view
|

Re: Symbol>>#value:

Sean P. DeNigris
Administrator
In reply to this post by Sean P. DeNigris
Sean P. DeNigris wrote
when I "amber init", the class [Symbol that implements #value:, which I use extensively in my imported code (e.g. ... collect: #name)] is not there....
Okay, I see Symbol has been removed in 0.12.4 per https://github.com/amber-smalltalk/amber/blob/master/API-CHANGES.txt . This undoes https://github.com/amber-smalltalk/amber/issues/116

Should we implement
  value: anObject
    ^ anObject perform: self
on String now?

"aCollection collect: #name" seems like a nice/common idiom...
Cheers,
Sean
Reply | Threaded
Open this post in threaded view
|

Re: Symbol>>#value:

Sean P. DeNigris
Administrator
Sean P. DeNigris wrote
Should we implement #value:... on String now?
Bummer...
  String>>#value: aUTFCharCode
        <return String.fromCharCode(aUTFCharCode);>

What's the rationale behind removing Symbol? I see it in the change log, but don't see an issue/discussion. String seems to have a lot of (in this case conflicting) responsibilities now - Character, String, and Symbol.
Cheers,
Sean
Reply | Threaded
Open this post in threaded view
|

Re: Symbol>>#value:

Herby Vojčík
In reply to this post by Sean P. DeNigris
It was long ago, so I do not remember the details. JavaScript strings _are_ essentially Symbols - they behave as if there was only one string with same contebts. Also, it would make model simpler.

As for the existing method String>>value:, I don't see why it is there, it may make sense on the class-side, bjt not on the instance side... and #value: performing the selector is really handy and used in many Smalltalks, so I would say make an issue foe removing the old one to make place for thr new one.

Herby

"Sean P. DeNigris" <[hidden email]>napísal/a:

>Sean P. DeNigris wrote
>> Should we implement #value:... on String now?
>
>Bummer...
>  String>>#value: aUTFCharCode
> <return String.fromCharCode(aUTFCharCode);>
>
>What's the rationale behind removing Symbol? I see it in the change log, but
>don't see an issue/discussion. String seems to have a lot of (in this case
>conflicting) responsibilities now - Character, String, and Symbol.
>
>
>
>-----
>Cheers,
>Sean
>--
>View this message in context: http://forum.world.st/Symbol-value-tp4754932p4755031.html
>Sent from the Amber Smalltalk mailing list archive at Nabble.com.
>
>--
>You received this message because you are subscribed to the Google Groups "amber-lang" group.
>To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
>For more options, visit https://groups.google.com/d/optout.

--
You received this message because you are subscribed to the Google Groups "amber-lang" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
For more options, visit https://groups.google.com/d/optout.
Reply | Threaded
Open this post in threaded view
|

Re: Symbol>>#value:

Nicolas Petton

Yes, it would make sense.

Sean, can you add an issue? (or a PR :p)

Nico

On Apr 17, 2014 9:51 AM, "Herby Vojčík" <[hidden email]> wrote:
It was long ago, so I do not remember the details. JavaScript strings _are_ essentially Symbols - they behave as if there was only one string with same contebts. Also, it would make model simpler.

As for the existing method String>>value:, I don't see why it is there, it may make sense on the class-side, bjt not on the instance side... and #value: performing the selector is really handy and used in many Smalltalks, so I would say make an issue foe removing the old one to make place for thr new one.

Herby

"Sean P. DeNigris" <[hidden email]>napísal/a:

>Sean P. DeNigris wrote
>> Should we implement #value:... on String now?
>
>Bummer...
>  String>>#value: aUTFCharCode
>       <return String.fromCharCode(aUTFCharCode);>
>
>What's the rationale behind removing Symbol? I see it in the change log, but
>don't see an issue/discussion. String seems to have a lot of (in this case
>conflicting) responsibilities now - Character, String, and Symbol.
>
>
>
>-----
>Cheers,
>Sean
>--
>View this message in context: http://forum.world.st/Symbol-value-tp4754932p4755031.html
>Sent from the Amber Smalltalk mailing list archive at Nabble.com.
>
>--
>You received this message because you are subscribed to the Google Groups "amber-lang" group.
>To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
>For more options, visit https://groups.google.com/d/optout.

--
You received this message because you are subscribed to the Google Groups "amber-lang" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
For more options, visit https://groups.google.com/d/optout.

--
You received this message because you are subscribed to the Google Groups "amber-lang" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
For more options, visit https://groups.google.com/d/optout.
Reply | Threaded
Open this post in threaded view
|

Re: Symbol>>#value:

Sean P. DeNigris
Administrator