Issue Details (XML | Word | Printable)

Key: BOO-1123
Type: Improvement Improvement
Status: Resolved Resolved
Resolution: Fixed
Priority: Minor Minor
Assignee: Cedric Vivier
Reporter: Cedric Vivier
Votes: 0
Watchers: 0
Operations

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

WARNING: Assignment/Comparison made to/with same expression.

Created: 20/Jan/09 02:13 AM   Updated: 21/Jan/09 04:58 AM   Resolved: 21/Jan/09 04:58 AM
Return to search
Component/s: Compiler
Affects Version/s: 0.8.2
Fix Version/s: 0.9

Time Tracking:
Not Specified

File Attachments: 1. Text File BOO-1123-1.patch (11 kB)


Testcase included: yes


 Description  « Hide
Test.Foo = Test.Foo
print "what?" if Test.Foo == Test.Foo

Should issue:

BCW0020: WARNING: Assignment made to same expression. Did you mean to assign to something else?
BCW0021: WARNING: Comparison made with same expression. Did you mean to compare with something else?



Cedric Vivier added a comment - 20/Jan/09 04:37 AM

I have patch ready but I have some weird problem when building PatternMatching (and PatternMatching only, ie. Extensions and Useful build fine for instance) :

I've changed ast.model.boo to set explicit values to BinaryOperatorType such as we can have a BinaryOperatorMask enum in order to more efficiently compare an operator to an operator group/kind (instead of a flurry of "|| ... ||").
For some reason PatternMatching build fails cause it seems to use the old values before that change but I cannot see how and why is it the only one to do this. Any ideas??


Cedric Vivier added a comment - 20/Jan/09 04:39 AM

Attached the patch so that you guys can try it. There must be something very stupid I overlook :-s


Cedric Vivier added a comment - 21/Jan/09 04:58 AM

Landed in rev. 3146