ts2c
ts2c copied to clipboard
Ain't work
`var indices = [1, 2, 3]; var values = ["1", "2", "3"]; var obj = { }; for(var x = 0; x < indices.length; x++) { obj[indices[x]] = values[x]; }
for(var y = 0; y < indices.length; y++) { console.log(obj[indices[y]]); }`
aha, I see, you are trying to use an empty object ({}
) but this doesn't support those currently as it says Unsupported use of object literal expression
as a comment in the generated C source code.