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

dart2js in non-minified mode should emit extra parens to make precedence plain #6666

Closed
rakudrama opened this issue Nov 12, 2012 · 5 comments
Labels
closed-not-planned Closed as we don't intend to take action on the reported issue P2 A bug or feature request we're likely to work on P3 A lower priority bug or feature request type-enhancement A request for a change that isn't a bug web-dart2js

Comments

@rakudrama
Copy link
Member

dart2js 'readable mode', i.e. when --minify is not specified, should emit parens to make the precedence of the operators clear to the programmer who has to read the emitted JavaScript.

This will be especially useful when Issue #114 is addressed since the precedence of operators in Dart code will be different to the generated JavaScript.

The operators have several natural families, e.g.

  1. *,%,/; +,-; <,<=,>,>=; ==,!=; &&; ||;
  2. <<,>>; |; &
  3. ^

The confusion generally occurs when expressions have operators from different families.

@peter-ahe-google
Copy link
Contributor

Added this to the Later milestone.

@kasperl
Copy link

kasperl commented May 23, 2013

Added TriageForM5 label.

@kasperl
Copy link

kasperl commented May 28, 2013

Removed TriageForM5 label.

@kasperl
Copy link

kasperl commented Jul 10, 2014

Removed this from the Later milestone.
Added Oldschool-Milestone-Later label.

@kasperl
Copy link

kasperl commented Aug 4, 2014

Removed Oldschool-Milestone-Later label.

@sigmundch sigmundch added type-enhancement P3 A lower priority bug or feature request and removed Type-Defect labels Dec 10, 2015
@kevmoo kevmoo added P2 A bug or feature request we're likely to work on type-enhancement A request for a change that isn't a bug and removed triaged labels Feb 29, 2016
@sigmundch sigmundch added the closed-not-planned Closed as we don't intend to take action on the reported issue label Jun 28, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
closed-not-planned Closed as we don't intend to take action on the reported issue P2 A bug or feature request we're likely to work on P3 A lower priority bug or feature request type-enhancement A request for a change that isn't a bug web-dart2js
Projects
None yet
Development

No branches or pull requests

5 participants