~octaspire/dern

102d3669ba7f485a922388facc1f0273c20847e8 — octaspire 1 year, 6 months ago ecc2828 v0.460.0
Remove Pygments syntax file, update syntax files and documentation
M dev/include/octaspire/dern/octaspire_dern_config.h => dev/include/octaspire/dern/octaspire_dern_config.h +1 -1
@@ 18,7 18,7 @@ limitations under the License.
#define OCTASPIRE_DERN_CONFIG_H

#define OCTASPIRE_DERN_CONFIG_VERSION_MAJOR "0"
#define OCTASPIRE_DERN_CONFIG_VERSION_MINOR "459"
#define OCTASPIRE_DERN_CONFIG_VERSION_MINOR "460"
#define OCTASPIRE_DERN_CONFIG_VERSION_PATCH "0"

#define OCTASPIRE_DERN_CONFIG_VERSION_STR "Octaspire Dern version " \

M release/documentation/dern-manual.html => release/documentation/dern-manual.html +10 -10
@@ 974,9 974,9 @@ http://www.gnu.org/software/src-highlite -->
<span class="cbracket">(</span><span class="normal">max  </span><span class="number">{D+1}</span><span class="normal"> </span><span class="number">{D+2}</span><span class="normal"> </span><span class="number">{D+3}</span><span class="cbracket">)</span><span class="normal">    </span><span class="comment">; {D+3}</span>
<span class="cbracket">(</span><span class="normal">max  </span><span class="string">[abc]</span><span class="normal"> </span><span class="string">[abd]</span><span class="normal"> </span><span class="string">[abe]</span><span class="cbracket">)</span><span class="normal">    </span><span class="comment">; [abe]</span>

<span class="cbracket">(</span><span class="normal">distance </span><span class="number">{D+1}</span><span class="normal"> </span><span class="number">{D+1.1}</span><span class="cbracket">)</span><span class="normal">    </span><span class="comment">; {D+0.1}</span>
<span class="cbracket">(</span><span class="normal">distance </span><span class="string">[lawn]</span><span class="normal"> </span><span class="string">[flaw]</span><span class="cbracket">)</span><span class="normal">    </span><span class="comment">; {D+2}</span>
<span class="cbracket">(</span><span class="normal">distance 'kitten 'sitt</span><span class="keyword">in</span><span class="normal">g</span><span class="cbracket">)</span><span class="normal"> </span><span class="comment">; {D+3}</span>
<span class="cbracket">(</span><span class="keyword">distance</span><span class="normal"> </span><span class="number">{D+1}</span><span class="normal"> </span><span class="number">{D+1.1}</span><span class="cbracket">)</span><span class="normal">    </span><span class="comment">; {D+0.1}</span>
<span class="cbracket">(</span><span class="keyword">distance</span><span class="normal"> </span><span class="string">[lawn]</span><span class="normal"> </span><span class="string">[flaw]</span><span class="cbracket">)</span><span class="normal">    </span><span class="comment">; {D+2}</span>
<span class="cbracket">(</span><span class="keyword">distance</span><span class="normal"> 'kitten 'sitt</span><span class="keyword">in</span><span class="normal">g</span><span class="cbracket">)</span><span class="normal"> </span><span class="comment">; {D+3}</span>
</pre>

  <p>


@@ 998,17 998,17 @@ http://www.gnu.org/software/src-highlite -->
by Lorenzo Bettini
http://www.lorenzobettini.it
http://www.gnu.org/software/src-highlite -->
<pre><span class="cbracket">(</span><span class="normal">s</span><span class="keyword">in</span><span class="normal"> </span><span class="number">{D+1}</span><span class="cbracket">)</span><span class="normal"> </span><span class="comment">; {D+0.841471}</span>
<span class="cbracket">(</span><span class="normal">cos </span><span class="number">{D+1}</span><span class="cbracket">)</span><span class="normal"> </span><span class="comment">; {D+0.540302}</span>
<span class="cbracket">(</span><span class="normal">tan </span><span class="number">{D+1}</span><span class="cbracket">)</span><span class="normal"> </span><span class="comment">; {D+1.55741}</span>
<pre><span class="cbracket">(</span><span class="keyword">sin</span><span class="normal"> </span><span class="number">{D+1}</span><span class="cbracket">)</span><span class="normal"> </span><span class="comment">; {D+0.841471}</span>
<span class="cbracket">(</span><span class="keyword">cos</span><span class="normal"> </span><span class="number">{D+1}</span><span class="cbracket">)</span><span class="normal"> </span><span class="comment">; {D+0.540302}</span>
<span class="cbracket">(</span><span class="keyword">tan</span><span class="normal"> </span><span class="number">{D+1}</span><span class="cbracket">)</span><span class="normal"> </span><span class="comment">; {D+1.55741}</span>

