import{__require as r}from"./function-uncurry-this.mjs";import{__require as e}from"./has-own-property.mjs";var n,t;function a(){if(t)return n;t=1;var a=r(),i=e(),o=SyntaxError,f=parseInt,s=String.fromCharCode,u=a("".charAt),c=a("".slice),h=a(/./.exec),w={'\\"':'"',"\\\\":"\\","\\/":"/","\\b":"\b","\\f":"\f","\\n":"\n","\\r":"\r","\\t":"\t"},l=/^[\da-f]{4}$/i,m=/^[\u0000-\u001F]$/;return n=function(r,e){for(var n=!0,t="";e<r.length;){var a=u(r,e);if("\\"===a){var p=c(r,e,e+2);if(i(w,p))t+=w[p],e+=2;else{if("\\u"!==p)throw new o('Unknown escape sequence: "'+p+'"');var d=c(r,e+=2,e+4);if(!h(l,d))throw new o("Bad Unicode escape at: "+e);t+=s(f(d,16)),e+=4}}else{if('"'===a){n=!1,e++;break}if(h(m,a))throw new o("Bad control character in string literal at: "+e);t+=a,e++}}if(n)throw new o("Unterminated string at: "+e);return{value:t,end:e}}}export{a as __require};