Re: [YANG] so many naming scopes
"tom.petch" <cfinss@dial.pipex.com> Tue, 08 January 2008 10:29 UTC
Return-path: <yang-bounces@ietf.org>
Received: from [127.0.0.1] (helo=stiedprmman1.va.neustar.com)
by megatron.ietf.org with esmtp (Exim 4.43)
id 1JCBiU-0002Vo-Rf; Tue, 08 Jan 2008 05:29:54 -0500
Received: from yang by megatron.ietf.org with local (Exim 4.43)
id 1JCBiT-0002K4-5c
for yang-confirm+ok@megatron.ietf.org; Tue, 08 Jan 2008 05:29:53 -0500
Received: from [10.91.34.44] (helo=ietf-mx.ietf.org)
by megatron.ietf.org with esmtp (Exim 4.43) id 1JCBiL-0001Jt-CQ
for yang@ietf.org; Tue, 08 Jan 2008 05:29:45 -0500
Received: from mk-outboundfilter-1.mail.uk.tiscali.com ([212.74.114.37])
by ietf-mx.ietf.org with esmtp (Exim 4.43) id 1JCBiJ-0004e2-Gb
for yang@ietf.org; Tue, 08 Jan 2008 05:29:45 -0500
X-Trace: 14620622/mk-outboundfilter-1.mail.uk.tiscali.com/PIPEX/$MX-ACCEPTED/pipex-infrastructure/62.241.163.6
X-SBRS: None
X-RemoteIP: 62.241.163.6
X-IP-MAIL-FROM: cfinss@dial.pipex.com
X-IP-BHB: Once
X-IronPort-Anti-Spam-Filtered: true
X-IronPort-Anti-Spam-Result: Ao8CAP7egkc+8aMG/2dsb2JhbACpIQ
Received: from astro.systems.pipex.net ([62.241.163.6])
by smtp.pipex.tiscali.co.uk with ESMTP; 08 Jan 2008 10:29:42 +0000
Received: from pc6 (1Cust147.tnt24.lnd4.gbr.da.uu.net [62.188.151.147])
by astro.systems.pipex.net (Postfix) with SMTP id 3917CE000089;
Tue, 8 Jan 2008 10:29:23 +0000 (GMT)
Message-ID: <011a01c851d8$cc8652c0$0601a8c0@pc6>
From: "tom.petch" <cfinss@dial.pipex.com>
To: "Bert Wijnen - IETF" <bertietf@bwijnen.net>,
"Andy Bierman" <ietf@andybierman.com>
References: <NIEJLKBACMDODCGLGOCNKEKPEEAA.bertietf@bwijnen.net>
Subject: Re: [YANG] so many naming scopes
Date: Tue, 8 Jan 2008 09:40:45 +0100
MIME-Version: 1.0
Content-Type: text/plain;
charset="iso-8859-1"
Content-Transfer-Encoding: 7bit
X-Priority: 3
X-MSMail-Priority: Normal
X-Mailer: Microsoft Outlook Express 6.00.2800.1106
X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2800.1106
X-Spam-Score: -100.0 (---------------------------------------------------)
X-Scan-Signature: 5ebbf074524e58e662bc8209a6235027
Cc: yang@ietf.org
X-BeenThere: yang@ietf.org
X-Mailman-Version: 2.1.5
Precedence: list
Reply-To: "tom.petch" <cfinss@dial.pipex.com>
List-Id: YANG modeling Language for NETCONF <yang.ietf.org>
List-Unsubscribe: <https://www1.ietf.org/mailman/listinfo/yang>,
<mailto:yang-request@ietf.org?subject=unsubscribe>
List-Archive: <http://www1.ietf.org/pipermail/yang>
List-Post: <mailto:yang@ietf.org>
List-Help: <mailto:yang-request@ietf.org?subject=help>
List-Subscribe: <https://www1.ietf.org/mailman/listinfo/yang>,
<mailto:yang-request@ietf.org?subject=subscribe>
Errors-To: yang-bounces@ietf.org
----- Original Message ----- From: "Bert Wijnen - IETF" <bertietf@bwijnen.net> To: "Andy Bierman" <ietf@andybierman.com>om>; "Balazs Lengyel" <balazs.lengyel@ericsson.com> Cc: <yang@ietf.org> Sent: Friday, January 04, 2008 1:08 PM Subject: RE: [YANG] so many naming scopes > > Balazs Lengyel wrote: > > > While the use of many naming-scopes is understandable for the compiler > > > is it easy to understand for the reader ? IMHO no. > > > To which Andy responded: > > > That is my concern as well. > > > > As in any engineering decision, we have to weigh the trade-offs. > > How much overall value is lost by forcing DM writers to > > maintain one set of identifiers (using up some of the 63 chars > > of minimum uniqueness), vs. the confusion of having the same > > identifier value mean many different things, even within the same file. > > > > If the language can accept and easily handle it, then maybe we should > allow it to do so and not create CLRs. > A good and smart data-model-developer would/should still do the right > thing and make things as clear as possible for the user/reader of the > data-model. That means that one uses a style of definitions that is > obvious and clear and so would not cause confusion. > Agree absolutely, but, sadly, developers may not be either good or smart or both. And your definition of smart may not be mine, it may be someone who is so clever that they come up with something that is incomprehensible to the mere mortals who inherit what they have produced. A goodly part of my coding has been maintenance, having to reverse engineer the existing language before being able to change it; the best developers produce something that is so simple, so obvious that everything thinks 'I could have done that' - except that they couldn't. The worst developers - who are often very clever - produce something that needs a Ph D in Philosophy to unravel. There are languages where no word is reserved, where the same symbol(word) can be used for label, type, module etc. XML is arguable worse with the ability to start a fresh namespace on alternate lines. These belong in the bin. So, I think that having restraints is a good thing, for the benefit of the good and smart maintainers who have to put up with the output of diabolical developers. The number of discrete naming scopes that can appear in a 200-line module should be severely restricted. Tom Petch > It is similar to using all sorts of short abbreviations/acronyms in names > of variables and such versus spelling out a longer name. The longer name > will make it much more readable/understandable for the new person who > read the module for the first time. That does not mean we must pre-scribe > that short-names/acronyms are not allowed. > > > > > > I like Andy's proposal. > > So I like the underlying reasons, but I am not sure we have to enforce it > in the langauge. > > Bert > > > Balazs > > > > Andy > > > > > > > > > > Phil Shafer wrote: > > >> Andy Bierman writes: > > >>> Yes, of course one naming scope (the term namespace is taken) > > >>> amongst siblings, except nested typedef and grouping names > > >>> cannot mask similar definitions within an ancestor node, > > >>> or globally within the same module. (This part already in the draft.) > > >> > > >> Isn't this dancing on the line of CLR? Where's the logic of saying > > >> "don't do that" when there's really no ambiguity? If I say "leaf foo > > >> { .. } typedef foo { .. }", my use of "type foo" is clear. > > >> Is there a situation where isn't not clear to the compiler > > >> what is meant? Are we trying to get the compiler to enforce > > >> style rules when the language proper doesn't require them? > > >> > > >> Thanks, > > >> Phil > > >> > > >> > > >> _______________________________________________ > > >> YANG mailing list > > >> YANG@ietf.org > > >> https://www1.ietf.org/mailman/listinfo/yang > > > > > > > > > > > _______________________________________________ > > YANG mailing list > > YANG@ietf.org > > https://www1.ietf.org/mailman/listinfo/yang > > > > > > _______________________________________________ > YANG mailing list > YANG@ietf.org > https://www1.ietf.org/mailman/listinfo/yang _______________________________________________ YANG mailing list YANG@ietf.org https://www1.ietf.org/mailman/listinfo/yang
- [YANG] so many naming scopes Andy Bierman
- Re: [YANG] so many naming scopes Martin Bjorklund
- Re: [YANG] so many naming scopes Andy Bierman
- Re: [YANG] so many naming scopes Phil Shafer
- Re: [YANG] so many naming scopes Martin Bjorklund
- Re: [YANG] so many naming scopes Balazs Lengyel
- Re: [YANG] so many naming scopes Andy Bierman
- RE: [YANG] so many naming scopes Bert Wijnen - IETF
- Re: [YANG] so many naming scopes Andy Bierman
- Re: [YANG] so many naming scopes Juergen Schoenwaelder
- Re: [YANG] so many naming scopes Andy Bierman
- Re: [YANG] so many naming scopes tom.petch
- Re: [YANG] so many naming scopes Phil Shafer
- Re: [YANG] so many naming scopes tom.petch
- Re: [YANG] so many naming scopes Andy Bierman
- Re: [YANG] so many naming scopes Phil Shafer
- Re: [YANG] so many naming scopes Juergen Schoenwaelder
- Re: [YANG] so many naming scopes Andy Bierman
- Re: [YANG] so many naming scopes Juergen Schoenwaelder
- Re: [YANG] so many naming scopes Phil Shafer
- Re: [YANG] so many naming scopes Balazs Lengyel
- Re: [YANG] so many naming scopes Juergen Schoenwaelder
- RE: [YANG] so many naming scopes Bert Wijnen - IETF