firescript
Version:
Firescript language
34 lines (26 loc) • 395 B
Markdown
try...catch
=========
The `try...catch` statement marks a block of statements to try. If an `Error` gets thrown within a `try` block the `catch` block is evaluated.
Syntax
------
```
try
[]
catch err
[]
```
```fire
try
db.connect()
catch err
console.log(err)
```
```js
try {
db.connect();
} catch (err) {
console.log(err);
}
```