actboy168 / lua-debug

Lua Debug Adapter for Visual Studio Code
MIT License
437 stars 95 forks source link

Support for LuaJIT #53

Closed Qonsyuma closed 2 years ago

Qonsyuma commented 5 years ago

There has been made another use called "love2D support" by dpMerchant here, though support for LuaJIT would be very useful, as it is widely used (including love2D), and I was not able to find any other debugger that doesn't suck for VSCode :(

It would be nice for you to consider adding support for LuaJIT, but if it isn't possible, then we might just have to live with that :/

actboy168 commented 5 years ago

Lua differs from other popular languages in that the language core has very little support for debuggers. Especially for cross-version support, the more powerful the debugger, the more difficult it is. I can easily write a pure lua debugger compatible with 5.1-5.4, but this is not the debugger I want.

Although I don't currently have any plans to be compatible with luajit/lua5.1/lua5.2, I am rewriting the debug backend, which is written in 90% lua and 10% c++. The portability and compatibility of the new debug backend will be greatly improved, and it will be easier to port it to other versions.

I can't tell you now that it will support luajit, or not. But the focus of my work is still to provide a debugging experience close to other mature languages for lua5.3 and the upcoming lua5.4.

Qonsyuma commented 5 years ago

Alright, if JIT/other support gets added at some point I'd be glad, if not it's fine too, this debugger works quite well for teaching purposes too :)

tan-wei commented 5 years ago

If lua5.1 and lua5.2 ares supported in this plugin, it must be a good news for many people.

kahlkevin commented 5 years ago

If lua5.1 and lua5.2 ares supported in this plugin, it must be a good news for many people.

Yes! Wireshark is pinned at Lua 5.2 and looks to remain that way for the foreseeable future. I'd love to be able to use this excellent debugger with my in-progress wire protocol dissector.

tan-wei commented 5 years ago

@kahlkevin For now, you can try ZeroBraneStudio to debug Wireshark protocol dissector. Do you have ever try project wssdl to define a protocol? It's much convinient for a simple protocol. I have create a fork which adding a string to value printing feature: wssdl, you can checkout the branch field-valuestring. I am going to plan to add extra features.

actboy168 commented 2 years ago

Already supported.