Because strings are iterable, TS supports destructuring them into individual characters:
const [a, b] = "test"; // a = "t" ; b = "e";
We currently do not support that in TSTL.
We should think about adding support for handling strings in restructuring assignments. At the very least, we should throw a diagnostic that this currently does not work.
Current behavior:
https://typescripttolua.github.io/play/#code/GYVwdgxgLglg9mABMOcAUUAWMDOAuRANzhgBMBKAnKAJxjAHNEBvAKEQ8RoFMoQakAIijdqggNysAvq1YQE1RAG0AhgBpEAIwC6iALzJUacpNYAHOmChp1Wk0A
Epected behaviour a = "t", b = "e";
https://www.typescriptlang.org/play?#code/GYVwdgxgLglg9mABMOcAUUAWMDOAuRANzhgBMBKAnKAJxjAHNEBvAKEQ8RoFMoQakAIijdqggNysAvq1YQE1RAG0AhgBpEAIwC6iALzJUacpLkK4AG24A6C3AZp1Wk0A
Discovered while fixing #1411