Skip to content

Commit

Permalink
Adding test.
Browse files Browse the repository at this point in the history
  • Loading branch information
CyrusNajmabadi committed Feb 27, 2015
1 parent 27e8882 commit 7b7f497
Show file tree
Hide file tree
Showing 3 changed files with 25 additions and 0 deletions.
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
tests/cases/compiler/catchClauseWithBindingPattern1.ts(3,8): error TS1195: Catch clause variable name must be an identifier.


==== tests/cases/compiler/catchClauseWithBindingPattern1.ts (1 errors) ====
try {
}
catch ({a}) {
~
!!! error TS1195: Catch clause variable name must be an identifier.
}
11 changes: 11 additions & 0 deletions tests/baselines/reference/catchClauseWithBindingPattern1.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
//// [catchClauseWithBindingPattern1.ts]
try {
}
catch ({a}) {
}

//// [catchClauseWithBindingPattern1.js]
try {
}
catch (a = (void 0).a) {
}
4 changes: 4 additions & 0 deletions tests/cases/compiler/catchClauseWithBindingPattern1.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
try {
}
catch ({a}) {
}

0 comments on commit 7b7f497

Please sign in to comment.