[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Reply to: [list | sender only]
Re: Draft CIF2 standard available
- Subject: Re: Draft CIF2 standard available
- From: "Bollinger, John C" <John.Bollinger@xxxxxxxxxx>
- Date: Wed, 7 Apr 2010 09:35:56 -0500
- Accept-Language: en-US
- acceptlanguage: en-US
Imagine my surprise at returning to this list after a several-year hiatus (involving two job changes and an interstate relocation) just in time to find a call for public comment on a new CIF standard. I hope I$B!G(Bm in time, at least. I see that no public discussion has proceeded from James$B!G(Bs solicitation, but I suppose that follows from many of the usual voices here having been involved in the DDLm working group that hammered out the draft in the first place.
I have several comments and questions about the draft. Many are more editorial than technical, so I hope you will indulge me there. All comments are based on the February 18, 2010 draft.
1) The convention used in the specification for expressing characters by hexadecimal code point value is readily enough interpreted (at least for an XML initiate such as myself), but it is nowhere defined, and I have not seen this exact convention before. Perhaps it is common in DDLm or STAR space, but I don$B!G(Bt think it a safe assumption that consumers of the spec will be familiar with those areas. Since CIF2 uses Unicode, I suggest characters be expressed instead according to Unicode convention; for example, $B!H(BU+0020$B!I(B instead of $B!H(B#x20$B!I(B. If the present convention is retained then it should be defined in the text.
2) The reference to $B!H(BUNICODE Code Page 0$B!I(B is meaningless as far as I am aware. I have never before seen the term $B!H(Bcode page$B!I(B applied in this context. It would be clearer to refer explicitly to the first 127 characters of Unicode, or, in more technically precise terms, the characters having Unicode code points 0 through 7E(hex). (Or was the omission of U+007F from the definition of ASCII characters accidental?)
3) Depending on how standardesque one wants to be, it might be appropriate to use the ISO name for the $B!H(BLatin-1$B!I(B character set, $B!H(BISO-8859-1$B!I(B. (You might also want to specify ISO-10646 (+- some revision) for Unicode, but in that case there are some small, but non-trivial distinctions.)
4a) I do not understand the meaning of the sentence $B!H(BThe lexical characters of CIF2 are restricted to the 7 bit ASCII range [$B!D(B].$B!I(B That is to say, I think I understand the intent, but it$B!G(Bs different from what the sentence appears on the surface to say, which is that a lexer for CIF2 need only deal with 7-bit ASCII characters, just like one for CIF1. This is false if the CIF contains non-ASCII characters (anywhere), for the UTF-8 encodings of all other characters use bytes that are not mapped to ASCII characters (i.e. they have the most significant bit set).
4b) It is debatable whether $B!H(Bthis enables faster parsing since one can defer UTF-8 decoding to later.$B!I(B I don$B!G(Bt think it$B!G(Bs useful to have that debate now, but I do think that that rationale is out of place in the $B!H(BTerminology$B!I(B section. It would be better placed with change 2.
5) As far as I know, the local convention for record termination is nowhere $B!H(Barchitecture dependent$B!I(B though it certainly is dependent on other aspects of the local computing environment.
6) I presume that it is not intended to refuse to recognize the Unicode line separator and / or paragraph separator characters as newline *in present or future environments where that is an accepted local convention*.
7) I find it unappealing and unpersuasive to justify the exclusion of some characters from syntactic significance based on their *rendering*. This is not to say that I expect or want characters U+201C and U+201D to be syntactically significant as opening and closing double quotation marks, or any similar thing. I do not. I would rather see the whole rationale omitted (at least here). If it is believed important to include reasoning, here, for this decision, then I think minimizing the syntactic complexity of the language is a much stronger justification.
8) With respect to the claim that $B!H(BApplications built on the CIF2 standard will be able to process CIF1 data files,$B!I(B is this a constraint on CIF2 applications, or an assertion about the CIF2 format? If the former, then I think it out of order (no matter how likely it is to be true). If the latter, then it is incorrect, for CIF2, as specified, is not 100% backwards compatible with CIF1.
9) What is the expected CIF version for a CIF that does not specify the CIF2 version comment? Is the specification saying that such a file does not conform to CIF2? As a practical matter (probably not appropriate for inclusion in the spec) what is the expectation for application behavior when presented with such a CIF?
10) I am very pleased with CIF2$B!G(Bs extension of character repertoire to the full Unicode set. The section header and text express an unfortunate comingling of the concepts of Unicode and UTF-8, however. These are distinct concepts: the former is a coded character set, mapping characters to numeric code points; the latter is one of several schemes commonly used to encode Unicode code points as byte sequences. The contents of a CIF are thus *Unicode* characters, encoded via UTF-8 (not $B!H(BUTF-8 characters$B!I(B).
11) Although it probably doesn$B!G(Bt belong in the format specification, it would be useful to know whether the special codes for expressing certain non-ASCII characters in CIF1 values are expected to be supported by CIF2 applications as well (in addition to the ability to include all those characters directly).
12) I applaud lifting the artificial restriction on data name lengths. It has always seemed backward to me that CIF 1.1 restricts data name lengths to those definable in a DDL1 dictionary.
13) Is it really appropriate in specifying the CIF *format* to document restrictions imposed by DDLm (or any other DDL) on *dictionaries*? Especially in such detail? These are characteristics of particular dictionaries, not of CIF itself, and they are relevant only to dictionary writers, who need to be intimately familiar with their chosen DDL anyway.
14) Is the text $B!H(BA whitespace$B!>(Bdelimited string cannot exactly match any STAR keyword, loop_ global_ save_* stop_ data_* [$B!D(B],$B!I(B especially the phrase $B!H(Bexactly match,$B!I(B intended to imply case-sensitive matching? That would be at variance with CIF1.
15) What is the rationale for changing the interpretation of single-quoted and double-quoted strings relative to CIF1? I$B!G(Bm talking about forbidding these values to contain the delimiter (even when it is not followed by whitespace). Yes, CIF1$B!G(Bs provision for such values may be surprising to newcomers, and yes, it makes CIF1 a little trickier to parse, but CIF1 parsers already handle it, and experienced CIF users already know it. This appears to be CIF2$B!G(Bs principal departure from backwards compatibility, and I simply don$B!G(Bt see why it is necessary. Full (or at least better) backwards compatibility would be VERY VALUABLE. Changing it now will produce unnecessary confusion and make CIF parsing even trickier (not easier) because both variants will need to be accommodated.
16) This is admittedly a quibble, but the sentence $B!H(BA list is an ordered set$B!I(B is susceptible to misinterpretation. The examples indicate that it is not intended that a list must have the set property of not containing duplicate elements. Perhaps $B!H(Bsequence$B!I(B would be an apt substitute for $B!H(Bordered set$B!I(B.
17) Is whitespace allowed between the opening(closing) bracket of a list and its first(last) element, or only to separate elements?
18) If $B!H(Bthere is implicit line joining, and the newline has no meaning with regard to List values$B!I(B then are $B!H(B\n;$B!I(B-delimited text blocks forbidden as list elements?
19) If $B!H(Ba Table is an unordered set$B!I(B then what are its elements? If they are name-value pairs (as the text seems to indicate), then wouldn$B!G(Bt that mean the same name could appear multiple times with different values? I think it would be helpful here to separate the data model for this type from its syntactic representation. A Table *is* a set of labels, each with an associated value. It is represented in CIF2 as a collection of label-value pairs, enclosed by matching curly braces.
20) Is whitespace allowed between the opening(closing) brace of a list and its first(last) element, or only to separate elements?
21) Is there special value in requiring the labels in a CIF2 Table to be quote-delimited? And in not allowing them to be triple-quote delimited? These restrictions are no special burden, I don$B!G(Bt think, but they seem unnecessary. As far as I am concerned, the labels could be any value interpretable according to the DDL1/2 $B!H(Bchar$B!I(B type.
22) If $B!H(Bthere is implicit line joining, and the newline has no meaning with regard to the Table values$B!I(B then are $B!H(B\n;$B!I(B-delimited text blocks forbidden as list elements? There$B!G(Bs a better argument here than for List values (comment 18, above), but given the explicit inclusion of $B!F(B\n$B!G(B as part of the delimiter for these values, they could be allowed.
23) Tokens are not a language component, but rather a parsing detail, and parsers are not obligated to tokenize in any particular way. I have no use for the spec instructing me about how to tokenize a CIF stream. The main point here seems to be requiring whitespace between language constructs where otherwise the spec might be construed to permit its omission. It would be more appropriate, easier to understand, and harder to miss if the details relevant to each language construct were included with the description of changes to that component. Alternatively, see (26) below.
24) The Reasoning subsection contains only descriptions and explanations, not any reasoning or even justification / rationale.
25) Moreover, I don$B!G(Bt think it$B!G(Bs correct to say that $B!H(BThe only meaningful use of whitespace is to separate data tokens.$B!I(B At least, I think one must adopt a very broad view of $B!H(Bdata tokens$B!I(B to make it correct. Surely whitespace meaningfully separates language keywords, tags, block and save frame headers, AND data values, all one from another. Furthermore, whitespace inside delimited string values is meaningful to applications, and therefore must be allowed and preserved.
26) If you want to make a blanket statement here then perhaps you want to say that language keywords, tags, block and save frame headers, and top-level data values must all be separated from one another by whitespace, where $B!H(Btop-level data values$B!I(B are defined as values that are not components of a List or Table. Details of the required syntax for List and Table contents are more appropriately discussed in changes 7 and 8, respectively.
John C. Bollinger, Ph.D.
Computing and X-Ray Scientist
Department of Structural Biology
St. Jude Children's Research Hospital
(901) 595-3166 [office]
Email Disclaimer: www.stjude.org/emaildisclaimer
_______________________________________________ cif-developers mailing list firstname.lastname@example.org http://scripts.iucr.org/mailman/listinfo/cif-developers
Reply to: [list | sender only]
- RE: Draft CIF2 standard available (Bollinger, John C)