import{Va as g,a,b as u,c,d as l,e as m,f as C,fb as p,jb as S,lb as v}from"./chunk-RKHDN2Z7.mjs";var n=class extends v{static{a(this,"RailroadPegTokenBuilder")}constructor(){super(["railroad-peg-beta"])}};var f=a(d=>{let e=d.slice(1,-1),r="";for(let t=0;t<e.length;t++){let i=e[t];if(i==="\\"&&t+1<e.length){t++;let o=e[t];switch(o){case"n":r+=`
`;break;case"r":r+="\r";break;case"t":r+="	";break;default:r+=o}continue}r+=i}return r},"decodeEscapedString"),s=class extends S{static{a(this,"RailroadPegValueConverter")}runConverter(e,r,t){let i=super.runConverter(e,r,t);if(e.name==="TITLE"&&typeof i=="string"){let o=i.trim();if(o.startsWith('"')&&o.endsWith('"')||o.startsWith("'")&&o.endsWith("'"))return f(o)}return i}runCustomConverter(e,r,t){if(e.name==="PEG_STRING")return f(r)}};var R={parser:{TokenBuilder:a(()=>new n,"TokenBuilder"),ValueConverter:a(()=>new s,"ValueConverter")}};function V(d=m){let e=l(c(d),g),r=l(u({shared:e}),p,R);return e.ServiceRegistry.register(r),{shared:e,RailroadPeg:r}}a(V,"createRailroadPegServices");export{R as a,V as b};
