branch: externals/bnf-mode
commit a3a77e363ba3120e89a5161f62fd70af912ae2f5
Author: Serghei Iakovlev <[email protected]>
Commit: Serghei Iakovlev <[email protected]>
In the BNF there are no grouping brackets except angle ones. Fixed
---
CHANGELOG.org | 5 +++--
bnf-mode.el | 12 ++++++++++--
2 files changed, 13 insertions(+), 4 deletions(-)
diff --git a/CHANGELOG.org b/CHANGELOG.org
index 26d2302..6daf61d 100644
--- a/CHANGELOG.org
+++ b/CHANGELOG.org
@@ -7,8 +7,9 @@ The format is based on [[http://keepachangelog.com][Keep a
Changelog]] and this
** [[https://github.com/sergeyklay/bnf-mode/compare/0.3.1...HEAD][Unreleased]]
*** Fixed
-- Original BNF has no strings so treat ~'~ and ~"~ as a symbols
+- In the BNF there are no strings so treat ~'~ and ~"~ as a symbols
- Minor code cleanup: removed no longer needed ~comment-*~ variables
+- In the BNF there are no grouping brackets except angle ones. Fixed
** [[https://github.com/sergeyklay/bnf-mode/compare/0.3.0...0.3.1][0.3.1]] -
2019-03-17
*** Fixed
@@ -20,7 +21,7 @@ The format is based on [[http://keepachangelog.com][Keep a
Changelog]] and this
** [[https://github.com/sergeyklay/bnf-mode/compare/0.1.0...0.2.0][0.2.0]] -
2019-03-16
*** Changed
-- Comments are no longer use syntax table. For more see `comment-use-syntax'
+- Comments are no longer use syntax table. For more see ~comment-use-syntax~
*** Fixed
- Changed comment syntax from ~#~ to ~;~ to follow
[[https://tools.ietf.org/html/rfc822#section-2.8][RFC822#2.8]]
diff --git a/bnf-mode.el b/bnf-mode.el
index 85085da..6260dd1 100644
--- a/bnf-mode.el
+++ b/bnf-mode.el
@@ -195,10 +195,18 @@ See `rx' documentation for more information about REGEXPS
param."
(modify-syntax-entry ?\= "_" table)
;; Treat | as a symbol
(modify-syntax-entry ?\| "_" table)
- ;; BNF has no strings so treat ' and "
- ;; as a symbols
+ ;; In the BNF there are no strings
+ ;; so treat ' and " as a symbols
(modify-syntax-entry ?\" "_" table)
(modify-syntax-entry ?\' "_" table)
+ ;; In the BNF there are no grouping
+ ;; brackets except angle ones
+ (modify-syntax-entry ?\( "_" table)
+ (modify-syntax-entry ?\) "_" table)
+ (modify-syntax-entry ?\{ "_" table)
+ (modify-syntax-entry ?\} "_" table)
+ (modify-syntax-entry ?\[ "_" table)
+ (modify-syntax-entry ?\] "_" table)
;; Group angle brackets
(modify-syntax-entry ?\< "(>" table)
(modify-syntax-entry ?\> ")<" table)