Menu

#30 Fix nested package generation

None
closed
None
4
2021-12-27
2017-01-06
David
No

Fix code generation of nested packages for java,php and as3

Also fix an uninitialized variable bug in the php generator,
and fix a bug, where the package of an as3 class was incorrectly
written if the package was a nested package: the top level package
name was written, followed by the open curly brace and after the
brace, the other package name parts were written.

1 Attachments

Discussion

  • Oliver Kellogg

    Oliver Kellogg - 2017-01-06

    Vincent, I believe you already fixed this type of problem in the dia2code-c++ branch?
    I would consider merging the branch to the master. What do you think?

     
  • Oliver Kellogg

    Oliver Kellogg - 2017-01-07

    I went ahead and created an initial development release from the dia2code-c++ branch.
    The plan is to direct what little time I have to this branch.
    It would help if you could try out the new Java generation, in particular whether it solves the nested package problem that you observed. Many thanks.

     
  • David

    David - 2017-01-10

    The dia2copde-c++ branch fixes the issue, but behaves different than master with this patch applied. If you have a package named "net.sourceforge.dia" and a nested package "codegen", the master branch would create the directory structure "net/sourceforge/dia/codegen" for any class in package "net.sourceforge.dia.codegen". The dia2code-c++ branch would create this directory structure: "net.sourceforge.dia/codegen".
    I'm not sure which behaviour is more correct. Personally i like the behaviour of master more.

     
    • Oliver Kellogg

      Oliver Kellogg - 2017-01-12

      I have addressed this in commit 2531d3.

       

      Last edit: Oliver Kellogg 2017-01-12
  • Oliver Kellogg

    Oliver Kellogg - 2017-01-12
    • status: open --> accepted
    • assigned_to: Oliver Kellogg
    • Group: -->
     
  • Oliver Kellogg

    Oliver Kellogg - 2021-12-27
    • status: accepted --> closed
     

Log in to post a comment.