var r="><+-.,[]".split("");const o={name:"brainfuck",startState:function(){return{commentLine:!1,left:0,right:0,commentLoop:!1}},token:function(n,t){if(n.eatSpace())return null;n.sol()&&(t.commentLine=!1);var e=n.next().toString();if(r.indexOf(e)!==-1){if(t.commentLine===!0)return n.eol()&&(t.commentLine=!1),"comment";if(e==="]"||e==="[")return e==="["?t.left++:t.right++,"bracket";if(e==="+"||e==="-")return"keyword";if(e==="<"||e===">")return"atom";if(e==="."||e===",")return"def"}else return t.commentLine=!0,n.eol()&&(t.commentLine=!1),"comment";n.eol()&&(t.commentLine=!1)}};export{o as t};
