Bug 108662 - [RFE] compiler warning on comparison of different float types
Summary: [RFE] compiler warning on comparison of different float types
Status: NEW
Alias: None
Product: JDT
Classification: Eclipse Project
Component: Core (show other bugs)
Version: 3.1   Edit
Hardware: PC Windows XP
: P3 enhancement (vote)
Target Milestone: ---   Edit
Assignee: JDT-Core-Inbox CLA
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2005-09-02 06:22 EDT by Ortwin Glück CLA
Modified: 2005-09-05 07:38 EDT (History)
0 users

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Ortwin Glück CLA 2005-09-02 06:22:20 EDT
A line like
if (Float.parseFloat("1.11") > 1.11)
should optionally trigger a compiler warning that floating point
values of different types are compared here which leads
to unprecise results. Other operators affected: +, -,
==, >, <

Maybe Jikes can already do that and only a GUI has to be built. I don't know.
Please check that out.

A similar request was filed with the Jikes project:
https://sourceforge.net/tracker/index.php?func=detail&aid=1280493&group_id=128803&atid=712760