Discussion List Archives

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

Re: [ddlm-group] Space as a list item separator

It would be easy enough to disallow mixed delimiters.

I favor spaces, but I don't see optional commas as a big disadvantage 
either. If commas are uses, allowing mixed delimiters is a bad idea. 
Herbert's parser allows a sloppy mixed syntax, but almost certainly 
never writes it that way. The sequence [1,2, 3 4] could be officially 
invalid, even if some parsers tolerate it.

My opinion is that the trend towards Python (or similar) syntax is not 
useful unless the entire syntax is converted. For example, CIF2 requires 
white space after a close quote, apparently to be more like other modern 
syntax, but will still plans to allow quotes embedded in a non-quoted 
string. A half-way conversion seems like complexity with no real benefit.

Herbert seems to disfavor the Python-syntax trend, except in the list 
case. That is because he has arguments favoring commas other than "it 
looks more modern/normal".

P.S. I am essentially just a guest end-user on this list. I hope my 
comments are useful, and not just adding to the overly-complex mix of 
opinions.

Joe

John Westbrook wrote:
> Given that allowing comma + space permits [1,2, 3 4] I will vote
> for space only.  While this moves away from familiar syntax in
> other languages, Python for instance would not allow the above
> mixed case.
> 
> John
> 
> 
> James Hester wrote:
>> Herbert writes:
>>
>> "I thought you had your vote and had decided not to support commas in
>> lists, but if it is still being discussed ..."
>>
>> I have been holding off on a final declaration, given that the vote 
>> wasn't that definitive and John hasn't yet contributed. But, unless 
>> Brian and John both move to the commas + spaces option, the choice of 
>> this group is that spaces only can be used as a list item separator.  
>> That will be the syntax that we will move forward with.
>>
>> Herbert: keep your current software versions around somewhere, because 
>> until COMCIFS formally puts the big tick in the box, the standard is not 
>> set in stone.
>>
>> On Wed, Dec 2, 2009 at 10:24 AM, Herbert J. Bernstein 
>> <yaya@bernstein-plus-sons.com <mailto:yaya@bernstein-plus-sons.com>> wrote:
>>
>>     I am very sorry to hear that.  In my shop, dealing with this one
>>     change will involve 1-3 person-months of recoding to make commas
>>     optional and
>>     to introduce warning messages when they are encountered and in
>>     redoing dictionaries and test cases.  What a pointless waste.  I
>>     hope this
>>     group will complete its work in the near future, so we can have some
>>     chance of having something stable to work against.
>>
>>
>>     =====================================================
>>      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 <mailto:yaya@dowling.edu>
>>     =====================================================
>>
>>     On Wed, 2 Dec 2009, James Hester wrote:
>>
>>         Counting up the votes so far on the list delimiter question I get:
>>
>>         Space and comma: David, Herbert
>>         Space only: Simon, Nick, James, Joe (?)
>>         Agnostic: Brian
>>         Unknown: John
>>
>>         It looks like the spaces have it, although I have perhaps
>>         over-interpreted
>>         Joe's reply.  
>>
>>         On Wed, Dec 2, 2009 at 3:57 AM, David Brown <idbrown@mcmaster.ca
>>         <mailto:idbrown@mcmaster.ca>> wrote:
>>              MY VOTE IS FOR 1 (SPACE AND COMMA) because commas are better
>>              visually.  Not a strong argument and I would not give my vote a
>>              large weighting.  I can live with 2 as well.
>>
>>              David
>>
>>              James Hester wrote:
>>         Dear CIF2 people: the time has come to vote on the list item
>>         separator issue.  Firstly: as far as I know, nobody is against
>>         space as a separator, so spaces will be possible list item
>>         separators.  Some may be against commas, so this vote is on
>>         whether or not to allow commas.
>>
>>         To summarise the arguments:
>>
>>         1. In favour of both space and comma
>>            - comma is used in some other non-CIF contexts as a list
>>         delimiter
>>
>>         2. Against comma:
>>            - A single type of separator makes the grammar simpler
>>            - Space is used everywhere else in CIF as a separator
>>         (consistency)
>>            - Comma can then be used in non-delimited strings
>>
>>         Space only: Nick, James (Nick is here)
>>         Comma and Space: ?
>>
>>         On Tue, Dec 1, 2009 at 5:30 PM, James Hester
>>         <jamesrhester@gmail.com <mailto:jamesrhester@gmail.com>> wrote:
>>              More specifically, CIF1.1 excludes square brackets
>>              as the first character in a non-delimited string.
>>
>>              On Tue, Dec 1, 2009 at 9:33 AM, James Hester
>>              <jamesrhester@gmail.com <mailto:jamesrhester@gmail.com>> wrote:
>>                    Dear Herbert: as CIF 1.1 doesn't define
>>                    lists, I'm not sure why you suggest that
>>                    the example below is a valid tag.
>>
>>                    On Tue, Dec 1, 2009 at 12:36 AM, Herbert
>>                    J. Bernstein
>>                    <yaya@bernstein-plus-sons.com
>>         <mailto:yaya@bernstein-plus-sons.com>> wrote:
>>                          Sorry something got lost in
>>                          the prior message.  It
>>                          should have
>>                          read:
>>
>>                                Dear Colleagues,
>>
>>                                 Back to the
>>                                question of
>>                                commas.  If you
>>                                accept the
>>                                desirability of
>>                                having a CIF
>>                                1.5, commas in
>>                                lists become
>>                                very useful.
>>                                 Someone with
>>                                a CIF 1.1 editor
>>                                will be able to
>>                                prepare a CIF
>>                                1.5 file for
>>                                many
>>                                useful cases by
>>                                doing all lists
>>                                with commas and
>>                                no embedded
>>                                blanks
>>                                as long as they
>>                                can make their
>>                                lists fit on
>>                                single lines.
>>                                 In CIF 1.1
>>
>>                                [[1,2,3],[4,5,6],[7,8,9]]
>>
>>                                is a valid value
>>                                for a tag, but
>>
>>                                [[1 2 3] [4 5 6]
>>                                [7 8 9]]
>>
>>         is not.
>>
>>
>>         No, neither example is a valid CIF 1.1 tag.  CIF 1.1
>>         explicitly excludes brackets as the first character
>>         of a non-delimited string.
>>
>>
>>                    Having the option of commas
>>                    in lists will help to smooth
>>                    the
>>                    transition for at least some
>>                    people.
>>
>>
_______________________________________________
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.