Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Unable to use color sensor color block inside a conditional block #736

Closed
abchatra opened this issue Jun 26, 2018 · 3 comments
Closed

Unable to use color sensor color block inside a conditional block #736

abchatra opened this issue Jun 26, 2018 · 3 comments
Assignees

Comments

@abchatra
Copy link
Contributor

To Reproduce
Steps to reproduce the behavior:

  1. Drag the 'color sensor color block'
  2. Try to drop into a 'condition'
  3. Pops out immediately.

Screenshots
ev3bug

Desktop (please complete the following information):

  • OS: Windows
  • Browser Edge
@riknoll
Copy link
Member

riknoll commented Jun 26, 2018

Ugh, I guess we'll finally have to overwrite the Blockly version of that block. I'm in favor of letting anything be compared with anything else but we'll need to do something about the error message that TypeScript generates. For example, this code:

if (0 === SpriteKind.Whatever) {
}

is fine but these examples:

if (SpriteKind.Whatever === SpriteKind.Okay) {
}


if (0 === 1) {
}

Both produce the message "operator '===' cannot be used between types 'whatever' and 'whatever'"

@riknoll riknoll self-assigned this Jul 2, 2018
@riknoll
Copy link
Member

riknoll commented Jul 3, 2018

Fixed by microsoft/pxt#4529

@abchatra
Copy link
Contributor Author

abchatra commented Sep 4, 2018

Fixed

@abchatra abchatra closed this as completed Sep 4, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants