You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@daffodil.apache.org by "Steve Lawrence (Jira)" <ji...@apache.org> on 2021/08/25 11:23:00 UTC

[jira] [Created] (DAFFODIL-2556) Build grammar of top-level elements to enforce checking

Steve Lawrence created DAFFODIL-2556:
----------------------------------------

             Summary: Build grammar of top-level elements to enforce checking
                 Key: DAFFODIL-2556
                 URL: https://issues.apache.org/jira/browse/DAFFODIL-2556
             Project: Daffodil
          Issue Type: Bug
          Components: Front End
            Reporter: Steve Lawrence


Ideally we would build the grammar for all top level elements that could potentially be roots (e.g. not referenced by other elements) so that we can enforce checking, as mentioned in this comment of a PR (for context):

https://github.com/apache/daffodil/pull/625#discussion_r695081931

This comes with the possibility of breaking schemas that have elements that aren't intended to be roots, but just happen to be not referenced (maybe for development reasons, maybe the element is expected to be accessed to other schemas). So we may need a way to specifiy which elements are roots, or perhaps that an element is specifically not allowed to be a root for these cases.

Another thing to consider, is due to the lazy nature of much of the front end, some checks may not happen unless a parser/unparse actually access some lazy member. If we do not build parser/unparsers and only access the grammar, those checks may not happen. So we may need to make changes to ensure some checks always happen, regardless of parser/unparser generation.



--
This message was sent by Atlassian Jira
(v8.3.4#803005)