import{__require as r}from"./an-object.mjs";import{__require as e}from"./function-call.mjs";import{__require as t}from"./iterator-create-proxy.mjs";import{__require as i}from"./create-iter-result-object.mjs";import{__require as o}from"./get-iterator-direct.mjs";import{__require as n}from"./iterator-close.mjs";import{__require as u}from"./function-uncurry-this.mjs";var a,s;function f(){if(s)return a;s=1;var f=r(),m=e(),l=t(),c=i(),_=o(),h=n(),w=u(),p=RangeError,d=TypeError,j=w([].push),g=w([].slice),q="allow-partial",b=l(function(){for(var r,e,t=this.iterator,i=this.next,o=this.buffer,n=this.windowSize,u=this.allowPartial;;){if(r=f(m(i,t)),e=this.done=!!r.done,u&&e&&o.length&&o.length<n)return c(o,!1);if(e)return c(void 0,!0);if(o.length===n&&(this.buffer=o=g(o,1)),j(o,r.value),o.length===n)return c(o,!1)}},!1,!0);return a=function(r,e,t){return f(r),"number"==typeof e&&e&&e>>>0===e?void 0!==t&&"only-full"!==t&&t!==q?h(r,"throw",new d("Incorrect `undersized` argument")):new b(_(r),{windowSize:e,buffer:[],allowPartial:t===q}):h(r,"throw",new p("`windowSize` must be integer in [1, 2^32-1]"))}}export{f as __require};