all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: "Štěpán Němec" <stepnem@gmail.com>
To: Stefan Monnier <monnier@IRO.UMontreal.CA>
Cc: emacs-devel@gnu.org
Subject: Re: SMIE documentation
Date: Sun, 28 Nov 2010 22:56:50 +0100	[thread overview]
Message-ID: <87aakt863h.fsf@gmail.com> (raw)
In-Reply-To: <jwvwrnxur2f.fsf-monnier+emacs@gnu.org> (Stefan Monnier's message of "Sun, 28 Nov 2010 15:36:26 -0500")

Stefan Monnier <monnier@IRO.UMontreal.CA> writes:

> While Savannah is down, maybe someone will feel like checking my attempt
> at documenting SMIE.  See patch below.  I intend to install it on the
> emacs-23 branch, in case it matters.

[...]

Thank you. A few nits I noticed:

> +@c @defvar smie-grammar
> +@c This variable is an alist specifying the left and right precedence of
> +@c each token.  It is meant to be initialized with the use of one of the
> +@c functions below.
> +@c @end defvar

Why is this commented out?

[...]

> +The returned @emph{prec2} table holds constraints between pairs of token, and
                                                                      ^^^^^
                                                                      tokens
> +for any given pair only one constraint can be present, either: T1 < T2,
> +T1 = T2, or T1 > T2.

[...]

> +returns nil or an empty string, SMIE will try to handle the corresponding
> +text as an sexp according to syntax tables.
           ^^
           a

[...]

> +@code{'((assoc "else" "then"))}.  It can also happen for cases where the
> +conflict is real and cannot really be resolved, but it is unlikely to
> +pose problem in practice.
   ^^^^^^^^^^^^
   problems?

[...]

> +An other important concept is the notion of @emph{parent}: The
   ^^^^^^^^
   another
> +@emph{parent} of a token, is the head token of the most closely
> +enclosing syntactic construct.  For example, the parent of an

What about "nearest enclosing" instead of "most closely enclosing"?

[...]

> +SMIE provides various functions designed specifically for use in the
> +indentation rules function (several of those function will break if used
                                                ^^^^^^^^
                                                functions
> +in another context).  These functions all start with the prefix
> +@code{smie-rule-}.

[...]

> +@defun smie-rule-hanging-p
> +Return non-@code{nil} if the current token is @emph{hanging}.
> +A token is @emph{hanging} if it is at the last token on the line
                                      ^^^
                                      [delete]
> +and if it is preceded by other tokens: a lone token on a line is not

[...]

> +By @emph{separator}, we mean here a token whose sole purpose is to
> +separate various elements within some enclosing syntactic construct, and
> +which does not have any semantic significance in itself (i.e. it would
> +typically no exist as a node in an abstract syntax tree).
             ^^
             not
[...]


  Štěpán



  reply	other threads:[~2010-11-28 21:56 UTC|newest]

Thread overview: 18+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-11-28 20:36 SMIE documentation Stefan Monnier
2010-11-28 21:56 ` Štěpán Němec [this message]
2010-12-04 18:01   ` Stefan Monnier
2010-12-04 19:46     ` Drew Adams
2010-12-04 20:21       ` Andreas Schwab
2010-12-04 21:36         ` Drew Adams
2010-12-04 21:04       ` Bob Rogers
2010-12-04 19:56     ` Štěpán Němec
2010-12-06 18:26       ` Stefan Monnier
2010-11-29 17:54 ` Chong Yidong
2010-11-29 21:34   ` Stefan Monnier
2010-12-07 17:54   ` Stefan Monnier
2010-12-01  0:39 ` Johan Bockgård
2010-12-07 19:27   ` Stefan Monnier
2012-05-13 11:51     ` Johan Bockgård
2012-05-15 13:25       ` Stefan Monnier
2010-12-01 19:23 ` Johan Bockgård
2010-12-04  4:41   ` Stefan Monnier

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=87aakt863h.fsf@gmail.com \
    --to=stepnem@gmail.com \
    --cc=emacs-devel@gnu.org \
    --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.