[sv-ec] Re: 1858 local:: proposal uploaded

From: Gordon Vreugdenhil <gordonv_at_.....>
Date: Tue Dec 11 2007 - 10:54:33 PST
Arturo Salz wrote:
> I find the repeating of various rules in your proposal to 
> reduce clarity since it isn't clear that you are saying
> "just do local binding".  Are you Ok with the wording that
> I proposed for that aspect in my proposal?
> 
>  
> 
> *I haven’t studied your proposal – only glanced at it. I wrote mine 
> before I saw yours.*
> 
> *I believe you’re proposing the parenthesis form to guide name binding, 
> and I’m not sure there was consensus for that.*


There wasn't objections raised just some questions about whether
both were needed.  I would definitely like both to be available
since requiring the prefix "local::" throughout an inline
constraint can be quite noisy and in some cases there is more
local context than in-target context.

Since there is no semantic issue with both biasings, I don't
see why we couldn't permit both.

If you aren't going to oppose it, I'll do the merge, otherwise
I won't merge but keep mine distinct so the question can be
separated.


I still don't like the longer set of "inner to outer" rules in
the original text and preserved by your proposal.  That description
is just too subject to assumptions that things are different
and I do want it to be crystal clear that there is no
difference.



[...]

> *I agree that the rules above do not contradict the earlier statements. 
> But, I do believe they help summarize things, particularly:*
> 
> * - this.foo   forces foo to bind into the randomize-with object – if 
> foo is not a property of the object, it is an error.*


But I in fact disagree with that.  If "this.foo" doesn't bind into
the target, "this.foo" is resolved as though it were "local::this.foo".
If the inline constraint is not in a class, such a resolution would
be an error but would otherwise denote the local foo.

If you are looking for a way to *force* resolution into the target
object, "local::" already gives you that:
    local::obj.foo

> 
> * - local::foo forces foo to bind into the local scope of the call.*

Exactly.  But that is already a given since local:: would necessarily
bind to the same thing as the prefix of the inline constraint
declaration.  Restating this as a "rule" makes it sound as though
it was special.

> 
> * - local::obj.foo is semantically identical to this.foo (and to the 
> less safe unadorned foo).*

I disagree.  If "this.foo" is not resolved in the inline constraint
declaration, it can resolve locally.  Otherwise you introduce
a disconnect between just "foo" and "this.foo" if the calling
context has a "foo".  "local::" is the only way to force things.

> *I think that having these there are useful. Perhaps I can change the 
> introductory wording*
> 
> *From:*
> 
> Within the in-line constraint, the following rules apply:
> 
> *to:*
> 
>             Given the earlier rules, the following rules can be deduced:


I don't want the word "rules" here at all.  If you insist on having
the list there, I would say,
   "Given these rules, the following behavior is implied:"

The list is not a set of rules -- it is a set of behaviors that
follow from the rules.

Gord.

-- 
--------------------------------------------------------------------
Gordon Vreugdenhil                                503-685-0808
Model Technology (Mentor Graphics)                gordonv@model.com


-- 
This message has been scanned for viruses and
dangerous content by MailScanner, and is
believed to be clean.
Received on Wed Dec 12 17:35:19 2007

This archive was generated by hypermail 2.1.8 : Wed Dec 12 2007 - 17:35:55 PST