I've been on vacation and forgot to check if you answered anyway :)
David, good to hear the patch feels useful to you! I will finish it in
a generic way and post it here in no time. Although there are two more
cases in Java I do not know how to deal with, we'll probably have to
discuss the topic as a next step.
On Wed, Mar 13, 2013 at 5:56 AM, Eric M. Ludlam <eric@...> wrote:
> On 03/12/2013 04:43 PM, David Engster wrote:
>>
>> Vladimir Kazanov writes:
th>>>
>>> Patch included adds static and non-static context separation in class
>>> methods. It changes semantic-analyze-possible-completions-default, and
>>> should work for both Java and Cpp, although I am not any good at the
>>> latter. All the tests pass nicely, I consider this being a good sign.
>>> :)
>>>
>>> I have also added one more unit test file (testjavastatic.java) for
>>> all the tests on the topic. This patch is just a start, as there are
>>> at least two more situations, where completion should be more precise
>>> in making this separation.
>>>
>>> As always, comments and ideas for improvements are welcome.
>>
>>
>> Vladimir,
>>
>> I just stumbled upon this while browsing through the archive. Sorry for
>> not coming back to this earlier.
>>
>> I tested your patch with a C++ example and it worked like a charm. I
>> also think that the 'static' concept is generic enough to make sense
>> putting it in the default implementation of
>> analyze-possible-completions. So unless Eric disagrees, I see no reason
>> to not apply this.
>
>
> Static is a generic concept in semantic, so it seems like a fine idea to me.
>
> For the patch, it would be good to use semantic-tag-static-p which is an
> overloadable function. If the default impl doesn't work for this case, we
> should update the java support files to overload this to work correctly.
>
> Thanks for finding this David. I usually tag things I need to reply to, but
> this one got lost. Sorry Vladimir.
>
> Thanks!
> Eric
>
--
Yours sincerely,
Vladimir Kazanov
--
С уважением,
Владимир Казанов
|