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

[jira] [Closed] (DAFFODIL-2326) Do not pass RuntimeData to DPathCompileInfo constructor

     [ https://issues.apache.org/jira/browse/DAFFODIL-2326?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Dave Thompson closed DAFFODIL-2326.
-----------------------------------

Verified the specified commit (commit eb603e7f4a342e1a63d1e07f59c714cf531724bc) is included in the latest pull from the daffodil repository.

Verified changes identified in commit comment were implemented.

Verified the all daffodil subproject sbt test suites execute successfully including the modified and added tests.

Verified the nightly test schemas compile and save successfully with the exception of the ATO and JSON schemas. These issues will be addressed in new JIRA tickets DAFFODIL-2551 and DAFFODIL-2552.

Verified the nightly test suite executes successfully with the exception of ATO and JSON tests.

> Do not pass RuntimeData to DPathCompileInfo constructor
> -------------------------------------------------------
>
>                 Key: DAFFODIL-2326
>                 URL: https://issues.apache.org/jira/browse/DAFFODIL-2326
>             Project: Daffodil
>          Issue Type: Improvement
>          Components: Back End, Clean Ups, Middle &quot;End&quot;
>    Affects Versions: 2.5.0
>            Reporter: Mike Beckerle
>            Assignee: Mike Beckerle
>            Priority: Minor
>             Fix For: 3.2.0
>
>
> DPathCompileInfo should not be passed a RuntimeData to its constructor.
> This causes a great deal of circularity between RuntimeData objects and computations that provide the values needed in those RuntimeData objects.
> This prevents simplifying the constructors of the RuntimeData objects (DAFFODIL-2325), and causes them to hold onto large compile-time structures unnecessarily (DAFFODIL-1879)
> Any computation that uses a check of an Evaluatable if it isConstant, (knownEncoding for example asks EncodingEv.isConstant), well.... constructing an evaluatable requires a DPathCompileInfo object, and ..... here's the problem: right now we pass a RuntimeData object to the DPathCompileInfo constructor purely for use compiling type-calc-related functions.
> The type-calc functions need to know about sibling elements. The DPath compile info objects don't have sibling info. But the RuntimeData objects do. So that's where the expression compiler gets the sibling info it needs.
> If some sibling information is needed to compile these functions, then we should compute that information and pass it to the DPathCompileInfo constructor, not just pass in the RuntimeData object.
>  
> Note however. The whole set of type-calc related functions is an experimental feature and subject to review. There are proposals to simplify it significantly. It's possible these functions will just not be needed. And in that case, the sibling info won't be needed in the DPathCompileInfo objects.
>  
>  



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