Hello, is it possible to check whether a macro exists (or - is it a non-\undefined control sequence) with Lua? Suppose: ---- \starttext \def\MyMacro{Ahoj} \def\MyMac#1#2{Something} \startluacode IsDefined = function(ctl_seq) print("CS " .. ctl_seq .. (tex.IsCS(ctl_seq) -- Or what to come here? "is defined" or "is unknown") .. ".") end -- So the function should print to the console: IsDefined("MyMacro") --> "CS MyMacro is defined." IsDefined("MyMac") --> "CS MyMac is defined." IsDefined("bf") --> "CS bf is defined." IsDefined("dummy") --> "CS dummy is unknown." \stopluacode \stoptext ---- Is it possible? Best regards, Lukas