Debian Bug report logs - #240091
java code: interface bug fix and better pretty printing

version graph

Package: dia2code; Maintainer for dia2code is Francesco Aloe <francescoaloe4gnulinux@gmail.com>; Source for dia2code is src:dia2code.

Reported by: Stefano Zacchiroli <zack@debian.org>

Date: Thu, 25 Mar 2004 19:03:04 UTC

Severity: normal

Tags: patch

Found in version 0.8.1-3

Reply or subscribe to this bug.

Toggle useless messages

View this report as an mbox folder, status mbox, maintainer mbox


Report forwarded to debian-bugs-dist@lists.debian.org, Morgon Kanter <morgon@surgo.net>:
Bug#240091; Package dia2code. Full text and rfc822 format available.

Acknowledgement sent to Stefano Zacchiroli <zack@debian.org>:
New Bug report received and forwarded. Copy sent to Morgon Kanter <morgon@surgo.net>. Full text and rfc822 format available.

Message #5 received at submit@bugs.debian.org (full text, mbox):

From: Stefano Zacchiroli <zack@debian.org>
To: Debian Bug Tracking System <submit@bugs.debian.org>
Subject: java code: interface bug fix and better pretty printing
Date: Thu, 25 Mar 2004 19:51:18 +0100
[Message part 1 (text/plain, inline)]
Package: dia2code
Version: 0.8.1-3
Severity: normal
Tags: patch

I've found two issues in dia2code Java support, the attached patch
should fix both of them:

1) documentation claims that dia2code support "interface" stereotype and
   uses it to generate Java interfaces. Still, the generated interface
   are similar to:

    public interface Foo {
      public void doSomething () {
      }
    }

    The above is not valid Java since methods specified in interface
    should have no implementation at all as in the following code:

    public interface Foo {
      public void doSomething ();
    }

2) I found the generated Java code not really "pretty"-printed, in
   particular:
   - methods with no argument are output as "void foo ( )", instead of
     "void foo ()"
   - too many spaces are output in methods' arguments as in
     "void foo ( int a, int b)", the standard is the more concise
     "void foo (int a, int b)".
   - spaces are not left between methods end and the javadoc comment
     which precedes the next method

The attached patch fixed both (1) (a bug) and (2) (a cosmetic issue).
Could you please embed the patch in the package and/or forward it
upstream for consideration?

TIA,
Cheers.

-- System Information:
Debian Release: testing/unstable
  APT prefers unstable
  APT policy: (500, 'unstable')
Architecture: powerpc (ppc)
Kernel: Linux 2.6.3-ben2-fistandantilus
Locale: LANG=it_IT@euro, LC_CTYPE=it_IT@euro

Versions of packages dia2code depends on:
ii  libc6                       2.3.2.ds1-11 GNU C Library: Shared libraries an
ii  libxml2                     2.6.7-1      GNOME XML library
ii  zlib1g                      1:1.2.1-5    compression library - runtime

-- no debconf information
[dia2code.patch (text/x-c, attachment)]

Information stored:
Bug#240091; Package dia2code. Full text and rfc822 format available.

Acknowledgement sent to Morgon Kanter <morgon@surgo.net>:
Extra info received and filed, but not forwarded. Full text and rfc822 format available.

Message #10 received at 240091-quiet@bugs.debian.org (full text, mbox):

From: Morgon Kanter <morgon@surgo.net>
To: Stefano Zacchiroli <zack@debian.org>, 240091-quiet@bugs.debian.org
Subject: Re: Bug#240091: java code: interface bug fix and better pretty printing
Date: Thu, 25 Mar 2004 15:20:34 -0500
This one time, at band camp, Stefano Zacchiroli <zack@debian.org> wrote:
> The attached patch fixed both (1) (a bug) and (2) (a cosmetic issue).
> Could you please embed the patch in the package and/or forward it
> upstream for consideration?

Thank you for the patch. Upstream is dead, and I'll be orphaning this 
soon. If you want to take it over, that would be fine, I don't even use 
it anymore and you seem a lot more knowledgable for this package than I do.

Morgan



Information stored:
Bug#240091; Package dia2code. Full text and rfc822 format available.

Acknowledgement sent to Stefano Zacchiroli <zack@bononia.it>:
Extra info received and filed, but not forwarded. Full text and rfc822 format available.

Message #15 received at 240091-quiet@bugs.debian.org (full text, mbox):