<span class="cbracket">(</span><span class="keyword">asin</span><span class="normal"> </span><span class="number">{D+1}</span><span class="cbracket">)</span><span class="normal"> </span><span class="comment">; {D+1.5708}</span>
<span class="cbracket">(</span><span class="normal">acos </span><span class="number">{D+1}</span><span class="cbracket">)</span><span class="normal"> </span><span class="comment">; {D+0}</span>
<span class="cbracket">(</span><span class="normal">atan </span><span class="number">{D+1}</span><span class="cbracket">)</span><span class="normal"> </span><span class="comment">; {D+0.785398}</span>
<span class="cbracket">(</span><span class="keyword">acos</span><span class="normal"> </span><span class="number">{D+1}</span><span class="cbracket">)</span><span class="normal"> </span><span class="comment">; {D+0}</span>
<span class="cbracket">(</span><span class="keyword">atan</span><span class="normal"> </span><span class="number">{D+1}</span><span class="cbracket">)</span><span class="normal"> </span><span class="comment">; {D+0.785398}</span>

<span class="cbracket">(</span><span class="normal">pow </span><span class="number">{D+2}</span><span class="normal"> </span><span class="number">{D+3}</span><span class="cbracket">)</span><span class="normal"> </span><span class="comment">;{D+8}</span>
<span class="cbracket">(</span><span class="keyword">pow</span><span class="normal"> </span><span class="number">{D+2}</span><span class="normal"> </span><span class="number">{D+3}</span><span class="cbracket">)</span><span class="normal"> </span><span class="comment">;{D+8}</span>

<span class="cbracket">(</span><span class="normal">sqrt </span><span class="number">{D+9}</span><span class="cbracket">)</span><span class="normal"> </span><span class="comment">;{D+3}</span>
<span class="cbracket">(</span><span class="keyword">sqrt</span><span class="normal"> </span><span class="number">{D+9}</span><span class="cbracket">)</span><span class="normal"> </span><span class="comment">;{D+3}</span>
</pre>

  <h2><a id="10"></a>10. Comparing and changing values, predicates</h2>

M release/octaspire-dern-amalgamated.c => release/octaspire-dern-amalgamated.c +1 -1
@@ 26214,7 26214,7 @@ limitations under the License.
#define OCTASPIRE_DERN_CONFIG_H

#define OCTASPIRE_DERN_CONFIG_VERSION_MAJOR "0"
#define OCTASPIRE_DERN_CONFIG_VERSION_MINOR "459"
#define OCTASPIRE_DERN_CONFIG_VERSION_MINOR "460"
#define OCTASPIRE_DERN_CONFIG_VERSION_PATCH "0"

#define OCTASPIRE_DERN_CONFIG_VERSION_STR "Octaspire Dern version " \

