UNPKG

openclaw

Version:

Multi-channel AI gateway with extensible messaging integrations

2 lines 2.46 kB
import{n as e}from"./rolldown-runtime-DkW27tQK.js";function t(e){for(var t;t=e.next();)if(t==`\\`)e.next();else if(!c.test(t)){e.backUp(1);break}return e.current()}function n(e,n){if(e.eatSpace())return l=`ws`,null;if(e.match(s))return`number`;var c=e.next();if(c==`\\`&&(c=e.next()),c==`"`)return(n.tokenize=r)(e,n);if(c==`(`)return l=`open`,`bracket`;if(c==`)`)return l=`close`,`bracket`;if(c==`;`)return e.skipToEnd(),l=`ws`,`comment`;if(/['`,@]/.test(c))return null;if(c==`|`)return e.skipTo(`|`)?(e.next(),`variableName`):(e.skipToEnd(),`error`);if(c==`#`){var c=e.next();return c==`(`?(l=`open`,`bracket`):/[+\-=\.']/.test(c)||/\d/.test(c)&&e.match(/^\d*#/)?null:c==`|`?(n.tokenize=i)(e,n):c==`:`?(t(e),`meta`):c==`\\`?(e.next(),t(e),`string.special`):`error`}var u=t(e);return u==`.`?null:(l=`symbol`,u==`nil`||u==`t`||u.charAt(0)==`:`?`atom`:n.lastType==`open`&&(a.test(u)||o.test(u))?`keyword`:u.charAt(0)==`&`?`variableName.special`:`variableName`)}function r(e,t){for(var r=!1,i;i=e.next();){if(i==`"`&&!r){t.tokenize=n;break}r=!r&&i==`\\`}return`string`}function i(e,t){for(var r,i;r=e.next();){if(r==`#`&&i==`|`){t.tokenize=n;break}i=r}return l=`ws`,`comment`}var a,o,s,c,l,u;function d(){return(d=e((()=>{a=/^(block|let*|return-from|catch|load-time-value|setq|eval-when|locally|symbol-macrolet|flet|macrolet|tagbody|function|multiple-value-call|the|go|multiple-value-prog1|throw|if|progn|unwind-protect|labels|progv|let|quote)$/,o=/^with|^def|^do|^prog|case$|^cond$|bind$|when$|unless$/,s=/^(?:[+\-]?(?:\d+|\d*\.\d+)(?:[efd][+\-]?\d+)?|[+\-]?\d+(?:\/[+\-]?\d+)?|#b[+\-]?[01]+|#o[+\-]?[0-7]+|#x[+\-]?[\da-f]+)/,c=/[^\s'`,@()\[\]";]/,u={name:`commonlisp`,startState:function(){return{ctx:{prev:null,start:0,indentTo:0},lastType:null,tokenize:n}},token:function(e,t){e.sol()&&typeof t.ctx.indentTo!=`number`&&(t.ctx.indentTo=t.ctx.start+1),l=null;var n=t.tokenize(e,t);return l!=`ws`&&(t.ctx.indentTo==null?l==`symbol`&&o.test(e.current())?t.ctx.indentTo=t.ctx.start+e.indentUnit:t.ctx.indentTo=`next`:t.ctx.indentTo==`next`&&(t.ctx.indentTo=e.column()),t.lastType=l),l==`open`?t.ctx={prev:t.ctx,start:e.column(),indentTo:null}:l==`close`&&(t.ctx=t.ctx.prev||t.ctx),n},indent:function(e){var t=e.ctx.indentTo;return typeof t==`number`?t:e.ctx.start+1},languageData:{commentTokens:{line:`;;`,block:{open:`#|`,close:`|#`}},closeBrackets:{brackets:[`(`,`[`,`{`,`"`]}}}})))()}d();export{u as commonLisp}; //# sourceMappingURL=commonlisp-BkuaFBi8.js.map