Closed CC007 closed 1 year ago
Unfortunately, "piggyback" classes are not supported. This feature of Java is a pet peeve of mine; manifold will probably never support it. Sorry this tidbit is missing from the documentation.
I expected as much. Just tried to use it, because java's nested class field access rules are a bit wack and prevented me from demoing how the Private
and Protected
parameter for manifold-props annotations work, so I tried to use these. I'll just use a package with multiple source files instead then.
I'll just use a package with multiple source files instead then.
Right. Or, you can use static inner classes, whichever is most suitable. In my view piggyback classes are pointless at best. :/
That's what I meant with nested classes above. Field access is unintuitive, considering you can access private fields defined in nested classes both from the parent and from sibling classes. It has its uses, but it wasn't suitable for my use-case
Describe the bug When using multiple classes in one source file (one being public, the rest package-private, like is allowed in Java), I get the following compile-time error:
To Reproduce Steps to reproduce the behavior: compile code from gist
Expected behavior I expected these classes to compile as if they were package-private classes that were specified in separate files, with all Manifold features working without issue.
Screenshots
Desktop (please complete the following information):
Additional context See gist: https://gist.github.com/CC007/13c6211b20c3c64dfb023415fc98cf2c The code here uses manifold-props, but I also noticed a
... because "tree.sym" is null
error when using other manifold dependencies.