Open Zash opened 7 years ago
You're right; there appears to be a bug in the compiler for the :
operator.
As a workaround, it works when you wrap the first member-call in brackets (although this should make no difference to Lua):
(s:lower()):gsub("a", "b")
This is a completely nonsense report, something is clearly broken here:
("a"):gsub("a", "b"):lower()
attempt to index '(string, integer)' with '"lower"'
should be equivalent to
string.gsub(s:lower(), "a", "b")
andstring.gsub(string.lower(s), "a", "b")
but gives atype error
.