LiteIDE suggestion (avoid auto-mangling of code!)


I’ve noticed an oddity in the LiteIDE editor that mangles some code (see example, below). If using LiteIDE, might be good to turn off “Automatically format code when saving”?
The option is well-hidden under: View->Options->GolangFmt

Example (duplicacy_backupmanager_test.go):
What it should be:

backupManager.Restore(testDir+"/repository2", threads, /*inPlace=*/false, /*quickMode=*/false, threads, /*overwrite=*/true,
    /*deleteMode=*/false, /*setowner=*/false, /*showStatistics=*/false, /*patterns=*/ nil)

Here’s what auto-format on save does if you modify & save the file (note the comma placement relative to the inline comments):

backupManager.Restore(testDir+"/repository2", threads /*inPlace=*/, false /*quickMode=*/, false, threads /*overwrite=*/, true,
    /*deleteMode=*/ false /*setowner=*/, false /*showStatistics=*/, false /*patterns=*/, nil)

I think this one or ones like it have made it into the master branch, too, on GitHub.
Thoughts? Opinions?


Haven’t used LiteIDE, only GoLand: A Clever IDE to Go by JetBrains, but i have never had this problems.
Imo you should open a bug on their github about this problem.


Good point @TheBestPessimist! I just did so. Thanks for the advice!
Though turning off the feature solves the problem for me. (Don’t like it anyway, since auto-reformatting messes with Git.)
May have to look at Jetbrains eventually but wanted to start with something, well… lite :wink:


Oh, GoLand is anything but that