X-Git-Url: http://git.hcoop.net/bpt/emacs.git/blobdiff_plain/28b6b84d4e91cf39c85f194c29b8e044ae6bac87..285f1858c328e250c78ec422a311a4b7fcc3d633:/lisp/progmodes/scheme.el diff --git a/lisp/progmodes/scheme.el b/lisp/progmodes/scheme.el index aae5526ea8..81af43dbef 100644 --- a/lisp/progmodes/scheme.el +++ b/lisp/progmodes/scheme.el @@ -1,6 +1,6 @@ ;;; scheme.el --- Scheme (and DSSSL) editing mode -;; Copyright (C) 1986-1988, 1997-1998, 2001-2013 Free Software +;; Copyright (C) 1986-1988, 1997-1998, 2001-2014 Free Software ;; Foundation, Inc. ;; Author: Bill Rozas @@ -210,9 +210,7 @@ start an inferior Scheme using the more general `cmuscheme' package. Commands: Delete converts tabs to spaces as it moves back. Blank lines separate paragraphs. Semicolons start comments. -\\{scheme-mode-map} -Entry to this mode calls the value of `scheme-mode-hook' -if that value is non-nil." +\\{scheme-mode-map}" (scheme-mode-variables)) (defgroup scheme nil @@ -310,8 +308,10 @@ See `run-hooks'." "(" (regexp-opt '("begin" "call-with-current-continuation" "call/cc" "call-with-input-file" "call-with-output-file" "case" "cond" - "do" "else" "for-each" "if" "lambda" + "do" "else" "for-each" "if" "lambda" "λ" "let" "let*" "let-syntax" "letrec" "letrec-syntax" + ;; R6RS library subforms. + "export" "import" ;; SRFI 11 usage comes up often enough. "let-values" "let*-values" ;; Hannes Haug wants: @@ -330,6 +330,10 @@ See `run-hooks'." ;; ;; Scheme `:' and `#:' keywords as builtins. '("\\<#?:\\sw+\\>" . font-lock-builtin-face) + ;; R6RS library declarations. + '("(\\(\\\\)\\s-*(?\\(\\sw+\\)?" + (1 font-lock-keyword-face) + (2 font-lock-type-face)) ))) "Gaudy expressions to highlight in Scheme modes.") @@ -410,6 +414,7 @@ that variable's value is a string." (put 'make 'scheme-indent-function 1) (put 'style 'scheme-indent-function 1) (put 'root 'scheme-indent-function 1) +(put 'λ 'scheme-indent-function 1) (defvar dsssl-font-lock-keywords (eval-when-compile @@ -535,6 +540,7 @@ indentation." (put 'letrec-syntax 'scheme-indent-function 1) (put 'syntax-rules 'scheme-indent-function 1) (put 'syntax-case 'scheme-indent-function 2) ; not r5rs +(put 'library 'scheme-indent-function 1) ; R6RS (put 'call-with-input-file 'scheme-indent-function 1) (put 'with-input-from-file 'scheme-indent-function 1)