From: Stefano Zacchiroli <zack@bononia.it>
To: Morgon Kanter <morgon@surgo.net>
Cc: 240091-quiet@bugs.debian.org
Subject: Re: Bug#240091: java code: interface bug fix and better pretty printing
Date: Fri, 26 Mar 2004 03:38:56 +0100
On Thu, Mar 25, 2004 at 03:20:34PM -0500, Morgon Kanter wrote:
> Thank you for the patch. Upstream is dead, and I'll be orphaning this
> soon. If you want to take it over, that would be fine, I don't even
> use it anymore and you seem a lot more knowledgable for this package
> than I do.

Well, I'm definitely not a Java programmer, it just happened than I need
to perform some OO design and argouml doesn't work on my laptop :-) If
you like I can NMU the package with this patch, but that's it. I know
almost nothing of the other converter shipped in the package so I don't
think I will be a good maintainer nor I'm interested in the package that
much.

Still I think it's not smart having such a trivial patch and don't
shipping it. Then again, if you like I can NMU the package or, if you
prefer, I can comaintain the package (just add me to the Uploaders
field) ... but nothing more.

Thanks,
Cheers.

-- 
Stefano Zacchiroli -*- Computer Science PhD student @ Uny Bologna, Italy
zack@{cs.unibo.it,debian.org,bononia.it} -%- http://www.bononia.it/zack/
If there's any real truth it's that the entire multidimensional infinity
of the Universe is almost certainly being run by a bunch of maniacs. -!-



Information forwarded to debian-bugs-dist@lists.debian.org, Morgon Kanter <morgon@surgo.net>:
Bug#240091; Package dia2code. Full text and rfc822 format available.

Acknowledgement sent to Stefano Zacchiroli <zack@debian.org>:
Extra info received and forwarded to list. Copy sent to Morgon Kanter <morgon@surgo.net>. Full text and rfc822 format available.

Message #20 received at 240091@bugs.debian.org (full text, mbox):

From: Stefano Zacchiroli <zack@debian.org>
To: 240091@bugs.debian.org
Subject: yet another patch: enables inheritance between Java interfaces
Date: Fri, 26 Mar 2004 16:09:43 +0100
[Message part 1 (text/plain, inline)]
The current dia2code java code generator assumes that each time there is
an arrow from a parent interface to a child something, this something
should "implement" the parent interface.  This inhibit interface
inheritance which is indeed permitted in Java.

The attached patch fixes this problem supporting the following pairs of
parent/child class relationship:
- parent interface, child interface (generate "extends" keyword)
- parent interface, child class     (generate "implements" keyword)
- parent class, child class         (generate "extends" keyword)

The patch is to be applied _after_ the previous patch I've sent for this
bug number.

Cheers.

-- 
Stefano Zacchiroli -*- Computer Science PhD student @ Uny Bologna, Italy
zack@{cs.unibo.it,debian.org,bononia.it} -%- http://www.bononia.it/zack/
If there's any real truth it's that the entire multidimensional infinity
of the Universe is almost certainly being run by a bunch of maniacs. -!-
[dia2code.patch2 (text/plain, attachment)]
[signature.asc (application/pgp-signature, inline)]

Information forwarded to debian-bugs-dist@lists.debian.org, Morgon Kanter <morgon@surgo.net>:
Bug#240091; Package dia2code. Full text and rfc822 format available.

Acknowledgement sent to Stefano Zacchiroli <zack@debian.org>:
Extra info received and forwarded to list. Copy sent to Morgon Kanter <morgon@surgo.net>. Full text and rfc822 format available.

Message #25 received at 240091@bugs.debian.org (full text, mbox):

From: Stefano Zacchiroli <zack@debian.org>
To: 240091@bugs.debian.org
Subject: yet yet another patch: avoid invalid "import Foo;" clauses
Date: Sat, 27 Mar 2004 00:27:55 +0100
[Message part 1 (text/plain, inline)]
"import Foo;" clauses are invalid Java code if Foo is not a fully
qualified namespace (e.g. "my.name.space.Foo"). The attached patch (to
be applied after the previous two in this thread) add a test which makes
the Java code generator outputs the "import" clauses only when the class
name is fully qualified.

Slovly converging towards an usable Java code generator ... :-)

Cheers.

-- 
Stefano Zacchiroli -*- Computer Science PhD student @ Uny Bologna, Italy
zack@{cs.unibo.it,debian.org,bononia.it} -%- http://www.bononia.it/zack/
If there's any real truth it's that the entire multidimensional infinity
of the Universe is almost certainly being run by a bunch of maniacs. -!-
[dia2code.patch3 (text/plain, attachment)]
[signature.asc (application/pgp-signature, inline)]

Send a report that this bug log contains spam.


Debian bug tracking system administrator <owner@bugs.debian.org>. Last modified: Wed Apr 16 07:28:29 2014; Machine Name: beach.debian.org

Debian Bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.