-
-
Notifications
You must be signed in to change notification settings - Fork 649
command for macroexpanding the expression #1
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
Conversation
Looks good, thank you! |
Hi Alexander, When you have some time, please give it a spin and let me know what you think? Again, thanks for the pull request! |
Hello Tim, Though I can't get the changed macroexpansion working. First of all, in the nrepl-macroexpand-last-sexp there is a error in process filter: Wrong number of arguments: ((nrepl-input-start-mark nrepl-prompt-start-mark t) (buffer value) (with-current-buffer buffer (let ((inhibit-read-only t) (buffer-undo-list t)) (erase-buffer) (insert (format "%s" value)) (goto-char (point-min)) (indent-sexp) (font-lock-fontify-buffer)))), 1 I can't find what's wrong. Can you take a look? |
Sorry about that, I hadn't pushed my latest changes. Should be working now. |
Thanks, it works great! Though I found an issue with macroexpanding (it's not unique to the introduced functions, but also happens in the interactive REPL). When I macroexpand some macros here's what I receive in the Messages buffer:
Trying to macroexpand the same expression from REPLy or CCW works fine. I thought maybe you've run into this kind of error? |
That sounds like a bug in the bencode decoder. If you can give me a reproducible test case I can track it down. |
It's hard to provide my exact reproducible case but here's another one for the time being. I don't know if they are quite connected, but...
Should just return a string with an Unicode character. It does for the REPLy but returns this in nrepl.el:
Typing this one yields the same:
The case I'm struggling with doesn't have any Unicode characters bit I currently can't minimize it down to the single problem. |
I think I have tracked down the multibyte decoding issue and pushed a fix. Let me know if that fixes the above issue. |
I mostly stole this from SLIME because I feel a critical lack of it in nREPL.
Having little experience with elisp there could be mistakes, but I'd like to give this function a spin.