all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: Ivan Andrus <darthandrus@gmail.com>
To: Matt DeBoard <matt.deboard@gmail.com>
Cc: Stefan Monnier <monnier@iro.umontreal.ca>, emacs <emacs-devel@gnu.org>
Subject: Re: SMIE
Date: Tue, 19 Aug 2014 21:57:46 -0600	[thread overview]
Message-ID: <97B176AD-AB59-4589-BB7C-3751A424A77B@gmail.com> (raw)
In-Reply-To: <CAPLdYOjNNmqMuL4yynmqHT8+PW=Tuuf94Qo_sswBQzTAB0uPVQ@mail.gmail.com>

[-- Attachment #1: Type: text/plain, Size: 2597 bytes --]

I enjoyed using it for gap-mode [1] once I got the hang of it, though I would hesitate to suggest that people should look at my implementation. :-)  And I love, love, love the sexp-based movement it gives me for free.

-Ivan

[1] https://bitbucket.org/gvol/gap-mode/src/tip/gap-smie.el?at=default

On Aug 19, 2014, at 9:19 PM, Matt DeBoard <matt.deboard@gmail.com> wrote:

> To bring the thread back around full-circle to the topic of SMIE...
> 
> Stefan I wound up rewriting the `forward-token' and `backward-token' functions, discarding the previous code (which I inherited) in favor of much simpler, more concise code I found in `ruby-mode' and `swift-mode'. I took up this project (https://github.com/elixir-lang/emacs-elixir) just a couple months ago, so I thought the convolution of the code I replaced was a result of SMIE. I was skeptical about the degree to which I would be able to simplify the logic.
> 
> However, after cutting out over 150 lines of code by leaning heavily on SMIE, I just wanted to say thanks. SMIE -- once you get it -- is really valuable. There's a learning curve for sure, but it's a really pragmatic tool.
> 
> To any future readers who are looking for guidance on how to implement SMIE-driven indentation in your language mode, below are a few links of simple, concise, valid SMIE implementations that can serve as reference. In order of simplicity (IMO):
> 
> elixir-mode:
> 
> https://github.com/elixir-lang/emacs-elixir/blob/v1.4.8/elixir-smie.el
> 
> swift-mode:
> 
> https://github.com/chrisbarrett/swift-mode/blob/6abb78812bd5795950c1872787575c8eb72e8574/swift-mode.el
> 
> ruby-mode:
> 
> http://git.savannah.gnu.org/cgit/emacs.git/tree/lisp/progmodes/ruby-mode.el?h=emacs-24&id=2605b19cfa2ff47066c91dfd2650b40645d51b32
> 
> 
> On Tue, Aug 19, 2014 at 9:27 PM, Richard Stallman <rms@gnu.org> wrote:
> [[[ To any NSA and FBI agents reading my email: please consider    ]]]
> [[[ whether defending the US Constitution against all enemies,     ]]]
> [[[ foreign or domestic, requires you to follow Snowden's example. ]]]
> 
>     What does it take to accept digital signatures from other countries?
>     E.g. from France?  Can we help here?
> 
> I don't know, but a priori it seems unlikely that you or I could
> do anything that would change this legal issue.
> 
> --
> Dr Richard Stallman
> President, Free Software Foundation
> 51 Franklin St
> Boston MA 02110
> USA
> www.fsf.org  www.gnu.org
> Skype: No way! That's nonfree (freedom-denying) software.
>   Use Ekiga or an ordinary phone call.
> 
> 


[-- Attachment #2: Type: text/html, Size: 4282 bytes --]

  reply	other threads:[~2014-08-20  3:57 UTC|newest]

Thread overview: 24+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <CAPLdYOhnp353s3LTM9EORWbzmiH2JXVjFNX1sp07tQYe2Q4MPA@mail.gmail.com>
2014-07-10  3:02 ` SMIE Stefan Monnier
2014-07-10  3:53   ` SMIE Matt DeBoard
2014-07-10  3:59     ` SMIE Matt DeBoard
2014-07-10 17:00       ` SMIE chad
2014-08-16  2:34         ` SMIE Matt DeBoard
2014-08-17  7:27           ` SMIE Bozhidar Batsov
2014-08-17 11:55             ` SMIE Stefan Monnier
2014-08-18 12:00               ` SMIE Bozhidar Batsov
2014-08-18 13:33                 ` SMIE Tassilo Horn
2014-08-18 14:07                 ` SMIE Stefan Monnier
2014-08-19 13:08                 ` SMIE Richard Stallman
2014-08-19 14:12                   ` SMIE Bastien
2014-08-20  2:27                     ` SMIE Richard Stallman
2014-08-20  3:19                       ` SMIE Matt DeBoard
2014-08-20  3:57                         ` Ivan Andrus [this message]
2014-08-20 14:25                           ` SMIE Stefan Monnier
2014-08-27 22:44                             ` SMIE Matt DeBoard
2014-08-28  3:11                               ` SMIE Stefan Monnier
2014-08-28  7:40                                 ` SMIE David Kastrup
2014-08-28 22:03                                   ` SMIE Dmitry
2014-08-17  8:55         ` SMIE Andreas Röhler
2014-07-10 13:32     ` SMIE Stefan Monnier
2014-07-12 14:38     ` SMIE Stephen Leake
2014-07-10  4:22   ` SMIE Matt DeBoard

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=97B176AD-AB59-4589-BB7C-3751A424A77B@gmail.com \
    --to=darthandrus@gmail.com \
    --cc=emacs-devel@gnu.org \
    --cc=matt.deboard@gmail.com \
    --cc=monnier@iro.umontreal.ca \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this external index

	https://git.savannah.gnu.org/cgit/emacs.git
	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.