Difference between ‘ and ” within Lua

Nope. No difference, except that you can enclose the other inside the ones that you are using. — No difference between these myStr = “Hi!!” myStr=”Hi!!” myStr = [[Hi!!]] — The ‘weird’ way to make a string literal IMO… — Double quotes enclosed in single quotes myStr=”My friend said: “Hi!!”” — Single quotes enclosed in … Read more

Lua operators, why isn’t +=, -= and so on defined?

This is just guesswork on my part, but: 1. It’s hard to implement this in a single-pass compiler Lua’s bytecode compiler is implemented as a single-pass recursive descent parser that immediately generates code. It does not parse to a separate AST structure and then in a second pass convert that to bytecode. This forces some … Read more

Safely remove items from an array table while iterating

the general case of iterating over an array and removing random items from the middle while continuing to iterate If you’re iterating front-to-back, when you remove element N, the next element in your iteration (N+1) gets shifted down into that position. If you increment your iteration variable (as ipairs does), you’ll skip that element. There … Read more

Hata!: SQLSTATE[HY000] [1045] Access denied for user 'divattrend_liink'@'localhost' (using password: YES)