[tei-council] att.typed and syntactic sugar

Kevin Hawkins kevin.s.hawkins at ultraslavonic.info
Wed Nov 30 23:12:30 EST 2011


Thanks for the clarification of "syntactic sugar", which, as you can 
tell, I've never felt entirely comfortable using.

After some investigation, I see that while @type often achieves 
syntactic salt for an element not available in the modules chosen for a 
particular customization (as is often the case with <name> or <rs>), I 
can't find any members of att.typed for which this is typically the 
case.  That is, att.typed includes elements that are themselves already 
sugar or which don't seem to be sugar or salt of anything.

So I'm now inclined to skip trying to say anything about syntactic sugar 
for att.typed.

I've posted this on the ticket as well; if no one objects, I will let 
SourceForge close the ticket automatically after a period of time.

On 11/30/11 6:58 PM, Martin Holmes wrote:
> Yes, of course you're right. <persName> is syntactic
> sugar for<name type="person">, just as <orgName> is syntactic sugar for
> <name type="org"> and so on.
>
> Got myself really confused there.
>
> Cheers,
> Martin
>
> On 11-11-30 03:55 PM, James Cummings wrote:
>>
>> I think you mean persName not person. ;-)
>>
>> James
>> --
>> James Cummings, InfoDev, OUCS, University of Oxford (via phone)
>>
>> Martin Holmes<mholmes at uvic.ca> wrote:
>>
>>
>> Hi Kevin,
>>
>> I think the basis of the confusion is in your sentence:
>>
>> "Alternatively, use the attribute to create syntactic sugar for another
>> TEI element."
>>
>> Actually, it's the other way round, isn't it?<person> is syntactic
>> sugar for<name type="person">, not the reverse. You don't use the @type
>> attribute to create syntactic sugar for an element; you could devolve
>> the syntactic sugar (if you see what I mean) by converting<person> to
>> <name type="person">.
>>
>> This is based on my assumption that "syntactic sugaring" goes in only
>> one direction:<name type="person"> is the simpler form (requiring a
>> smaller schema with fewer elements and attributes), while<person> is
>> the sugared form (a bit less verbose, so "sweeter" to use, but requiring
>> a larger schema with an extra element).
>>
>> Cheers,
>> Martin
>>
>> On 11-11-30 03:02 PM, Kevin Hawkins wrote:
>>> The December 2 deadline for implementing tickets so that Sebastian can
>>> produce a release this month is rapidly approaching, but I'm still not
>>> sure how to complete this ticket. Should this be postponed for further
>>> discussion during the next Council meeting?
>>>
>>> On 11/26/2011 9:02 PM, Kevin Hawkins wrote:
>>>> Colleagues,
>>>>
>>>> I was trying to implement:
>>>>
>>>> https://sourceforge.net/tracker/index.php?func=detail&aid=3064014&group_id=106328&atid=644065
>>>>
>>>>
>>>>
>>>> but realized I don't quite understand what we had in mind for our
>>>> advice
>>>> on syntactic sugar. I've added a comment with my question. Could anyone
>>>> who understands this weigh in? Thanks,
>>>>
>>>> Kevin
>>
>> --
>> Martin Holmes
>> University of Victoria Humanities Computing and Media Centre
>> (mholmes at uvic.ca)
>> --
>> tei-council mailing list
>> tei-council at lists.village.Virginia.EDU
>> http://lists.village.Virginia.EDU/mailman/listinfo/tei-council
>>
>> PLEASE NOTE: postings to this list are publicly archived
>> .
>>
>


More information about the tei-council mailing list