goldstein 5.0.2 → 5.1.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/ChangeLog CHANGED
@@ -1,3 +1,8 @@
1
+ 2024.02.19, v5.1.0
2
+
3
+ feature:
4
+ - c329ff0 goldstein: printer: visitors: try-statememnt: improve support
5
+
1
6
  2024.02.19, v5.0.2
2
7
 
3
8
  feature:
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "goldstein",
3
- "version": "5.0.2",
3
+ "version": "5.1.0",
4
4
  "type": "module",
5
5
  "author": "coderaiser <mnemonic.enemy@gmail.com> (https://github.com/coderaiser)",
6
6
  "description": "JavaScript with no limits",
@@ -1,11 +1,14 @@
1
- import {visitors as v} from '@putout/printer';
1
+ import {
2
+ visitors as v,
3
+ maybeVisitor,
4
+ } from '@putout/printer';
2
5
 
3
6
  export const TryStatement = (path, printer, semantics) => {
4
7
  const {maybe, print} = printer;
5
8
  const {node} = path;
6
9
 
7
10
  if (!node.expression)
8
- return v.TryStatement(path, printer, semantics);
11
+ return maybeVisitor(v.TryStatement, path, printer, semantics);
9
12
 
10
13
  print('try ');
11
14
  maybe.print(node.async, 'await ');