@speclynx/apidom-parser-adapter-openapi-yaml-3-1 4.7.1 → 4.8.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.md CHANGED
@@ -3,6 +3,10 @@
3
3
  All notable changes to this project will be documented in this file.
4
4
  See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
5
5
 
6
+ # [4.8.0](https://github.com/speclynx/apidom/compare/v4.7.1...v4.8.0) (2026-04-17)
7
+
8
+ **Note:** Version bump only for package @speclynx/apidom-parser-adapter-openapi-yaml-3-1
9
+
6
10
  ## [4.7.1](https://github.com/speclynx/apidom/compare/v4.7.0...v4.7.1) (2026-04-16)
7
11
 
8
12
  **Note:** Version bump only for package @speclynx/apidom-parser-adapter-openapi-yaml-3-1
@@ -53202,10 +53202,12 @@ function* traverseGenerator(root, visitor, options) {
53202
53202
  nodePredicate,
53203
53203
  nodeCloneFn,
53204
53204
  detectCycles,
53205
+ skipVisited,
53205
53206
  mutable,
53206
53207
  mutationFn
53207
53208
  } = options;
53208
53209
  const keyMapIsFunction = typeof keyMap === 'function';
53210
+ const visitedNodes = skipVisited ? new WeakSet() : null;
53209
53211
  let stack;
53210
53212
  let inArray = Array.isArray(root);
53211
53213
  let keys = [root];
@@ -53291,6 +53293,14 @@ function* traverseGenerator(root, visitor, options) {
53291
53293
  continue;
53292
53294
  }
53293
53295
 
53296
+ // Skip already-visited nodes (handles DAG structures from cloneShallow)
53297
+ if (skipVisited && !isLeaving) {
53298
+ if (visitedNodes.has(node)) {
53299
+ continue;
53300
+ }
53301
+ visitedNodes.add(node);
53302
+ }
53303
+
53294
53304
  // Always create Path for the current node (needed for parentPath chain)
53295
53305
  currentPath = new _Path_mjs__WEBPACK_IMPORTED_MODULE_2__.Path(node, parent, parentPath, key, inArray);
53296
53306
  const visitFn = (0,_visitors_mjs__WEBPACK_IMPORTED_MODULE_3__.getVisitFn)(visitor, nodeTypeGetter(node), isLeaving);
@@ -53434,6 +53444,7 @@ const traverse = (root, visitor, options = {}) => {
53434
53444
  nodePredicate: options.nodePredicate ?? _visitors_mjs__WEBPACK_IMPORTED_MODULE_3__.isNode,
53435
53445
  nodeCloneFn: options.nodeCloneFn ?? _visitors_mjs__WEBPACK_IMPORTED_MODULE_3__.cloneNode,
53436
53446
  detectCycles: options.detectCycles ?? true,
53447
+ skipVisited: options.skipVisited ?? false,
53437
53448
  mutable: options.mutable ?? false,
53438
53449
  mutationFn: options.mutationFn ?? _visitors_mjs__WEBPACK_IMPORTED_MODULE_3__.mutateNode
53439
53450
  };
@@ -53465,6 +53476,7 @@ const traverseAsync = async (root, visitor, options = {}) => {
53465
53476
  nodePredicate: options.nodePredicate ?? _visitors_mjs__WEBPACK_IMPORTED_MODULE_3__.isNode,
53466
53477
  nodeCloneFn: options.nodeCloneFn ?? _visitors_mjs__WEBPACK_IMPORTED_MODULE_3__.cloneNode,
53467
53478
  detectCycles: options.detectCycles ?? true,
53479
+ skipVisited: options.skipVisited ?? false,
53468
53480
  mutable: options.mutable ?? false,
53469
53481
  mutationFn: options.mutationFn ?? _visitors_mjs__WEBPACK_IMPORTED_MODULE_3__.mutateNode
53470
53482
  };