Title: TSTL generates unrechable code when converts 'continue' statement on Lua 5.1 · Issue #1638 · TypeScriptToLua/TypeScriptToLua · GitHub
Open Graph Title: TSTL generates unrechable code when converts 'continue' statement on Lua 5.1 · Issue #1638 · TypeScriptToLua/TypeScriptToLua
X Title: TSTL generates unrechable code when converts 'continue' statement on Lua 5.1 · Issue #1638 · TypeScriptToLua/TypeScriptToLua
Description: Here's example of TS code: while (true) continue; Here's generated code: --[[ Generated with https://github.com/TypeScriptToLua/TypeScriptToLua ]] while true do do local __continue2 repeat __continue2 = true break __continue2 = true unti...
Open Graph Description: Here's example of TS code: while (true) continue; Here's generated code: --[[ Generated with https://github.com/TypeScriptToLua/TypeScriptToLua ]] while true do do local __continue2 repeat __contin...
X Description: Here's example of TS code: while (true) continue; Here's generated code: --[[ Generated with https://github.com/TypeScriptToLua/TypeScriptToLua ]] while true do do local __continue2 repeat ...
Opengraph URL: https://github.com/TypeScriptToLua/TypeScriptToLua/issues/1638
X: @github
Domain: github.com
{"@context":"https://schema.org","@type":"DiscussionForumPosting","headline":"TSTL generates unrechable code when converts 'continue' statement on Lua 5.1","articleBody":"Here's example of TS code:\n```ts\nwhile (true) continue;\n```\n\nHere's generated code:\n```lua\n--[[ Generated with https://github.com/TypeScriptToLua/TypeScriptToLua ]]\nwhile true do\n do\n local __continue2\n repeat\n __continue2 = true\n break\n __continue2 = true\n until true\n if not __continue2 then\n break\n end\n end\nend\n```\n\nTSTL generated unneeded `__continue2 = true` after `break` statement.","author":{"url":"https://github.com/inklesspen1rus","@type":"Person","name":"inklesspen1rus"},"datePublished":"2025-06-02T12:42:01.000Z","interactionStatistic":{"@type":"InteractionCounter","interactionType":"https://schema.org/CommentAction","userInteractionCount":1},"url":"https://github.com/1638/TypeScriptToLua/issues/1638"}
| route-pattern | /_view_fragments/issues/show/:user_id/:repository/:id/issue_layout(.:format) |
| route-controller | voltron_issues_fragments |
| route-action | issue_layout |
| fetch-nonce | v2:bb55d32b-90e0-d67f-4960-9d055a35848b |
| current-catalog-service-hash | 81bb79d38c15960b92d99bca9288a9108c7a47b18f2423d0f6438c5b7bcd2114 |
| request-id | E394:398ED3:19DC5A6:237DF79:6973471E |
| html-safe-nonce | c9df7e9ec2a952d7cef16d4032bbcc4171c65fa34730e80a7f061a17bf16eb6c |
| visitor-payload | eyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiJFMzk0OjM5OEVEMzoxOURDNUE2OjIzN0RGNzk6Njk3MzQ3MUUiLCJ2aXNpdG9yX2lkIjoiMTI0Mjc5MzkwNzQ5ODIwNzAwNyIsInJlZ2lvbl9lZGdlIjoiaWFkIiwicmVnaW9uX3JlbmRlciI6ImlhZCJ9 |
| visitor-hmac | f1b2770ed932fd466ee93e1a1d6e86c3d1360576d920d9e11fb2a2eea9c5ff10 |
| hovercard-subject-tag | issue:3110028482 |
| github-keyboard-shortcuts | repository,issues,copilot |
| google-site-verification | Apib7-x98H0j5cPqHWwSMm6dNU4GmODRoqxLiDzdx9I |
| octolytics-url | https://collector.github.com/github/collect |
| analytics-location | / |
| fb:app_id | 1401488693436528 |
| apple-itunes-app | app-id=1477376905, app-argument=https://github.com/_view_fragments/issues/show/TypeScriptToLua/TypeScriptToLua/1638/issue_layout |
| twitter:image | https://opengraph.githubassets.com/ae91986ba540c901512d9b8d58b3e0d2a6a2ce64269a94e010e077d81886439a/TypeScriptToLua/TypeScriptToLua/issues/1638 |
| twitter:card | summary_large_image |
| og:image | https://opengraph.githubassets.com/ae91986ba540c901512d9b8d58b3e0d2a6a2ce64269a94e010e077d81886439a/TypeScriptToLua/TypeScriptToLua/issues/1638 |
| og:image:alt | Here's example of TS code: while (true) continue; Here's generated code: --[[ Generated with https://github.com/TypeScriptToLua/TypeScriptToLua ]] while true do do local __continue2 repeat __contin... |
| og:image:width | 1200 |
| og:image:height | 600 |
| og:site_name | GitHub |
| og:type | object |
| og:author:username | inklesspen1rus |
| hostname | github.com |
| expected-hostname | github.com |
| None | 9c6b49fea3d431063963fbeee3309a15cb4096903286e532f663096b47b63bc6 |
| turbo-cache-control | no-preview |
| go-import | github.com/TypeScriptToLua/TypeScriptToLua git https://github.com/TypeScriptToLua/TypeScriptToLua.git |
| octolytics-dimension-user_id | 44121206 |
| octolytics-dimension-user_login | TypeScriptToLua |
| octolytics-dimension-repository_id | 115876595 |
| octolytics-dimension-repository_nwo | TypeScriptToLua/TypeScriptToLua |
| octolytics-dimension-repository_public | true |
| octolytics-dimension-repository_is_fork | false |
| octolytics-dimension-repository_network_root_id | 115876595 |
| octolytics-dimension-repository_network_root_nwo | TypeScriptToLua/TypeScriptToLua |
| turbo-body-classes | logged-out env-production page-responsive |
| disable-turbo | false |
| browser-stats-url | https://api.github.com/_private/browser/stats |
| browser-errors-url | https://api.github.com/_private/browser/errors |
| release | 814e1d7d82db0f7eb6982bfa0395502441bb14ad |
| ui-target | full |
| theme-color | #1e2327 |
| color-scheme | light dark |
Links:
Viewport: width=device-width