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

Break after equal on assignment if rhs is await/yield expression #15204

Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
add test for delegated yield
  • Loading branch information
seiyab committed Aug 5, 2023
commit 6ac0033c91772b07ff67081fb197eaf915f8b1e2
3 changes: 3 additions & 0 deletions tests/format/js/assignment/__snapshots__/jsfmt.spec.js.snap
Original file line number Diff line number Diff line change
Expand Up @@ -305,6 +305,7 @@ function* g() {
const loooooooooooooooooooooooooong3 = yield looooooooooooooooooooooooooooooooooooooooooooog();
const loooooooooooooooooooooooooong4 = !(yield looooooooooooooong.looooooooooooooong.loooooong);
const loooooooooooooooooooooooooong5 = void !!(yield looooooooooooooong.looooooooooooooong.loooooong);
const loooooooooooooooooooooooooong6 = yield* looooooooooooooong.looooooooooooooong.loooooong;

const longlonglonglonglonglonglong1 = yield qwertyuiop(asdfghjkl, zxcvbnm, qwertyuiop, asdfghjkl);
const longlonglonglonglonglonglong2 = yield { qwertyuiop: 1234567890, asdfghjkl: 1234567890, zxcvbnm: 123456789 };
Expand Down Expand Up @@ -354,6 +355,8 @@ function* g() {
!(yield looooooooooooooong.looooooooooooooong.loooooong);
const loooooooooooooooooooooooooong5 =
void !!(yield looooooooooooooong.looooooooooooooong.loooooong);
const loooooooooooooooooooooooooong6 =
yield* looooooooooooooong.looooooooooooooong.loooooong;

const longlonglonglonglonglonglong1 = yield qwertyuiop(
asdfghjkl,
Expand Down
1 change: 1 addition & 0 deletions tests/format/js/assignment/discussion-15196.js
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@ function* g() {
const loooooooooooooooooooooooooong3 = yield looooooooooooooooooooooooooooooooooooooooooooog();
const loooooooooooooooooooooooooong4 = !(yield looooooooooooooong.looooooooooooooong.loooooong);
const loooooooooooooooooooooooooong5 = void !!(yield looooooooooooooong.looooooooooooooong.loooooong);
const loooooooooooooooooooooooooong6 = yield* looooooooooooooong.looooooooooooooong.loooooong;

const longlonglonglonglonglonglong1 = yield qwertyuiop(asdfghjkl, zxcvbnm, qwertyuiop, asdfghjkl);
const longlonglonglonglonglonglong2 = yield { qwertyuiop: 1234567890, asdfghjkl: 1234567890, zxcvbnm: 123456789 };
Expand Down