ID:2816779
 
BYOND Version:514
Operating System:Windows 10 Home 64-bit
Web Browser:Firefox 104.0
Applies to:Dream Maker
Status: Open

Issue hasn't been assigned a status value.
Descriptive Problem Summary:

Numbered Steps to Reproduce Problem:

Code Snippet (if applicable) to Reproduce Problem:
/proc/main()
var/test = max(null,0)
if(test == null)
world.log << "null"
if(test == 0)
world.log << "0"

test = max(0,null)
if(test == null)
world.log << "null"
if(test == 0)
world.log << "0"


Expected Results:
For both max(0,null) and max(null,0) to be 0; the documentation states that nulls evaluate to "0" in a numeric context, such as mathematical operations like "max".

Actual Results:
max(0,null) is null, max(null,0) is 0; the results are different depending on order

Does the problem occur:
Every time? Or how often? Every time
In other games? All Games
In other user accounts? All Users
On other computers? All computers

When does the problem NOT occur?
Never

Did the problem NOT occur in any earlier versions? If so, what was the last version that worked?
Unknown

Workarounds:
Unknown
identical behavior for min

If this is a non-bug I'd like to request the min and max ref docs get a new little blurb clarifying this behavior

/proc/main()
world.log << min(0,null)
world.log << min(null,0)