@lezer/common 1.2.0 → 1.2.1

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/dist/index.cjs CHANGED
@@ -802,9 +802,11 @@ function getChildren(node, type, before, after) {
802
802
  if (!cur.firstChild())
803
803
  return result;
804
804
  if (before != null)
805
- while (!cur.type.is(before))
805
+ for (let found = false; !found;) {
806
+ found = cur.type.is(before);
806
807
  if (!cur.nextSibling())
807
808
  return result;
809
+ }
808
810
  for (;;) {
809
811
  if (after != null && cur.type.is(after))
810
812
  return result;
package/dist/index.js CHANGED
@@ -800,9 +800,11 @@ function getChildren(node, type, before, after) {
800
800
  if (!cur.firstChild())
801
801
  return result;
802
802
  if (before != null)
803
- while (!cur.type.is(before))
803
+ for (let found = false; !found;) {
804
+ found = cur.type.is(before);
804
805
  if (!cur.nextSibling())
805
806
  return result;
807
+ }
806
808
  for (;;) {
807
809
  if (after != null && cur.type.is(after))
808
810
  return result;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@lezer/common",
3
- "version": "1.2.0",
3
+ "version": "1.2.1",
4
4
  "description": "Syntax tree data structure and parser interfaces for the lezer parser",
5
5
  "main": "dist/index.cjs",
6
6
  "type": "module",