1
0
Fork 0
mirror of https://github.com/Reuh/anselme.git synced 2025-10-28 00:59:31 +00:00
anselme/test/tests/remove duplicate spaces.lua
Étienne Reuh Fildadut f2e74c94c9 Changed a few things
* Integrated # and ~ decorators into the expression system. Created associated operators.
* # and ~ decorators only affect their current line. That's more useful...
* Fix our priority system to evaluate left-to-right instead of right-to-left (if there was a reason why I did it this way initially, I don't remember it so ¯\_(ツ)_/¯)
* a lotta internal changes

Various other small adjustments, see the diff of REFERENCE.md for details.
2021-11-28 01:43:54 +01:00

28 lines
No EOL
444 B
Lua

local _={}
_[10]={}
_[9]={}
_[8]={}
_[7]={text="c",tags=_[10]}
_[6]={text="",tags=_[10]}
_[5]={text="b ",tags=_[9]}
_[4]={text="a ",tags=_[8]}
_[3]={_[4],_[5],_[6],_[7]}
_[2]={"return"}
_[1]={"text",_[3]}
return {_[1],_[2]}
--[[
{ "text", { {
tags = {},
text = "a "
}, {
tags = {},
text = "b "
}, {
tags = <1>{},
text = ""
}, {
tags = <table 1>,
text = "c"
} } }
{ "return" }
]]--