[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [O] [PATCH] babel: ob-C with Visual C++ and compilation-mode
From: |
Achim Gratz |
Subject: |
Re: [O] [PATCH] babel: ob-C with Visual C++ and compilation-mode |
Date: |
Wed, 10 Sep 2014 11:27:36 +0200 |
User-agent: |
Gnus/5.13 (Gnus v5.13) Emacs/24.3.93 (gnu/linux) |
Eric Schulte writes:
> Ernesto Durante <address@hidden> writes:
>> + First patch, modify org-babel-eval to load compilation-mode in case
>>of errors
>>
>
> Applied.
These are missing a proper changelog so Bastien will be less happy.
>> org-babel-eval: compilation-mode to deal with errors in (C/C++/D)
Despite the title, the change is implemented for all Babel error
buffers. I'm not sure that's the right thing to do, but I don't see
off-hand how to easily make this a per-language setting.
>> + (compilation-mode)
Setting a mode from within lisp is pretty heavy-handed. Since we're
calling upon an existing buffer we should check if it's already in that
mode.
>> + ;;compilation-mode enforces read-only
>> + (read-only-mode 0))))
That doesn't work on Emacs < 24.3 and does a few other things that again
should not be done from Lisp. I'll change this to just
(setq buffer-read-only nil)
but compilation mode in an editable buffer is somewhat strange. Instead
we should probably bind (inhibit-read-only t) around those places where
Babel wants to modify the buffer, but I'm not sure how to easily find
them all.
(Done in ec8f245.)
Regards
Achim.
--
+<[Q+ Matrix-12 WAVE#46+305 Neuron microQkb Andromeda XTk Blofeld]>+
Factory and User Sound Singles for Waldorf Blofeld:
http://Synth.Stromeko.net/Downloads.html#WaldorfSounds
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- Re: [O] [PATCH] babel: ob-C with Visual C++ and compilation-mode,
Achim Gratz <=