UNPKG

cream-and-sugar

Version:

A deliciously functional syntax for JavaScript with native support for JSX

10 lines (8 loc) 367 B
'use strict'; var _utils = require('../utils'); /* * Handle trye/catch */ (0, _utils.compile)(_utils.nodes.TryCatchNode, function () { return '(function () {\n try {\n ' + (0, _utils.compileBody)(this.attempt) + ';\n } catch (' + this.errName.compile(true) + ') {\n ' + (0, _utils.compileBody)(this.fallback) + ';\n }\n }.bind(this)())'; });