Issue Details (XML | Word | Printable)

Key: PCC-354
Type: Bug Bug
Status: Resolved Resolved
Resolution: Fixed
Priority: Trivial Trivial
Assignee: Anders Magnusson
Reporter: TAKAHASHI Tamotsu
Votes: 0
Watchers: 0
Operations

If you were logged in you would be able to see more operations.
pcc

Bool ++/-- postfix is the same as prefix

Created: 10/Jun/11 09:10 AM   Updated: 06/Jul/11 07:02 PM
Component/s: C frontend
Affects Version/s: None
Fix Version/s: None

File Attachments: 1. File bool.diff (1 kB)



 Description  « Hide
   int main()
   {
    _Bool b = 0;
    if (b++)
    return 1;
    return 0;
   }

returns 1.
Note that b is incremented by the postfix.



 All   Comments   Change History      Sort Order: Descending order - Click to sort in ascending order
Anders Magnusson added a comment - 06/Jul/11 07:02 PM
Great and thanks for your patch! I've applied it with a slight change.