Discussion List Archives

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [ddlm-group] Technical issues with Proposal P. .

Dear James,

   I don't understand the question.  In its internal representation
the string is what it is.  What is the ambuguity?  If a
string is presented to an application by an API and it contains
\", then it contains the two characters backslash and double quote
with a meaning that depends on the type specified in the dictionary.
The are no delimiters in the internal representation, so a double
quote is as good or bad a character as any other.  How is it a delimiter
internally?  Is there some rule that we are not supposed to have strings
whose internal representation contains a delimiter?

   Regards,
     Herbert

=====================================================
  Herbert J. Bernstein, Professor of Computer Science
    Dowling College, Kramer Science Center, KSC 121
         Idle Hour Blvd, Oakdale, NY, 11769

                  +1-631-244-3035
                  yaya@dowling.edu
=====================================================

On Wed, 23 Feb 2011, James Hester wrote:

> I would point out that nobody has yet addressed, let alone answered my
> question.  I am *not* confused about going from syntax to internal
> representation, as it appears Simon briefly was.  I am concerned about
> how a CIF application will disambiguate the character sequence
> <backslash><delimiter> *in the internal representation*.
>
> I am however glad that we all seem to agree that the particular
> delimiters used to express data values should not be significant
> beyond the parser.
>
> On Wed, Feb 23, 2011 at 3:32 AM, Bollinger, John C
> <John.Bollinger@stjude.org> wrote:
>>
>> On Tuesday, February 22, 2011 7:51 AM, Herbert J. Bernstein wrote:
>>
>>>   From the point of view of writing a pure "CIF2" application that is not aware of the whitespace, particular quote marks, comments, etc, those two string are identical.
>>>
>>>   From the point of view of a more general CIF API, in which comments, magic numbers, and partiular quote marks, those two string are different in precisely the same way that the string 'ABC' and "ABC" are different, and 13.4 and
>>> 1.34e1 are different.
>>>
>>>   This is _not_ an ambiguity.  It is a matter of whether we are looking for the information in a file or looking for the representations of the data in the file.
>>
>> Herbert is right about this.  It doesn't matter which syntactic variant was used to express a data value in an input CIF.  Once the value is parsed, the result is the value.  In particular, under proposal P, """C\"""" expresses a different value than does r"""C\"""", whereas """C\\\"""" and r"""C\"""" express the same value.  The fact that the character sequence C" cannot be expressed via Python raw string format is irrelevant.  An application receiving these values does not need to know and should not care in which form the value was expressed in a CIF, if indeed it was ever expressed in CIF format at all.
>>
>> However, although there is no technical issue here, the fact that an experienced and successful Python and CIF practitioner such as James raised the question is illuminating.  It demonstrates that the complexity of the syntax and semantics provided by proposal P would be likely to be a source of confusion for developers and users both.
>>
>>
>> Regards,
>>
>> John
>>
>> --
>> John C. Bollinger, Ph.D.
>> Department of Structural Biology
>> St. Jude Children's Research Hospital
>>
>>
>>
>>
>> Email Disclaimer:  www.stjude.org/emaildisclaimer
>> _______________________________________________
>> ddlm-group mailing list
>> ddlm-group@iucr.org
>> http://scripts.iucr.org/mailman/listinfo/ddlm-group
>>
>
>
>
> -- 
> T +61 (02) 9717 9907
> F +61 (02) 9717 3145
> M +61 (04) 0249 4148
> _______________________________________________
> ddlm-group mailing list
> ddlm-group@iucr.org
> http://scripts.iucr.org/mailman/listinfo/ddlm-group
>
_______________________________________________
ddlm-group mailing list
ddlm-group@iucr.org
http://scripts.iucr.org/mailman/listinfo/ddlm-group

Reply to: [list | sender only]
International Union of Crystallography

Scientific Union Member of the International Science Council (admitted 1947). Member of CODATA, the ISC Committee on Data. Partner with UNESCO, the United Nations Educational, Scientific and Cultural Organization in the International Year of Crystallography 2014.

International Science Council Scientific Freedom Policy

The IUCr observes the basic policy of non-discrimination and affirms the right and freedom of scientists to associate in international scientific activity without regard to such factors as ethnic origin, religion, citizenship, language, political stance, gender, sex or age, in accordance with the Statutes of the International Council for Science.