Details

    • Type: Bug Bug
    • Status: Closed
    • Priority: Blocker Blocker
    • Resolution: Won't Fix
    • Affects Version/s: 1.6.3
    • Fix Version/s: None
    • Component/s: parser
    • Labels:
      None
    • Environment:
      suse linux enterprise 64 bit

      Description

      hi i just tried some groovy by following http://pleac.sourceforge.net/pleac_groovy/numbers.html
      code:

      import java.text.*
       int nb = 0
      try {
          nb = NumberFormat.getInstance().parse('33.5') // '.5' will be ignored
          nb = NumberFormat.getInstance().parse('abc')
      } catch (ParseException ex) {
          assert ex.getMessage().contains('abc')
      }
      assert nb == 33
      

      i get the error Caught: java.lang.AssertionError: Expression: (nb == 33). Values: nb = 335

      and when i do println nb it gives me the value 335 !
      i categorize this as blocker because it can block the whole system if youre working with floats castings

      greeets umit

        Activity

          People

          • Assignee:
            Jochen Theodorou
            Reporter:
            umit
          • Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved:

              Time Tracking

              Estimated:
              Original Estimate - 1h
              1h
              Remaining:
              Remaining Estimate - 1h
              1h
              Logged:
              Time Spent - Not Specified
              Not Specified

                Development