[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[sc-users] Re: [sc-users-old] Emacs Parse Fail
On Wednesday 04 March 2009 04:03:43 andersvi@xxxxxxxxxx wrote:
> >>>>> "a" == andersvi <andersvi@xxxxxxxxxx> writes:
>
> a> I believe 'sclang-beginning-of-defun should be changed to check for
> the a> cursor being on the opening parenthesis or after the closing
> parenthesis a> (plus a semicolon) to make it more effective together with
> the move a> between blocks: C-M-n, C-M-p etc. Ill see if i get some time
> to look at a> it if nobody else gets there before me.
>
> A possible fix is to add a jump to end-of-line before looking for where
> the block starts, and comment out a (unnecessary?) check whether we
> moved in 'sclang-point-in-defun-p in sclang-language.el:
but would that work for a code block like this?
( 2:~v_foo=3+5; )
sincerely,
Marije
>
> (defun sclang-point-in-defun-p ()
> "Return non-nil if point is inside a defun.
> Return value is nil or (beg end) of defun."
> (save-excursion
> (let ((orig (point))
> beg end)
> (and (progn (end-of-line) (beginning-of-defun-raw 1) t)
> (setq beg (point))
> (condition-case nil (forward-list 1) (error nil))
> (setq end (point))
> ;; (> (point) orig)
> (list beg end)))))
>
> There are still issues here however. It doesn't understand expressions
> not inside parenthesis, eg
>
> {SinOsc.ar}.play(s)
>
> on a line by itself.
>
> -anders
> _______________________________________________
> sc-users mailing list
> sc-users@xxxxxxxxxxxxxxx
> http://lists.create.ucsb.edu/mailman/listinfo/sc-users
_______________________________________________
sc-users mailing list
info (subscription, etc.): http://www.beast.bham.ac.uk/research/sc_mailing_lists.shtml
archive: https://listarc.bham.ac.uk/marchives/sc-users/
search: https://listarc.bham.ac.uk/lists/sc-users/search/