For prob2, it looks like when 'matlab-fill-code' is nil, it won't fill the code (via auto-fill mode), and it throws that error.
I pushed a change that will not fill code if matlab-fill-code is nil so it won't error anymore. Ideally, I suppose you might wan to set matlab-fill-code to t round-about line 2774 if you think it should fill if you specifically ask it to. ie: (if (= (point) (progn (matlab-auto-fill) (point))) (error "Fill algorithm failed!")) Would become (if (= (point) (let ((matlab-fill-code t)) (matlab-auto-fill) (point))) (error "Fill algorithm failed!")) In addition to removing the initial check to short-circuit this block. I remember this going in where the request was to auto-fill comments, but stop auto-filling code since it often didn't do what was desired. Eric From: Uwe Brauer <o...@mat.ucm.es> Sent: Thursday, July 27, 2023 11:46 AM To: Eric Ludlam <elud...@mathworks.com> Cc: Uwe Brauer <o...@mat.ucm.es>; Matlab-emacs-discuss <matlab-emacs-discuss@lists.sourceforge.net> Subject: Re: the filling patch and its problems >>> "EL" == Eric Ludlam <elud...@mathworks.com<mailto:elud...@mathworks.com>> >>> writes: > I saw an error indicated in your readme and tried it out. I pushed a > fix that will improve that particular case. Eric Thanks I did test it. It is better but still not perfect 1. It does not return error, but 2. it did not change much the filling (contrary to matlab-fill-comment-line which now works very nicely. 3. I also added a new test file, for which it still returns error. 4. I pushed Uwe -- Warning: Content may be disturbing to some audiences I strongly condemn Putin's war of aggression against the Ukraine. I support to deliver weapons to Ukraine's military. I support the NATO membership of the Ukraine. I support the EU membership of the Ukraine. https://addons.thunderbird.net/en-US/thunderbird/addon/gmail-conversation-view/<https://addons.thunderbird.net/en-US/thunderbird/addon/gmail-conversation-view> From: Uwe Brauer <o...@mat.ucm.es> Sent: Thursday, July 27, 2023 11:46 AM To: Eric Ludlam <elud...@mathworks.com> Cc: Uwe Brauer <o...@mat.ucm.es>; Matlab-emacs-discuss <matlab-emacs-discuss@lists.sourceforge.net> Subject: Re: the filling patch and its problems >>> "EL" == Eric Ludlam <elud...@mathworks.com<mailto:elud...@mathworks.com>> >>> writes: > I saw an error indicated in your readme and tried it out. I pushed a > fix that will improve that particular case. Eric Thanks I did test it. It is better but still not perfect 1. It does not return error, but 2. it did not change much the filling (contrary to matlab-fill-comment-line which now works very nicely. 3. I also added a new test file, for which it still returns error. 4. I pushed Uwe -- Warning: Content may be disturbing to some audiences I strongly condemn Putin's war of aggression against the Ukraine. I support to deliver weapons to Ukraine's military. I support the NATO membership of the Ukraine. I support the EU membership of the Ukraine. https://addons.thunderbird.net/en-US/thunderbird/addon/gmail-conversation-view/<https://addons.thunderbird.net/en-US/thunderbird/addon/gmail-conversation-view>
_______________________________________________ Matlab-emacs-discuss mailing list Matlab-emacs-discuss@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/matlab-emacs-discuss