From mboxrd@z Thu Jan 1 00:00:00 1970 MIME-Version: 1.0 In-Reply-To: References: <2abfc8db078f981044b3f9e69934279d@quanstro.net> <20090831161633.CD6F75B64@mail.bitblocks.com> <9ab217670908311009k3c8f0b23s52a3fce6239cc47d@mail.gmail.com> Date: Mon, 31 Aug 2009 13:32:30 -0400 Message-ID: <9ab217670908311032x5401e505yb78cb76b79355368@mail.gmail.com> From: "Devon H. O'Dell" To: Fans of the OS Plan 9 from Bell Labs <9fans@9fans.net> Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable Subject: Re: [9fans] Interested in improving networking in Plan 9 Topicbox-Message-UUID: 5d963134-ead5-11e9-9d60-3106f5b1d025 2009/8/31 erik quanstrom : >> 2009/8/31 Bakul Shah : >> > But this is nasty! >> > % cat ndb/dom/'' # same as ndbquery dom '' >> >> No, the nasty part is really that the file should be called `.' and >> the filesystem reserves dot as the reference to the current directory. >> You could probably call the file `dot' or `root' (cat ndb/dom/dot or >> cat ndb/dom/root) as something that shouldn't ever conflict with >> anything else -- but the root of DNS is not an empty string. > > aren't you being a little bit pedantic? =A0quoting is a fact > of life. =A0we don't say that it's evil to need to quote or > transform things in rc or smtp to deal with local requirements. > why would it be evil to quote '.'? =A0and why would be calling > '.' 'root' or 'dot' rather than '' be any less evil? It's (in my opinion) slightly less evil because if(!strlen(name)) seems like a pretty poor way to determine that you're looking at the root zone. It's also more intuitive and easier to document that you're looking at the root than saying `to find root, look for a file named as an empty string'. So: less evil because it makes code more intuitive and it makes documentation easier. Also, I think I should state that I really don't care about implementation as long as it's documented, and that the root is not an empty string. I don't particularly care about quoting at all, and I don't consider that any reason for one method to be more obtuse than another. --dho > - erik > >