-
Notifications
You must be signed in to change notification settings - Fork 63
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Maximum call stack size exceeded #111
Comments
+1 |
From what I can tell this is being caused by the recursion in Out of memory example function isExteriorRing() {
var rings = [this]
var idx = 0;
while(rings[idx]._isExteriorRing === undefined) {
var enclosing = rings[idx].enclosingRing();
if (enclosing) {
rings.push(enclosing);
idx++;
} else {
rings[idx]._isExteriorRing = true;
}
}
for(let i=rings.length-2; i>=0; i--) {
rings[i]._isExteriorRing = !rings[i+1]._isExteriorRing;
}
return this._isExteriorRing;
}
} Infinite loop example function isExteriorRing() {
if (this._isExteriorRing === undefined) {
var ring = this
var idx = 0;
while(ring._isExteriorRing === undefined) {
var enclosing = ring.enclosingRing();
if (enclosing) {
ring = enclosing;
idx++;
} else {
ring._isExteriorRing = true;
}
}
this._isExteriorRing = ring._isExteriorRing;
for(let i=0; i<idx; i++) {
this._isExteriorRing = !this._isExteriorRing;
}
}
return this._isExteriorRing;
} |
Have been repeatedly hitting a
Maximum call stack size exceeded
when trying to perform a union operation on a multi-polygon:Below are the additional and original geometries. The original multi-polygon seems to be the source of the error (as I've attempted the union with a several additional regions, all of which return this call stack error). Curious what could be causing call stack error for this case?
The text was updated successfully, but these errors were encountered: