Skip to content
This repository has been archived by the owner on May 31, 2020. It is now read-only.

fix: Added fix for lshift and rshift #526

Merged
merged 5 commits into from
May 24, 2017
Merged

Conversation

shortdiv
Copy link
Contributor

@shortdiv shortdiv commented May 22, 2017

This removes an expected failure and makes rshift and lshift work with Booleans.

cc @toastdriven

@@ -515,6 +515,12 @@ Bool.prototype.__lshift__ = function(other) {
return new types.Int(0)
}
} else if (types.isinstance(other, types.Int)) {
if(other.valueOf() < 0) {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The linter is probably going to yell at you about having spaces after if (here and below).

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for catching that! Updating code...

Copy link
Contributor

@swenson swenson left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This LGTM, aside from probably linter stuff :)

@glasnt
Copy link
Member

glasnt commented May 24, 2017

I've just pushed a fix for the linting issues. Will merge when CI goes green

@glasnt glasnt merged commit 2f22821 into beeware:master May 24, 2017
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants