| // Copyright (C) 2016 the V8 project authors. All rights reserved. | |
| // This code is governed by the BSD license found in the LICENSE file. | |
| /*--- | |
| path: language/statements/try/dstr/ | |
| name: try statement | |
| esid: sec-runtime-semantics-catchclauseevaluation | |
| features: [destructuring-binding] | |
| info: | | |
| Catch : catch ( CatchParameter ) Block | |
| [...] | |
| 5. Let status be the result of performing BindingInitialization for | |
| CatchParameter passing thrownValue and catchEnv as arguments. | |
| [...] | |
| ---*/ | |
| var ranCatch = false; | |
| try { | |
| throw /*{ vals }*/; | |
| } catch (/*{ elems }*/) { | |
| /*{ body }*/ | |
| ranCatch = true; | |
| } | |
| assert(ranCatch, 'executed `catch` block'); |