-
Notifications
You must be signed in to change notification settings - Fork 75
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Some suggestions for future development #149
Comments
Hey, sorry for the delay... your suggestions make sense.
yes, a configuration parameter should help, right?
ouch, yes, definitely!
Yep, we can actually move that part out of the lisp source and put it into
Temporary files are indeed not quite portable, that's why I removed the temporary files-based approach when I started working on lua-mode and was reluctant to add it back. Regarding reading Another option would be to implement the "protocol" as a multi-part interface in which
It may work, but I'd really like to discuss the implementation before it is done, because it could prove to be a significant effort and I don't want it to go to waste because of not being on the same page. |
I may tackle some of these myself, assuming I find some free time, but in the meantime I thought it'd be useful if I posted a list of things that annoy me here (maybe others can strike some of these off):
compilation-shell-minor mode usage should be completely optional. Switching it on without an option is not kosher. Worse, advising compilation-* functions on lua-mode.el load is unacceptable!
comint-prompt-regexp should be set inside lua-start-process, with setq-local. Right now it's done inside define-derived-mode and the global comint-prompt-regexp is overwritten (not good).
There is no reason for lua-process-init-code to be this convoluted. There's no need for (mapconcat 'identity ...) there, a multiline Lisp string will do just fine with the following diff in lua-start-process:
The current way that the code is sent to the process is too convoluted and breaks with process-send-string limits. Temporary files are a kludge and don't work over sockets. A much better way is to have luamode_loadstring call io:read() in a loop until it hits a delimiter. A proper input/output protocol can be defined that works over that channel.
Go one step further, and get rid of the `lineno' kludge by splitting the output from the process into normal output and error output on top of the previously mentioned protocol. These two separate streams should be multiplexed over the common channel and post-processing applied to the error output to fix the line number (when needed). For a local lua process, this means that stderr will not be used at all. All output will be multiplexed on top of stdout.
The text was updated successfully, but these errors were encountered: