import{i as r}from"./p-BJQylLSL.js";import{i as t}from"./p-BOEi1C7r.js";var i=/\s/,f=/^\s+/;var n=/^[-+]0x[0-9a-f]+$/i,a=/^0b[01]+$/i,o=/^0o[0-7]+$/i,e=parseInt;function p(p){if("number"==typeof p)return p;if(t(p))return NaN;if(r(p)){var s="function"==typeof p.valueOf?p.valueOf():p;p=r(s)?s+"":s}if("string"!=typeof p)return 0===p?p:+p;var u;p=(u=p)?u.slice(0,function(r){for(var t=r.length;t--&&i.test(r.charAt(t)););return t}(u)+1).replace(f,""):u;var v=a.test(p);return v||o.test(p)?e(p.slice(2),v?2:8):n.test(p)?NaN:+p}export{p as t}