Uploaded image for project: 'Errai'
  1. Errai
  2. ERRAI-640

[errai-codegen] StatementBuilder.loadVariable() doesn't work with fields from super classes with reduced visiblity

    Details

      Description

      ThingyBase.java
      public abstract class ThingyBase {
        protected int protectedField;
        int packagePrivateField;
      }
      
      ThingyGenerator.java
      public class ThingyGenerator {
        /* ... */
          Stmt.loadVariable("protectedField")
        /* ... */
      
        /* ... */
          Stmt.loadVariable("packagePrivateField")
        /* ... */
      }
      

      This pseudo example will fail with a org.jboss.errai.codegen.exception.OutOfScopeException

      Workaround: Make fields public.

        Gliffy Diagrams

          Attachments

            Activity

              People

              • Assignee:
                csa Christian Sadilek
                Reporter:
                jbarop Johannes Barop
              • Votes:
                0 Vote for this issue
                Watchers:
                1 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved: