bugKawa - Bugs: bug #20143, some GCJs can't compile...

 
 

bug #20143: some GCJs can't compile gnu/lists/PrintConsumer.java:74

Submitter:  Stephen Compall <S11001001>
Submitted:  Mon 11 Jun 2007 02:11:58 AM UTC
   
 
Category:  None Severity:  3 - Normal
Item Group:  Problem building Kawa Status:  Wont Fix
Privacy:  Public Assigned to:  bothner
Open/Closed:  Closed
* Mandatory Fields

Add a New Comment Rich Markup
   

Mon 11 Jun 2007 05:14:06 AM UTC, comment #1: 

Thanks for the comment.  I did some experimenting, trying both gcj (GCC) 4.1.1 20061011 and gcj (GCC) 4.1.2 20070502 (as shipped with respectively Fedora 6 and 7).  Neither seemed to have this problem.

I considered your work-around, but it's an unusual use of super, and would fail if a subclass overloaded write(String,int,int) - not that is terribly likely.

So I decided to leave it as-is.

Per Bothner <bothner>
Group administrator
Mon 11 Jun 2007 02:11:58 AM UTC, original submission:  

I tried building from SVN trunk r5973 with gcj (GCC) 4.1.2 20070302 (prerelease) (4.1.2-1mdv2007.1), which is the current official/update release on Mandriva 2007.  It has trouble with e.g. choosing the correct `execute' method to call in my example file, attached to this report.

This causes r5973 to break like:

./configure --with-gcj && make
...
CLASSPATH=../..:./../..:$CLASSPATH gcj -C -d ../.. -g AbstractFormat.java AbstractSequence.java ...
PrintConsumer.java: In class 'gnu.lists.PrintConsumer':
PrintConsumer.java: In method 'gnu.lists.PrintConsumer.write(java.lang.CharSequence,int,int)':
PrintConsumer.java:74: error: Can't find method ‘write(Ljava/lang/String;II)’ in type ‘gnu.lists.PrintConsumer’. Candidates are:
  'gnu.lists.PrintConsumer.write(java.lang.CharSequence,int,int)' in 'gnu.lists.PrintConsumer'
  'java.io.PrintWriter.write(java.lang.String,int,int)' in 'java.io.PrintWriter'.
      write((String) csq, start, end);

I worked around it here by putting super.write instead.

I asked in irc.oftc.net/#gcj and at least gcj (GCC) 4.1.3 20070518 (prerelease) (Debian 4.1.2-8) supports the construct correctly, so there may be too small a subset of compilers to justify changing it in SVN.

Stephen Compall <S11001001>

 

(Note: upload size limit is set to 16384 kB, after insertion of the required escape characters.)

Attach Files:
   
   
Comment:
   

Attached Files
file #13006:  MoreSpecificSuperApplies.java added by S11001001 (476B - application/octet-stream - a smaller test case for GCJ)

 

Depends on the following items: None found

Items that depend on this one: None found

 

Carbon-Copy List
  • -email is unavailable- added by bothner (Posted a comment)
  • -email is unavailable- added by S11001001 (Submitted the item)
  •  

    There are 0 votes so far. Votes easily highlight which items people would like to see resolved in priority, independently of the priority of the item set by tracker managers.

    Only logged-in users can vote.

     

    Follow 4 latest changes.

    Date Changed by Updated Field Previous Value => Replaced by
    2007-06-11 bothner StatusNone Wont Fix
        Assigned toNone bothner
        Open/ClosedOpen Closed
    2007-06-11 S11001001 Attached File- Added MoreSpecificSuperApplies.java, #13006

    Back to the top

    Powered by Savane 3.13-4b48.
    Corresponding source code