melody icon indicating copy to clipboard operation
melody copied to clipboard

[FEATURE] Add compiler to IntelliJ plugin and add unicode category support

Open Tigermouthbear opened this issue 2 years ago โ€ข 6 comments

Description

I added a built-in compiler to the IntelliJ plugin, and added the ability to see the regex of the file while editing. I also added support for unicode categories. The compiler is compatible with all current melody features, however it does not have any specific error messages. Heres a screenshot of it working:

Type of change

  • [ ] ๐Ÿ’” Breaking
  • [x] ๐Ÿš€ Feature
  • [ ] ๐Ÿ› Fix
  • [ ] ๐Ÿ› ๏ธ Tooling
  • [ ] ๐Ÿงช Test
  • [ ] ๐Ÿ“ฆ Dependency
  • [ ] ๐Ÿ“– Requires documentation update

Tigermouthbear avatar Apr 29 '22 01:04 Tigermouthbear

Awesome work @Tigermouthbear!

Regarding the compiler - I really appreciate you doing this and it's awesome, but wouldn't it be better long term to use the actual compiler to avoid incompatibility?

Thanks!

yoav-lavi avatar Apr 29 '22 12:04 yoav-lavi

I'll see if its feasible to use the JNI to load the binary. The biggest challenge is that I'll have to compile the library for each supported platform and package it into the jar. Also, I need to check if intellij plugins are allowed to load into the JNI.

Tigermouthbear avatar Apr 29 '22 13:04 Tigermouthbear

Does Java / Kotlin support WASM? That may work

yoav-lavi avatar Apr 29 '22 14:04 yoav-lavi

not natively, but I might be able to use this Gradle plugin I found to transpile it into java code https://github.com/renatoathaydes/wasm-on-jvm

Tigermouthbear avatar Apr 29 '22 19:04 Tigermouthbear

Hey @Tigermouthbear, is this still relevant?

yoav-lavi avatar Jun 05 '22 22:06 yoav-lavi

sorry, I haven't been able to work much on this recently, but there is no native support for WASM on the JVM. I have tried a couple of WASM to JVM compilers, but I couldn't ever get them to work.

Tigermouthbear avatar Jun 06 '22 16:06 Tigermouthbear