You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@daffodil.apache.org by "Michael Beckerle (Jira)" <ji...@apache.org> on 2023/02/24 15:46:00 UTC

[jira] [Commented] (DAFFODIL-2797) Make Runner final

    [ https://issues.apache.org/jira/browse/DAFFODIL-2797?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17693249#comment-17693249 ] 

Michael Beckerle commented on DAFFODIL-2797:
--------------------------------------------

What are Scala's ways of extending a final class? You  are talking of implicit conversions to things like RichString, or something else?

> Make Runner final
> -----------------
>
>                 Key: DAFFODIL-2797
>                 URL: https://issues.apache.org/jira/browse/DAFFODIL-2797
>             Project: Daffodil
>          Issue Type: Improvement
>          Components: Clean Ups
>            Reporter: jinterrante
>            Priority: Trivial
>
> We have hundreds of Test*.scala files in Daffodil, each with at least one 'val runner' constructing a test suite from a TDML file.  IDEA has warnings in all of these files saying that we need explicit type declarations for these runners.  However, no user ever extends the Runner class so we could make Runner a final class, which would eliminate all of these warnings in IDEA.  Scala has ways to let users extend even final classes like String so I am not worried about preventing users from doing something with Runner.
> We also could look for other Daffodil classes which cause similar IDEA warnings and make them final too if they are unlikely to ever be subclassed.



--
This message was sent by Atlassian Jira
(v8.20.10#820010)