Menu

#622 FIX() for negative inputs and unsigned types

v1.0 (example)
closed
nobody
None
5
2018-04-16
2014-09-08
No

test_fix.pro checks for the results of FIX() for negative inputs and unsigned returned types. The IDL docs (http://www.exelisvis.com/docs/FIX.html) don't reference this situation explicitly, but it seems like an inherently undefined operation and as such architecture/implementation specific. And while gdl appears to match IDL on x86_64, e.g.:

GDL> print,FIX(-1.01,type=12)
   65535
IDL> print,FIX(-1.01,type=12)
   65535

on arm this is returning:

GDL> print,FIX(-1.01,type=12)
   0

I have no access to IDL on non-x86 architectures so I can't compare. But my suggestion would be to not test this situation.

Related

Bugs: #622

Discussion

  • Orion Poplawski

    Orion Poplawski - 2015-05-19

    Ping? I think we should not test this condition.

     
    • giloo

      giloo - 2015-05-20

      Pong? :-)
      I agree with you, we should do something.
      The test comments by Alain specifically refer to problems with negative inputs reported by a "Nicolas". Everybody could remove the test for negative values, but I would prefer Alain reviews this. Perhaps we should make the test only for intel
      architectures, or simply report the errors but let the test pass.
      Gilles

      On 05/19/2015 05:06 AM, Orion Poplawski wrote:

      Ping? I think we should not test this condition.


      [bugs:#622] http://sourceforge.net/p/gnudatalanguage/bugs/622 FIX() for negative inputs and unsigned types

      Status: open
      Group: v1.0 (example)
      Created: Mon Sep 08, 2014 08:53 PM UTC by Orion Poplawski
      Last Updated: Mon Sep 08, 2014 08:53 PM UTC
      Owner: nobody

      test_fix.pro checks for the results of FIX() for negative inputs and unsigned returned types. The IDL docs (http://www.exelisvis.com/docs/FIX.html) don't reference this situation explicitly, but it seems like an inherently undefined operation and as such
      architecture/implementation specific. And while gdl appears to match IDL on x86_64, e.g.:

      GDL> print,FIX(-1.01,type=12)
      65535
      IDL> print,FIX(-1.01,type=12)
      65535

      on arm this is returning:

      GDL> print,FIX(-1.01,type=12)
      0

      I have no access to IDL on non-x86 architectures so I can't compare. But my suggestion would be to not test this situation.


      Sent from sourceforge.net because you indicated interest in https://sourceforge.net/p/gnudatalanguage/bugs/622/ https://sourceforge.net/p/gnudatalanguage/bugs/622

      To unsubscribe from further messages, please visit https://sourceforge.net/auth/subscriptions/ https://sourceforge.net/auth/subscriptions

       

      Related

      Bugs: #622

  • Sylwester Arabas

    • status: open --> closed
     

Log in to post a comment.