Skip to content

NetRexx Format BIF does not conform to Classic Rexx results #58

@rvjansen

Description

@rvjansen

with the following testcase (from Walter Pachl):

/* REXX */
Parse Version v
Say v
_="    -0.05625000000000000000"
Say '_='_
Say 'format(_/1, 6)' format(_/1, 6)
Say 'format(_+0, 6)' format(_+0, 6)
Say 'format(_  , 6)' format(_  , 6)
_="     0.05625000000000000000"
Say 'format(_/1, 6)' format(_/1, 6)
Say 'format(_+0, 6)' format(_+0, 6)
Say 'format(_  , 6)' format(_  , 6)
/*

results in

NetRexx 4.07 11 Mar 2024
_=    -0.05625000000000000000
format(_/1, 6)     -0.05625
format(_+0, 6)     -0.0562500000
format(_  , 6)     -0.05625000000000000000
format(_/1, 6)      0.05625
format(_+0, 6)      0.0562500000
format(_  , 6)      0.05625000000000000000

when expected result is:

_=    -0.05625000000000000000          
format(_/1, 6)     -0.05625            
format(_+0, 6)     -0.0562500000       
format(_  , 6)     -0.0562500000       
format(_/1, 6)      0.05625            
format(_+0, 6)      0.0562500000       
format(_  , 6)      0.0562500000       

Note that this result is obtained with JVM8 or JVM>=9 with -exec (interpreted). _ is not supported with Java =>9, will be a separate issue, but irrelevant to this issue.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions