View Issue Details

IDProjectCategoryView StatusLast Update
0031145RunnerGeneralPublic2019-07-12 16:58
ReporterScott DunbarAssigned ToRussell Kay 
PriorityLowSeverityC - GeneralReproducibility100%
Status AssignedResolutionOpen 
Product Version2.2.3 
Target VersionFixed in Version 
Summary0031145: General: Post/Pre-Increment Left/Right Error on YYC
DescriptionIssue:
 YYC is handling pre/post increment of values differently than VM
Steps To Reproduce1. import project
2. run for vm
3. observe output is value of 1
4. run for YYC
5. observe output is value of 0
TagsNo tags attached.
1.4 Found In
2.x Runtime Found In2.2.3.341
2.x Runtime Verified In

Activities

Scott Dunbar

2019-07-08 13:55

Adminstrator  

prepostincrement.yyz (20,017 bytes)

Russell Kay

2019-07-12 16:58

Manager   ~0064418

I will have to think about this one as it boils down to how C++ and VM differ in handling the expression... basically both are correct in different ways and the expression itself is at fault

VM is stacking the intermediate answer from the --
while
C++ is performing both of the -- and then subtracting the answer (which the more I think about it is more correct).

I suspect this is due to the precedence rules in C++ (where the -- and ++ have higher precedence so get done first)