bugKawa - Bugs: bug #38891, Wrong warning with literal double...

 
 

bug #38891: Wrong warning with literal double value

Submitter:  Matthieu Vachon <maoueh>
Submitted:  Sun 05 May 2013 03:52:34 AM UTC
   
 
Category:  None Severity:  3 - Normal
Item Group:  None Status:  Fixed
Privacy:  Public Assigned to:  bothner
Open/Closed:  Closed
* Mandatory Fields

Add a New Comment Rich Markup
   

Sat 11 May 2013 06:37:36 PM UTC, comment #1: 

Thanks.  I checked in a fix as well as the testcase  In this case the fix was to remove some code in Type "comparison" that had been obsoleted by newer code.

Per Bothner <bothner>
Group administrator
Sun 05 May 2013 03:52:34 AM UTC, original submission:  

I saw a similar bug report in the list but since it was quite old (2003), I will submit a new one. Feel free to close it if you think it's a duplicate.

When compiling the following code, Kawa will issue a warning saying there is more than one applicable method:


(define (test)
  (make <java.lang.Double> 3.0))


Full compile log is:


(compiling make-double.scm to org.kawa.test.double)
make-double.scm:4:3: warning - more than one possibly applicable method '<init>' in java.lang.Double
  candidate: java.lang.Double java.lang.Double.<init>(double)
  candidate: java.lang.Double java.lang.Double.<init>(java.lang.String)


In my opinion, since I directly enter a double literal (3.0), Kawa should automatically assume I want to use the double version.

I attached my test file for easier testing.

Regards,
Matt

Matthieu Vachon <maoueh>

 

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

Attach Files:
   
   
Comment:
   

Attached Files
file #28022:  make-double.scm added by maoueh (104B - application/octet-stream - Kawa test file)

 

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 maoueh (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
    2013-05-11 bothner StatusNone Fixed
        Assigned toNone bothner
        Open/ClosedOpen Closed
    2013-05-05 maoueh Attached File- Added make-double.scm, #28022

    Back to the top

    Powered by Savane 3.13-4448.
    Corresponding source code