M release/tool-support/emacs/syntax/octaspire-dern-mode.el => release/tool-support/emacs/syntax/octaspire-dern-mode.el +6 -6
@@ 23,13 23,13 @@
(defconst octaspire-dern-lock-keywords-1
  (list
   (cons (concat "\\_<" (regexp-opt '("!=" "*" "+" "++" "+=" "-" "--" "-=" "-==" "/" "<" "<=" "="
                       "==" "===" ">" ">=" "abort" "and" "define" "do" "doc" "env-current"
                       "env-global" "env-new" "eval" "exit" "find" "fn" "for" "hash-map" "if"
                       "input-file-open" "io-file-open" "len" "mod" "not" "ln@" "cp@" "or" "pop-front"
                       "==" "===" ">" ">=" "abort" "acos" "asin" "atan" "and" "cos" "define" "distance" "do"
                       "doc" "env-current" "env-global" "env-new" "eval" "exit" "find" "fn" "for" "hash-map"
                       "if" "input-file-open" "io-file-open" "len" "mod" "not" "ln@" "cp@" "or" "pop-front"
                       "port-close" "port-dist" "port-flush" "port-length" "port-read" "port-seek"
                       "port-write" "print" "println" "quote" "read-and-eval-path"
                       "read-and-eval-string" "return" "select" "starts-with?"
                       "string-format" "to-integer" "to-string" "uid" "vector" "while"
                       "port-write" "pow" "print" "println" "quote" "read-and-eval-path"
                       "read-and-eval-string" "return" "select" "sin" "sqrt" "starts-with?"
                       "string-format" "tan" "to-integer" "to-string" "uid" "vector" "while"
                       "output-file-open" "port-supports-output?" "port-supports-input?" "require"
                       "queue" "queue-with-max-length" "list" "howto" "howto-ok" "howto-no" "as"
                       "in" "pop-back"

D release/tool-support/pygments/dern.py => release/tool-support/pygments/dern.py +0 -62
@@ 1,62 0,0 @@
#This file has some influences from pygments/lexers/lisp.py
import re
import pygments
from pygments.lexer import RegexLexer
from pygments.token import *

__all__ = ['DernLexer']

class DernLexer(RegexLexer):
    """All your code goes here"""

    name= 'Dern'
    aliases = ['dern']
    filenames = '*.dern'
    flags = re.MULTILINE | re.DOTALL

    builtins = [
        '!=', '*', '+', '++', '+=', '-', '--', '-=', '-==', '/', '<', '<=', '=', '==', '===', '>', '>=', 'abort',
        'and', 'define', 'do', 'doc', 'env-current', 'env-global', 'env-new', 'eval', 'exit',
        'find', 'fn', 'for', 'hash-map', 'if', 'len', 'mod', 'not', 'ln@', 'cp@', 'or',
        'pop-front', 'print', 'println', 'quote', 'read-and-eval-path', 'read-and-eval-string',
        'return', 'select', 'starts-with?', 'string-format', 'to-integer', 'to-string', 'uid',
        'vector', 'while', 'io-file-open', 'port-read', 'port-write', 'port-seek', 'port-flush',
        'port-close', 'port-dist', 'port-length', 'input-file-open', 'output-file-open',
        'port-supports-output?', 'port-supports-input?', 'require', 'queue', 'queue-with-max-length',
        'list', 'howto', 'howto-ok', 'howto-no', 'as', 'in', 'pop-back'

    ]

    builtins.sort(reverse=True)

    valid_name = r'[\w!$%&*+-/\:;,.<=>?@^~]+'

    tokens = {
            'root' : [
                (r';.*?$', Comment.Singleline),
                (r'\s+',  Text), #Whitespace
                (r'(true|false|nil)',  Name.Constant),
                (r'-?\d+\.\d+', Number.Float),
                (r'-?\d+', Number.Integer),
                (r'(?<=\()(%s)' % "|".join(re.escape(entry) + '[\s\)]+' for entry in builtins), Name.Builtin),
                (r'(?<=\(fn \()' + valid_name, Name.Variable),
                (r'(?<=[^\']\()' + valid_name, Name.Function),
                (valid_name, Name.Variable),
                (r'(\(|\))', Punctuation), #Parentheses
                ('\[', String, 'string'),
                ('\#\!', Comment.Multiline, 'comment_multiline'),
                (r"'" + valid_name, String.Symbol),
                (r"('|\.)", Operator),
                (r'(\|.?\||\|bar\||\|newline\||\|tab\||\|string-start\||\|string-end\||\|[0-9a-fA-F]+\|)', String.Char),
                ],
                'string' : [
                    (r'\]', String, '#pop'),
                    (r"(\|bar\||\|newline\||\|tab\||\|string-start\||\|string-end\||\|[0-9a-fA-F]+\|)", String.Escape),
                    (r"(\{\})", String.Escape),
                    (r'[^\]\|\{\}]+', String),
                    ],
                'comment_multiline' : [
                    ('[^\!\#]+', Comment.Multiline),
                    ('\!\#', Comment.Multiline, '#pop'),
                    ]
            }

M release/tool-support/source-highlight/dern.lang => release/tool-support/source-highlight/dern.lang +6 -6
@@ 24,9 24,9 @@ keyword =
        "<=|<",
        "===|==|=",
        ">=|>",
        "abort|and|as",
        "cp@",
        "define|doc|do",
        "abort|acos|and|as|asin|atan",
        "cos|cp@",
        "define|distance|doc|do",
        "env-current|env-global|env-new|eval|exit",
        "find|fn|for",
        "howto-ok|howto-no|howto|hash-map",


@@ 35,11 35,11 @@ keyword =
        "mod",
        "not",
        "output-file-open|or",
        "port-supports-output?|port-supports-input?|pop-front|println|print|port-read|port-write|port-seek|port-flush|port-close|port-dist|port-length|pop-back",
        "port-supports-output?|port-supports-input?|pop-front|pow|println|print|port-read|port-write|port-seek|port-flush|port-close|port-dist|port-length|pop-back",
        "queue-with-max-length|queue|quote",
        "read-and-eval-path|read-and-eval-string|require|return",
        "select|starts-with?|string-format",
        "to-integer|to-string",
        "select|sin|sqrt|starts-with?|string-format",
        "tan|to-integer|to-string",
        "uid",
        "vector",
        "while"

M release/tool-support/vim/syntax/dern.vim => release/tool-support/vim/syntax/dern.vim +1 -1
@@ 26,7 26,7 @@ syn match dernEscape "\v\|[0-9a-fA-F]+\|" contained
syn match dernEscape "\v\{\}" contained
hi link dernString String

syn keyword dernKeyword != * + ++ += - -- -= -== / < <= = == === > >= abort and define do doc env-current env-global env-new eval exit find fn for hash-map if len mod not ln@ cp@ or pop-front print println quote read-and-eval-path read-and-eval-string return select starts-with? string-format to-integer to-string uid vector while io-file-open port-read port-write port-seek port-flush port-close port-dist port-length input-file-open output-file-open port-supports-output? port-supports-input? require queue queue-with-max-length list howto howto-ok howto-no as in pop-back
syn keyword dernKeyword != * + ++ += - -- -= -== / < <= = == === > >= abort and acos asin atan cos define distance do doc env-current env-global env-new eval exit find fn for hash-map if len mod not ln@ cp@ or pop-front pow print println quote read-and-eval-path read-and-eval-string return select sin sqrt starts-with? string-format tan to-integer to-string uid vector while io-file-open port-read port-write port-seek port-flush port-close port-dist port-length input-file-open output-file-open port-supports-output? port-supports-input? require queue queue-with-max-length list howto howto-ok howto-no as in pop-back
hi link dernKeyword Keyword

syn keyword dernBoolean true false nil