Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

<empty/> element not processed #263

Open
lb42 opened this issue May 3, 2017 · 6 comments
Open

<empty/> element not processed #263

lb42 opened this issue May 3, 2017 · 6 comments
Assignees
Labels
conversion: odd resp: council status: needsDiscussion Council has not yet been able to agree on how to proceed. type: bug A bug report. type: enhancement A feature request or other improvement in the Stylesheets.

Comments

@lb42
Copy link
Member

lb42 commented May 3, 2017

Issue TEIC/TEI#1596 has been resolved by creation of a new <empty/> element, but this is not currently being processed by any ODD processor.

@lb42 lb42 added type: bug A bug report. type: enhancement A feature request or other improvement in the Stylesheets. resp: helpWanted No-one on Council has the expertise required to deal with this issue. labels May 3, 2017
@martindholmes
Copy link
Contributor

@lb42 I'm looking at the example on the spec page:

http://www.tei-c.org/release/doc/tei-p5-doc/en/html/ref-empty.html

and wondering what on earth it can mean. Why would anyone do that?

@martindholmes
Copy link
Contributor

Also, is any processing actually required for this element? As far as we can tell, the right behaviour occurs already, just by doing nothing.

@sydb
Copy link
Member

sydb commented Jan 26, 2018

(“We” is me & Martin — tested <empty> as the only child of <content>, as the only child of <sequence>, and of <sequence> with one or two sibling <elementRef>s.)

@lb42
Copy link
Member Author

lb42 commented Jan 26, 2018

@martindholmes It represents a content model which might be more economically expressed as (hi*). But as you can see in the discussion on TEIC/TEI#1596 economy of expression is not the primary goal here.

Can you confirm that for each pair of content models below, both expressions are processed identically?

(a) 

<content/>
 <content><empty/></content>

(b)

 <content>
       <elementRef key="hi" minOccurs="0" maxOccurs="1"/>
      </content> 

<content>
      <alternate>
          <empty/> 
           <elementRef key="hi"/>
       </alternate>
      </content> 

@martindholmes
Copy link
Contributor

martindholmes commented Jan 26, 2018

We think so (although our quick tests were slightly different), although might look at this ticket in a future Stylesheets group meeting and create a complete test suite for all the cases we can think of.

@hcayless hcayless self-assigned this Feb 25, 2018
@martindholmes martindholmes added conversion: odd resp: council status: needsDiscussion Council has not yet been able to agree on how to proceed. and removed resp: helpWanted No-one on Council has the expertise required to deal with this issue. labels Jun 11, 2020
@sydb
Copy link
Member

sydb commented Sep 23, 2021

Council Stylesheets group did a few tests, and as far as we can tell all cases of <empty/> are being properly processed (that is, the output RELAX NG will validate the expected set of constructs) except for the case of an <empty> inside an <alternate>.
For example, @lb42’s example above:

<content>
  <alternate>
    <empty/>
    <elementRef key="hi"/>
  </alternate>
</content> 

results in just (hi). (It should result in either (hi?) or ( hi | empty ).)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
conversion: odd resp: council status: needsDiscussion Council has not yet been able to agree on how to proceed. type: bug A bug report. type: enhancement A feature request or other improvement in the Stylesheets.
Projects
None yet
Development

No branches or pull requests

4 participants