About Pragma keyword vs Pragma selector

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

About Pragma keyword vs Pragma selector

stepharo
Color >> gtInspectorColorIn: composite
     <gtInspectorPresentationOrder: 30>

     composite morph
         title: 'Color';
         display: [ BorderedMorph new color: self ]

pragma := (Color >> #gtInspectorColorIn:) pragmas first
pragma arguments
 > 30
pragma keyword
 > #gtInspectorPresentationOrder:


I wonder why pragma returns their selector using keyword and not selector?

Especially since message API uses selector.


Pragma >> message
     "Answer the message of the receiving pragma."

     ^ Message selector: self keyword arguments: self arguments.

Stef


Reply | Threaded
Open this post in threaded view
|

Re: About Pragma keyword vs Pragma selector

stepharo
I would rename

     Pragma>>keyword into Pragma>>selector

     Pragma>>selector into Pragma>>methodSelector
     so like that it is coherent with

Message and method api and with Pragma>>methodClass
Le 13/5/16 à 14:33, stepharo a écrit :

> Color >> gtInspectorColorIn: composite
>     <gtInspectorPresentationOrder: 30>
>
>     composite morph
>         title: 'Color';
>         display: [ BorderedMorph new color: self ]
>
> pragma := (Color >> #gtInspectorColorIn:) pragmas first
> pragma arguments
> > 30
> pragma keyword
> > #gtInspectorPresentationOrder:
>
>
> I wonder why pragma returns their selector using keyword and not
> selector?
>
> Especially since message API uses selector.
>
>
> Pragma >> message
>     "Answer the message of the receiving pragma."
>
>     ^ Message selector: self keyword arguments: self arguments.
>
> Stef
>
>
>


Reply | Threaded
Open this post in threaded view
|

Re: About Pragma keyword vs Pragma selector

Tudor Girba-2
Hi,

I would agree with that. The only thing to take into account is that this can introduce incompatibilities with external libraries, but I do not think this would be much.

Cheers,
Doru


> On May 14, 2016, at 3:03 PM, stepharo <[hidden email]> wrote:
>
> I would rename
>
>    Pragma>>keyword into Pragma>>selector
>
>    Pragma>>selector into Pragma>>methodSelector
>    so like that it is coherent with
>
> Message and method api and with Pragma>>methodClass
> Le 13/5/16 à 14:33, stepharo a écrit :
>> Color >> gtInspectorColorIn: composite
>>    <gtInspectorPresentationOrder: 30>
>>
>>    composite morph
>>        title: 'Color';
>>        display: [ BorderedMorph new color: self ]
>>
>> pragma := (Color >> #gtInspectorColorIn:) pragmas first
>> pragma arguments
>> > 30
>> pragma keyword
>> > #gtInspectorPresentationOrder:
>>
>>
>> I wonder why pragma returns their selector using keyword and not selector?
>>
>> Especially since message API uses selector.
>>
>>
>> Pragma >> message
>>    "Answer the message of the receiving pragma."
>>
>>    ^ Message selector: self keyword arguments: self arguments.
>>
>> Stef
>>
>>
>>
>
>

--
www.tudorgirba.com
www.feenk.com

"What we can governs what we wish."





Reply | Threaded
Open this post in threaded view
|

Re: About Pragma keyword vs Pragma selector

stepharo
we can use deprecation and I do not think that there are that many
usages out there.


Le 14/5/16 à 15:53, Tudor Girba a écrit :

> Hi,
>
> I would agree with that. The only thing to take into account is that this can introduce incompatibilities with external libraries, but I do not think this would be much.
>
> Cheers,
> Doru
>
>
>> On May 14, 2016, at 3:03 PM, stepharo <[hidden email]> wrote:
>>
>> I would rename
>>
>>     Pragma>>keyword into Pragma>>selector
>>
>>     Pragma>>selector into Pragma>>methodSelector
>>     so like that it is coherent with
>>
>> Message and method api and with Pragma>>methodClass
>> Le 13/5/16 à 14:33, stepharo a écrit :
>>> Color >> gtInspectorColorIn: composite
>>>     <gtInspectorPresentationOrder: 30>
>>>
>>>     composite morph
>>>         title: 'Color';
>>>         display: [ BorderedMorph new color: self ]
>>>
>>> pragma := (Color >> #gtInspectorColorIn:) pragmas first
>>> pragma arguments
>>>> 30
>>> pragma keyword
>>>> #gtInspectorPresentationOrder:
>>>
>>> I wonder why pragma returns their selector using keyword and not selector?
>>>
>>> Especially since message API uses selector.
>>>
>>>
>>> Pragma >> message
>>>     "Answer the message of the receiving pragma."
>>>
>>>     ^ Message selector: self keyword arguments: self arguments.
>>>
>>> Stef
>>>
>>>
>>>
>>
> --
> www.tudorgirba.com
> www.feenk.com
>
> "What we can governs what we wish."
>
>
>
>
>
>


Reply | Threaded
Open this post in threaded view
|

Re: About Pragma keyword vs Pragma selector

Tudor Girba-2
Hi,

We can indeed deprecate keyword, but if we change selector to mean the pragma selector instead of method selector, we cannot deprecate that one. But, indeed, I do not think we have many users out there :).

Cheers,
Doru


> On May 15, 2016, at 10:34 AM, stepharo <[hidden email]> wrote:
>
> we can use deprecation and I do not think that there are that many usages out there.
>
>
> Le 14/5/16 à 15:53, Tudor Girba a écrit :
>> Hi,
>>
>> I would agree with that. The only thing to take into account is that this can introduce incompatibilities with external libraries, but I do not think this would be much.
>>
>> Cheers,
>> Doru
>>
>>
>>> On May 14, 2016, at 3:03 PM, stepharo <[hidden email]> wrote:
>>>
>>> I would rename
>>>
>>>    Pragma>>keyword into Pragma>>selector
>>>
>>>    Pragma>>selector into Pragma>>methodSelector
>>>    so like that it is coherent with
>>>
>>> Message and method api and with Pragma>>methodClass
>>> Le 13/5/16 à 14:33, stepharo a écrit :
>>>> Color >> gtInspectorColorIn: composite
>>>>    <gtInspectorPresentationOrder: 30>
>>>>
>>>>    composite morph
>>>>        title: 'Color';
>>>>        display: [ BorderedMorph new color: self ]
>>>>
>>>> pragma := (Color >> #gtInspectorColorIn:) pragmas first
>>>> pragma arguments
>>>>> 30
>>>> pragma keyword
>>>>> #gtInspectorPresentationOrder:
>>>>
>>>> I wonder why pragma returns their selector using keyword and not selector?
>>>>
>>>> Especially since message API uses selector.
>>>>
>>>>
>>>> Pragma >> message
>>>>    "Answer the message of the receiving pragma."
>>>>
>>>>    ^ Message selector: self keyword arguments: self arguments.
>>>>
>>>> Stef
>>>>
>>>>
>>>>
>>>
>> --
>> www.tudorgirba.com
>> www.feenk.com
>>
>> "What we can governs what we wish."
>>
>>
>>
>>
>>
>>
>
>

--
www.tudorgirba.com
www.feenk.com

"Yesterday is a fact.
 Tomorrow is a possibility.
 Today is a challenge."





Reply | Threaded
Open this post in threaded view
|

Re: About Pragma keyword vs Pragma selector

stepharo
indeed :)



Le 15/5/16 à 11:02, Tudor Girba a écrit :

> Hi,
>
> We can indeed deprecate keyword, but if we change selector to mean the pragma selector instead of method selector, we cannot deprecate that one. But, indeed, I do not think we have many users out there :).
>
> Cheers,
> Doru
>
>
>> On May 15, 2016, at 10:34 AM, stepharo <[hidden email]> wrote:
>>
>> we can use deprecation and I do not think that there are that many usages out there.
>>
>>
>> Le 14/5/16 à 15:53, Tudor Girba a écrit :
>>> Hi,
>>>
>>> I would agree with that. The only thing to take into account is that this can introduce incompatibilities with external libraries, but I do not think this would be much.
>>>
>>> Cheers,
>>> Doru
>>>
>>>
>>>> On May 14, 2016, at 3:03 PM, stepharo <[hidden email]> wrote:
>>>>
>>>> I would rename
>>>>
>>>>     Pragma>>keyword into Pragma>>selector
>>>>
>>>>     Pragma>>selector into Pragma>>methodSelector
>>>>     so like that it is coherent with
>>>>
>>>> Message and method api and with Pragma>>methodClass
>>>> Le 13/5/16 à 14:33, stepharo a écrit :
>>>>> Color >> gtInspectorColorIn: composite
>>>>>     <gtInspectorPresentationOrder: 30>
>>>>>
>>>>>     composite morph
>>>>>         title: 'Color';
>>>>>         display: [ BorderedMorph new color: self ]
>>>>>
>>>>> pragma := (Color >> #gtInspectorColorIn:) pragmas first
>>>>> pragma arguments
>>>>>> 30
>>>>> pragma keyword
>>>>>> #gtInspectorPresentationOrder:
>>>>> I wonder why pragma returns their selector using keyword and not selector?
>>>>>
>>>>> Especially since message API uses selector.
>>>>>
>>>>>
>>>>> Pragma >> message
>>>>>     "Answer the message of the receiving pragma."
>>>>>
>>>>>     ^ Message selector: self keyword arguments: self arguments.
>>>>>
>>>>> Stef
>>>>>
>>>>>
>>>>>
>>> --
>>> www.tudorgirba.com
>>> www.feenk.com
>>>
>>> "What we can governs what we wish."
>>>
>>>
>>>
>>>
>>>
>>>
>>
> --
> www.tudorgirba.com
> www.feenk.com
>
> "Yesterday is a fact.
>   Tomorrow is a possibility.
>   Today is a challenge."
>
>
>
>
>
>