You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@lucy.apache.org by nw...@apache.org on 2015/08/06 18:19:38 UTC

[01/20] lucy-clownfish git commit: Improve HTML output of return and argument types

Repository: lucy-clownfish
Updated Branches:
  refs/heads/master aec7214de -> a7af0130b


Improve HTML output of return and argument types

- Support const types.
- Support space before indirection.
- Support arrays.


Project: http://git-wip-us.apache.org/repos/asf/lucy-clownfish/repo
Commit: http://git-wip-us.apache.org/repos/asf/lucy-clownfish/commit/a7af0130
Tree: http://git-wip-us.apache.org/repos/asf/lucy-clownfish/tree/a7af0130
Diff: http://git-wip-us.apache.org/repos/asf/lucy-clownfish/diff/a7af0130

Branch: refs/heads/master
Commit: a7af0130bb2444bf55b5c677346a282ccb28bab5
Parents: 04a1832
Author: Nick Wellnhofer <we...@aevum.de>
Authored: Mon Jul 27 02:30:58 2015 +0200
Committer: Nick Wellnhofer <we...@aevum.de>
Committed: Thu Aug 6 18:19:19 2015 +0200

----------------------------------------------------------------------
 compiler/src/CFCCHtml.c | 140 ++++++++++++++++++++++++-------------------
 1 file changed, 79 insertions(+), 61 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/lucy-clownfish/blob/a7af0130/compiler/src/CFCCHtml.c
----------------------------------------------------------------------
diff --git a/compiler/src/CFCCHtml.c b/compiler/src/CFCCHtml.c
index e36cb10..24576fe 100644
--- a/compiler/src/CFCCHtml.c
+++ b/compiler/src/CFCCHtml.c
@@ -168,7 +168,7 @@ static void
 S_transform_link(cmark_node *link, CFCClass *klass, int dir_level);
 
 static char*
-S_type_to_html(CFCClass *klass, CFCType *type);
+S_type_to_html(CFCType *type, const char *sep, CFCClass *doc_class);
 
 static char*
 S_cfc_uri_to_url(CFCUri *uri_obj, CFCClass *base, int dir_level);
@@ -789,11 +789,13 @@ S_html_create_fresh_methods(CFCClass *klass, CFCClass *ancestor) {
 static char*
 S_html_create_func(CFCClass *klass, CFCFunction *func, const char *prefix,
                    const char *short_sym) {
-    CFCType    *return_type      = CFCFunction_get_return_type(func);
-    char       *return_type_html = S_type_to_html(klass, return_type);
-    const char *incremented      = "";
+    CFCType    *ret_type      = CFCFunction_get_return_type(func);
+    char       *ret_html      = S_type_to_html(ret_type, "", klass);
+    const char *ret_array     = CFCType_get_array(ret_type);
+    const char *ret_array_str = ret_array ? ret_array : "";
+    const char *incremented   = "";
 
-    if (CFCType_incremented(return_type)) {
+    if (CFCType_incremented(ret_type)) {
         incremented = " <span class=\"comment\">// incremented</span>";
     }
 
@@ -801,10 +803,10 @@ S_html_create_func(CFCClass *klass, CFCFunction *func, const char *prefix,
 
     const char *pattern =
         "<dd>\n"
-        "<pre><code>%s%s\n"
+        "<pre><code>%s%s%s\n"
         "<span class=\"prefix\">%s</span><strong>%s</strong>%s</code></pre>\n";
-    char *result = CFCUtil_sprintf(pattern, return_type_html, incremented,
-                                   prefix, short_sym, param_list);
+    char *result = CFCUtil_sprintf(pattern, ret_html, ret_array_str,
+                                   incremented, prefix, short_sym, param_list);
 
     FREEMEM(param_list);
 
@@ -859,7 +861,7 @@ S_html_create_func(CFCClass *klass, CFCFunction *func, const char *prefix,
 
     result = CFCUtil_cat(result, "</dd>\n", NULL);
 
-    FREEMEM(return_type_html);
+    FREEMEM(ret_html);
     return result;
 }
 
@@ -875,39 +877,43 @@ S_html_create_param_list(CFCClass *klass, CFCFunction *func) {
         return CFCUtil_strdup("(void);\n");
     }
 
-    char *result = CFCUtil_strdup("(");
+    char *result = CFCUtil_strdup("(\n");
 
     for (int i = 0; variables[i]; ++i) {
-        CFCVariable *variable = variables[i];
-        CFCType     *type     = CFCVariable_get_type(variable);
-        const char  *name     = CFCVariable_get_name(variable);
+        CFCVariable *variable  = variables[i];
+        CFCType     *type      = CFCVariable_get_type(variable);
+        const char  *name      = CFCVariable_get_name(variable);
+        const char  *array     = CFCType_get_array(type);
+        const char  *array_str = array ? array : "";
 
         char *type_html;
         if (is_method && i == 0) {
             const char *prefix     = CFCClass_get_prefix(klass);
             const char *struct_sym = CFCClass_get_struct_sym(klass);
-            const char *pattern    = "<span class=\"prefix\">%s</span>%s*";
+            const char *pattern    = "<span class=\"prefix\">%s</span>%s *";
             type_html = CFCUtil_sprintf(pattern, prefix, struct_sym);
         }
         else {
-            type_html = S_type_to_html(klass, type);
+            type_html = S_type_to_html(type, " ", klass);
         }
 
-        result = CFCUtil_cat(result, "\n    ", type_html, " <strong>", name,
-                             "</strong>", NULL);
+        const char *sep = variables[i+1] ? "," : "";
+        const char *decremented = "";
 
-        if (variables[i+1]) {
-            result = CFCUtil_cat(result, ",", NULL);
-        }
         if (CFCType_decremented(type)) {
-            result = CFCUtil_cat(result,
-                    " <span class=\"comment\">// decremented</span>", NULL);
+            decremented = " <span class=\"comment\">// decremented</span>";
         }
 
+        const char *pattern = "    %s<strong>%s</strong>%s%s%s\n";
+        char *param_html = CFCUtil_sprintf(pattern, type_html, name, array_str,
+                                           sep, decremented);
+        result = CFCUtil_cat(result, param_html, NULL);
+
+        FREEMEM(param_html);
         FREEMEM(type_html);
     }
 
-    result = CFCUtil_cat(result, "\n);\n", NULL);
+    result = CFCUtil_cat(result, ");\n", NULL);
 
     return result;
 }
@@ -1055,54 +1061,66 @@ S_transform_link(cmark_node *link, CFCClass *doc_class, int dir_level) {
 }
 
 static char*
-S_type_to_html(CFCClass *doc_class, CFCType *type) {
-    const char *type_c = CFCType_to_c(type);
+S_type_to_html(CFCType *type, const char *sep, CFCClass *doc_class) {
+    const char *specifier = CFCType_get_specifier(type);
+    char *specifier_html = NULL;
 
     if (CFCType_is_object(type)) {
-        const char *underscore = strchr(type_c, '_');
-
-        if (underscore) {
-            const char *doc_struct_sym = CFCClass_full_struct_sym(doc_class);
-            const char *specifier      = CFCType_get_specifier(type);
-            CFCClass *klass = NULL;
-
-            // Don't link to doc class.
-            if (strcmp(specifier, doc_struct_sym) != 0) {
-                klass = CFCClass_fetch_by_struct_sym(specifier);
-                if (!klass) {
-                    CFCUtil_warn("Class '%s' not found", specifier);
-                }
-                else if (!CFCClass_public(klass)) {
-                    CFCUtil_warn("Non-public class '%s' used in public method",
-                                 specifier);
-                    klass = NULL;
-                }
-            }
-
-            size_t  offset = underscore + 1 - type_c;
-            char   *prefix = CFCUtil_strndup(specifier, offset);
-            char   *retval;
+        CFCClass   *klass = NULL;
 
+        // Don't link to doc class.
+        if (strcmp(specifier, CFCClass_full_struct_sym(doc_class)) != 0) {
+            klass = CFCClass_fetch_by_struct_sym(specifier);
             if (!klass) {
-                retval = CFCUtil_sprintf("<span class=\"prefix\">%s</span>%s",
-                                         prefix, type_c + offset);
+                CFCUtil_warn("Class '%s' not found", specifier);
             }
-            else {
-                char *url = S_class_to_url(klass, doc_class, 0);
-                const char *pattern =
-                    "<span class=\"prefix\">%s</span>"
-                    "<a href=\"%s\">%s</a>";
-                retval = CFCUtil_sprintf(pattern, prefix, url,
-                                         type_c + offset);
-                FREEMEM(url);
+            else if (!CFCClass_public(klass)) {
+                CFCUtil_warn("Non-public class '%s' used in public method",
+                             specifier);
+                klass = NULL;
             }
+        }
+
+        const char *underscore = strchr(specifier, '_');
+        if (!underscore) {
+            CFCUtil_die("Unprefixed object specifier '%s'", specifier);
+        }
+
+        size_t      offset     = underscore + 1 - specifier;
+        char       *prefix     = CFCUtil_strndup(specifier, offset);
+        const char *struct_sym = specifier + offset;
 
-            FREEMEM(prefix);
-            return retval;
+        if (!klass) {
+            const char *pattern = "<span class=\"prefix\">%s</span>%s";
+            specifier_html = CFCUtil_sprintf(pattern, prefix, struct_sym);
         }
+        else {
+            char *url = S_class_to_url(klass, doc_class, 0);
+            const char *pattern =
+                "<span class=\"prefix\">%s</span>"
+                "<a href=\"%s\">%s</a>";
+            specifier_html = CFCUtil_sprintf(pattern, prefix, url, struct_sym);
+            FREEMEM(url);
+        }
+
+        FREEMEM(prefix);
     }
+    else {
+        specifier_html = CFCUtil_strdup(specifier);
+    }
+
+    const char *const_str = CFCType_const(type) ? "const " : "";
+
+    int indirection = CFCType_get_indirection(type);
+    size_t asterisk_offset = indirection < 10 ? 10 - indirection : 0;
+    const char *asterisks = "**********";
+    const char *ind_str   = asterisks + asterisk_offset;
 
-    return CFCUtil_strdup(type_c);
+    char *html = CFCUtil_sprintf("%s%s%s%s", const_str, specifier_html,
+                                 sep, ind_str);
+
+    FREEMEM(specifier_html);
+    return html;
 }
 
 // Return a relative URL for a CFCUri object.


[04/20] lucy-clownfish git commit: Upgrade libcmark to 0.21.0

Posted by nw...@apache.org.
http://git-wip-us.apache.org/repos/asf/lucy-clownfish/blob/89c7b809/compiler/modules/CommonMark/src/scanners.h
----------------------------------------------------------------------
diff --git a/compiler/modules/CommonMark/src/scanners.h b/compiler/modules/CommonMark/src/scanners.h
index f360505..a6a71bf 100644
--- a/compiler/modules/CommonMark/src/scanners.h
+++ b/compiler/modules/CommonMark/src/scanners.h
@@ -5,25 +5,40 @@
 extern "C" {
 #endif
 
-int _scan_at(int (*scanner)(const unsigned char *), cmark_chunk *c, int offset);
-int _scan_autolink_uri(const unsigned char *p);
-int _scan_autolink_email(const unsigned char *p);
-int _scan_html_tag(const unsigned char *p);
-int _scan_html_block_tag(const unsigned char *p);
-int _scan_link_url(const unsigned char *p);
-int _scan_link_title(const unsigned char *p);
-int _scan_spacechars(const unsigned char *p);
-int _scan_atx_header_start(const unsigned char *p);
-int _scan_setext_header_line(const unsigned char *p);
-int _scan_hrule(const unsigned char *p);
-int _scan_open_code_fence(const unsigned char *p);
-int _scan_close_code_fence(const unsigned char *p);
-int _scan_entity(const unsigned char *p);
+bufsize_t _scan_at(bufsize_t (*scanner)(const unsigned char *), cmark_chunk *c, bufsize_t offset);
+bufsize_t _scan_scheme(const unsigned char *p);
+bufsize_t _scan_autolink_uri(const unsigned char *p);
+bufsize_t _scan_autolink_email(const unsigned char *p);
+bufsize_t _scan_html_tag(const unsigned char *p);
+bufsize_t _scan_html_block_start(const unsigned char *p);
+bufsize_t _scan_html_block_start_7(const unsigned char *p);
+bufsize_t _scan_html_block_end_1(const unsigned char *p);
+bufsize_t _scan_html_block_end_2(const unsigned char *p);
+bufsize_t _scan_html_block_end_3(const unsigned char *p);
+bufsize_t _scan_html_block_end_4(const unsigned char *p);
+bufsize_t _scan_html_block_end_5(const unsigned char *p);
+bufsize_t _scan_link_url(const unsigned char *p);
+bufsize_t _scan_link_title(const unsigned char *p);
+bufsize_t _scan_spacechars(const unsigned char *p);
+bufsize_t _scan_atx_header_start(const unsigned char *p);
+bufsize_t _scan_setext_header_line(const unsigned char *p);
+bufsize_t _scan_hrule(const unsigned char *p);
+bufsize_t _scan_open_code_fence(const unsigned char *p);
+bufsize_t _scan_close_code_fence(const unsigned char *p);
+bufsize_t _scan_entity(const unsigned char *p);
+bufsize_t _scan_dangerous_url(const unsigned char *p);
 
+#define scan_scheme(c, n) _scan_at(&_scan_scheme, c, n)
 #define scan_autolink_uri(c, n) _scan_at(&_scan_autolink_uri, c, n)
 #define scan_autolink_email(c, n) _scan_at(&_scan_autolink_email, c, n)
 #define scan_html_tag(c, n) _scan_at(&_scan_html_tag, c, n)
-#define scan_html_block_tag(c, n) _scan_at(&_scan_html_block_tag, c, n)
+#define scan_html_block_start(c, n) _scan_at(&_scan_html_block_start, c, n)
+#define scan_html_block_start_7(c, n) _scan_at(&_scan_html_block_start_7, c, n)
+#define scan_html_block_end_1(c, n) _scan_at(&_scan_html_block_end_1, c, n)
+#define scan_html_block_end_2(c, n) _scan_at(&_scan_html_block_end_2, c, n)
+#define scan_html_block_end_3(c, n) _scan_at(&_scan_html_block_end_3, c, n)
+#define scan_html_block_end_4(c, n) _scan_at(&_scan_html_block_end_4, c, n)
+#define scan_html_block_end_5(c, n) _scan_at(&_scan_html_block_end_5, c, n)
 #define scan_link_url(c, n) _scan_at(&_scan_link_url, c, n)
 #define scan_link_title(c, n) _scan_at(&_scan_link_title, c, n)
 #define scan_spacechars(c, n) _scan_at(&_scan_spacechars, c, n)
@@ -33,6 +48,7 @@ int _scan_entity(const unsigned char *p);
 #define scan_open_code_fence(c, n) _scan_at(&_scan_open_code_fence, c, n)
 #define scan_close_code_fence(c, n) _scan_at(&_scan_close_code_fence, c, n)
 #define scan_entity(c, n) _scan_at(&_scan_entity, c, n)
+#define scan_dangerous_url(c, n) _scan_at(&_scan_dangerous_url, c, n)
 
 #ifdef __cplusplus
 }

http://git-wip-us.apache.org/repos/asf/lucy-clownfish/blob/89c7b809/compiler/modules/CommonMark/src/scanners.re
----------------------------------------------------------------------
diff --git a/compiler/modules/CommonMark/src/scanners.re b/compiler/modules/CommonMark/src/scanners.re
index d83efde..fbe3283 100644
--- a/compiler/modules/CommonMark/src/scanners.re
+++ b/compiler/modules/CommonMark/src/scanners.re
@@ -2,9 +2,9 @@
 #include "chunk.h"
 #include "scanners.h"
 
-int _scan_at(int (*scanner)(const unsigned char *), cmark_chunk *c, int offset)
+bufsize_t _scan_at(bufsize_t (*scanner)(const unsigned char *), cmark_chunk *c, bufsize_t offset)
 {
-	int res;
+	bufsize_t res;
 	unsigned char *ptr = (unsigned char *)c->data;
 	unsigned char lim = ptr[c->len];
 
@@ -24,15 +24,15 @@ int _scan_at(int (*scanner)(const unsigned char *), cmark_chunk *c, int offset)
 
   wordchar = [^\x00-\x20];
 
-  spacechar = [ \t\n];
+  spacechar = [ \t\v\f\r\n];
 
   reg_char     = [^\\()\x00-\x20];
 
   escaped_char = [\\][!"#$%&'()*+,./:;<=>?@[\\\]^_`{|}~-];
 
-  tagname = [A-Za-z][A-Za-z0-9]*;
+  tagname = [A-Za-z][A-Za-z0-9-]*;
 
-  blocktagname = 'article'|'header'|'aside'|'hgroup'|'iframe'|'blockquote'|'hr'|'body'|'li'|'map'|'button'|'object'|'canvas'|'ol'|'caption'|'output'|'col'|'p'|'colgroup'|'pre'|'dd'|'progress'|'div'|'section'|'dl'|'table'|'td'|'dt'|'tbody'|'embed'|'textarea'|'fieldset'|'tfoot'|'figcaption'|'th'|'figure'|'thead'|'footer'|'footer'|'tr'|'form'|'ul'|'h1'|'h2'|'h3'|'h4'|'h5'|'h6'|'video'|'script'|'style';
+  blocktagname = 'address'|'article'|'aside'|'base'|'basefont'|'blockquote'|'body'|'caption'|'center'|'col'|'colgroup'|'dd'|'details'|'dialog'|'dir'|'div'|'dl'|'dt'|'fieldset'|'figcaption'|'figure'|'footer'|'form'|'frame'|'frameset'|'h1'|'head'|'header'|'hr'|'html'|'legend'|'li'|'link'|'main'|'menu'|'menuitem'|'meta'|'nav'|'noframes'|'ol'|'optgroup'|'option'|'p'|'param'|'pre'|'section'|'source'|'title'|'summary'|'table'|'tbody'|'td'|'tfoot'|'th'|'thead'|'title'|'tr'|'track'|'ul';
 
   attributename = [a-zA-Z_:][a-zA-Z0-9:._-]*;
 
@@ -60,7 +60,7 @@ int _scan_at(int (*scanner)(const unsigned char *), cmark_chunk *c, int offset)
   htmltag = opentag | closetag | htmlcomment | processinginstruction |
             declaration | cdata;
 
-  in_parens_nosp   = [(] (reg_char|escaped_char)* [)];
+  in_parens_nosp   = [(] (reg_char|escaped_char|[\\])* [)];
 
   in_double_quotes = ["] (escaped_char|[^"\x00])* ["];
   in_single_quotes = ['] (escaped_char|[^'\x00])* ['];
@@ -69,19 +69,30 @@ int _scan_at(int (*scanner)(const unsigned char *), cmark_chunk *c, int offset)
   scheme = 'coap'|'doi'|'javascript'|'aaa'|'aaas'|'about'|'acap'|'cap'|'cid'|'crid'|'data'|'dav'|'dict'|'dns'|'file'|'ftp'|'geo'|'go'|'gopher'|'h323'|'http'|'https'|'iax'|'icap'|'im'|'imap'|'info'|'ipp'|'iris'|'iris.beep'|'iris.xpc'|'iris.xpcs'|'iris.lwz'|'ldap'|'mailto'|'mid'|'msrp'|'msrps'|'mtqp'|'mupdate'|'news'|'nfs'|'ni'|'nih'|'nntp'|'opaquelocktoken'|'pop'|'pres'|'rtsp'|'service'|'session'|'shttp'|'sieve'|'sip'|'sips'|'sms'|'snmp'|'soap.beep'|'soap.beeps'|'tag'|'tel'|'telnet'|'tftp'|'thismessage'|'tn3270'|'tip'|'tv'|'urn'|'vemmi'|'ws'|'wss'|'xcon'|'xcon-userid'|'xmlrpc.beep'|'xmlrpc.beeps'|'xmpp'|'z39.50r'|'z39.50s'|'adiumxtra'|'afp'|'afs'|'aim'|'apt'|'attachment'|'aw'|'beshare'|'bitcoin'|'bolo'|'callto'|'chrome'|'chrome-extension'|'com-eventbrite-attendee'|'content'|'cvs'|'dlna-playsingle'|'dlna-playcontainer'|'dtn'|'dvb'|'ed2k'|'facetime'|'feed'|'finger'|'fish'|'gg'|'git'|'gizmoproject'|'gtalk'|'hcp'|'icon'|'ipn'|'irc'|'irc6'|'ircs'|'itms'|'jar'|'jms'|'keyparc'|'lastfm'|'lda
 ps'|'magnet'|'maps'|'market'|'message'|'mms'|'ms-help'|'msnim'|'mumble'|'mvn'|'notes'|'oid'|'palm'|'paparazzi'|'platform'|'proxy'|'psyc'|'query'|'res'|'resource'|'rmi'|'rsync'|'rtmp'|'secondlife'|'sftp'|'sgn'|'skype'|'smb'|'soldat'|'spotify'|'ssh'|'steam'|'svn'|'teamspeak'|'things'|'udp'|'unreal'|'ut2004'|'ventrilo'|'view-source'|'webcal'|'wtai'|'wyciwyg'|'xfire'|'xri'|'ymsgr';
 */
 
+// Try to match a scheme including colon.
+bufsize_t _scan_scheme(const unsigned char *p)
+{
+  const unsigned char *marker = NULL;
+  const unsigned char *start = p;
+/*!re2c
+  scheme [:] { return (bufsize_t)(p - start); }
+  .? { return 0; }
+*/
+}
+
 // Try to match URI autolink after first <, returning number of chars matched.
-int _scan_autolink_uri(const unsigned char *p)
+bufsize_t _scan_autolink_uri(const unsigned char *p)
 {
   const unsigned char *marker = NULL;
   const unsigned char *start = p;
 /*!re2c
-  scheme [:]([^\x00-\x20<>\\]|escaped_char)*[>]  { return (p - start); }
+  scheme [:][^\x00-\x20<>]*[>]  { return (bufsize_t)(p - start); }
   .? { return 0; }
 */
 }
 
 // Try to match email autolink after first <, returning num of chars matched.
-int _scan_autolink_email(const unsigned char *p)
+bufsize_t _scan_autolink_email(const unsigned char *p)
 {
   const unsigned char *marker = NULL;
   const unsigned char *start = p;
@@ -90,32 +101,101 @@ int _scan_autolink_email(const unsigned char *p)
     [@]
     [a-zA-Z0-9]([a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?
     ([.][a-zA-Z0-9]([a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?)*
-    [>] { return (p - start); }
+    [>] { return (bufsize_t)(p - start); }
   .? { return 0; }
 */
 }
 
 // Try to match an HTML tag after first <, returning num of chars matched.
-int _scan_html_tag(const unsigned char *p)
+bufsize_t _scan_html_tag(const unsigned char *p)
+{
+  const unsigned char *marker = NULL;
+  const unsigned char *start = p;
+/*!re2c
+  htmltag { return (bufsize_t)(p - start); }
+  .? { return 0; }
+*/
+}
+
+// Try to match an HTML block tag start line, returning
+// an integer code for the type of block (1-6, matching the spec).
+// #7 is handled by a separate function, below.
+bufsize_t _scan_html_block_start(const unsigned char *p)
+{
+  const unsigned char *marker = NULL;
+/*!re2c
+  [<] ('script'|'pre'|'style') (spacechar | [>]) { return 1; }
+  '<!--' { return 2; }
+  '<?' { return 3; }
+  '<!' [A-Z] { return 4; }
+  '<![CDATA[' { return 5; }
+  [<] [/]? blocktagname (spacechar | [/]? [>])  { return 6; }
+  .? { return 0; }
+*/
+}
+
+// Try to match an HTML block tag start line of type 7, returning
+// 7 if successful, 0 if not.
+bufsize_t _scan_html_block_start_7(const unsigned char *p)
+{
+  const unsigned char *marker = NULL;
+/*!re2c
+  [<] (opentag | closetag) [\t\n\f ]* [\r\n] { return 7; }
+  .? { return 0; }
+*/
+}
+
+// Try to match an HTML block end line of type 1
+bufsize_t _scan_html_block_end_1(const unsigned char *p)
+{
+  const unsigned char *marker = NULL;
+  const unsigned char *start = p;
+/*!re2c
+  .* [<] [/] ('script'|'pre'|'style') [>] { return (bufsize_t)(p - start); }
+  .? { return 0; }
+*/
+}
+
+// Try to match an HTML block end line of type 2
+bufsize_t _scan_html_block_end_2(const unsigned char *p)
+{
+  const unsigned char *marker = NULL;
+  const unsigned char *start = p;
+/*!re2c
+  .* '-->' { return (bufsize_t)(p - start); }
+  .? { return 0; }
+*/
+}
+
+// Try to match an HTML block end line of type 3
+bufsize_t _scan_html_block_end_3(const unsigned char *p)
+{
+  const unsigned char *marker = NULL;
+  const unsigned char *start = p;
+/*!re2c
+  .* '?>' { return (bufsize_t)(p - start); }
+  .? { return 0; }
+*/
+}
+
+// Try to match an HTML block end line of type 4
+bufsize_t _scan_html_block_end_4(const unsigned char *p)
 {
   const unsigned char *marker = NULL;
   const unsigned char *start = p;
 /*!re2c
-  htmltag { return (p - start); }
+  .* '>' { return (bufsize_t)(p - start); }
   .? { return 0; }
 */
 }
 
-// Try to match an HTML block tag including first <,
-// returning num of chars matched.
-int _scan_html_block_tag(const unsigned char *p)
+// Try to match an HTML block end line of type 5
+bufsize_t _scan_html_block_end_5(const unsigned char *p)
 {
   const unsigned char *marker = NULL;
   const unsigned char *start = p;
 /*!re2c
-  [<] [/] blocktagname (spacechar | [>])  { return (p - start); }
-  [<] blocktagname (spacechar | [/>]) { return (p - start); }
-  [<] [!?] { return (p - start); }
+  .* ']]>' { return (bufsize_t)(p - start); }
   .? { return 0; }
 */
 }
@@ -124,13 +204,13 @@ int _scan_html_block_tag(const unsigned char *p)
 // This may optionally be contained in <..>; otherwise
 // whitespace and unbalanced right parentheses aren't allowed.
 // Newlines aren't ever allowed.
-int _scan_link_url(const unsigned char *p)
+bufsize_t _scan_link_url(const unsigned char *p)
 {
   const unsigned char *marker = NULL;
   const unsigned char *start = p;
 /*!re2c
-  [ \n]* [<] ([^<>\n\\\x00] | escaped_char | [\\])* [>] { return (p - start); }
-  [ \n]* (reg_char+ | escaped_char | in_parens_nosp)* { return (p - start); }
+  [ \r\n]* [<] ([^<>\r\n\\\x00] | escaped_char | [\\])* [>] { return (bufsize_t)(p - start); }
+  [ \r\n]* (reg_char+ | escaped_char | in_parens_nosp | [\\][^()])* { return (bufsize_t)(p - start); }
   .? { return 0; }
 */
 }
@@ -138,47 +218,48 @@ int _scan_link_url(const unsigned char *p)
 // Try to match a link title (in single quotes, in double quotes, or
 // in parentheses), returning number of chars matched.  Allow one
 // level of internal nesting (quotes within quotes).
-int _scan_link_title(const unsigned char *p)
+bufsize_t _scan_link_title(const unsigned char *p)
 {
   const unsigned char *marker = NULL;
   const unsigned char *start = p;
 /*!re2c
-  ["] (escaped_char|[^"\x00])* ["]   { return (p - start); }
-  ['] (escaped_char|[^'\x00])* ['] { return (p - start); }
-  [(] (escaped_char|[^)\x00])* [)]  { return (p - start); }
+  ["] (escaped_char|[^"\x00])* ["]   { return (bufsize_t)(p - start); }
+  ['] (escaped_char|[^'\x00])* ['] { return (bufsize_t)(p - start); }
+  [(] (escaped_char|[^)\x00])* [)]  { return (bufsize_t)(p - start); }
   .? { return 0; }
 */
 }
 
 // Match space characters, including newlines.
-int _scan_spacechars(const unsigned char *p)
+bufsize_t _scan_spacechars(const unsigned char *p)
 {
+  const unsigned char *marker = NULL;
   const unsigned char *start = p; \
 /*!re2c
-  [ \t\n]* { return (p - start); }
+  [ \t\v\f\r\n]* { return (bufsize_t)(p - start); }
   . { return 0; }
 */
 }
 
 // Match ATX header start.
-int _scan_atx_header_start(const unsigned char *p)
+bufsize_t _scan_atx_header_start(const unsigned char *p)
 {
   const unsigned char *marker = NULL;
   const unsigned char *start = p;
 /*!re2c
-  [#]{1,6} ([ ]+|[\n])  { return (p - start); }
+  [#]{1,6} ([ ]+|[\r\n])  { return (bufsize_t)(p - start); }
   .? { return 0; }
 */
 }
 
-// Match sexext header line.  Return 1 for level-1 header,
+// Match setext header line.  Return 1 for level-1 header,
 // 2 for level-2, 0 for no match.
-int _scan_setext_header_line(const unsigned char *p)
+bufsize_t _scan_setext_header_line(const unsigned char *p)
 {
   const unsigned char *marker = NULL;
 /*!re2c
-  [=]+ [ ]* [\n] { return 1; }
-  [-]+ [ ]* [\n] { return 2; }
+  [=]+ [ ]* [\r\n] { return 1; }
+  [-]+ [ ]* [\r\n] { return 2; }
   .? { return 0; }
 */
 }
@@ -186,51 +267,65 @@ int _scan_setext_header_line(const unsigned char *p)
 // Scan a horizontal rule line: "...three or more hyphens, asterisks,
 // or underscores on a line by themselves. If you wish, you may use
 // spaces between the hyphens or asterisks."
-int _scan_hrule(const unsigned char *p)
+bufsize_t _scan_hrule(const unsigned char *p)
 {
   const unsigned char *marker = NULL;
   const unsigned char *start = p;
 /*!re2c
-  ([*][ ]*){3,} [ \t]* [\n] { return (p - start); }
-  ([_][ ]*){3,} [ \t]* [\n] { return (p - start); }
-  ([-][ ]*){3,} [ \t]* [\n] { return (p - start); }
+  ([*][ ]*){3,} [ \t]* [\r\n] { return (bufsize_t)(p - start); }
+  ([_][ ]*){3,} [ \t]* [\r\n] { return (bufsize_t)(p - start); }
+  ([-][ ]*){3,} [ \t]* [\r\n] { return (bufsize_t)(p - start); }
   .? { return 0; }
 */
 }
 
 // Scan an opening code fence.
-int _scan_open_code_fence(const unsigned char *p)
+bufsize_t _scan_open_code_fence(const unsigned char *p)
 {
   const unsigned char *marker = NULL;
   const unsigned char *start = p;
 /*!re2c
-  [`]{3,} / [^`\n\x00]*[\n] { return (p - start); }
-  [~]{3,} / [^~\n\x00]*[\n] { return (p - start); }
+  [`]{3,} / [^`\r\n\x00]*[\r\n] { return (bufsize_t)(p - start); }
+  [~]{3,} / [^~\r\n\x00]*[\r\n] { return (bufsize_t)(p - start); }
   .?                        { return 0; }
 */
 }
 
 // Scan a closing code fence with length at least len.
-int _scan_close_code_fence(const unsigned char *p)
+bufsize_t _scan_close_code_fence(const unsigned char *p)
 {
   const unsigned char *marker = NULL;
   const unsigned char *start = p;
 /*!re2c
-  [`]{3,} / [ \t]*[\n] { return (p - start); }
-  [~]{3,} / [ \t]*[\n] { return (p - start); }
+  [`]{3,} / [ \t]*[\r\n] { return (bufsize_t)(p - start); }
+  [~]{3,} / [ \t]*[\r\n] { return (bufsize_t)(p - start); }
   .? { return 0; }
 */
 }
 
 // Scans an entity.
 // Returns number of chars matched.
-int _scan_entity(const unsigned char *p)
+bufsize_t _scan_entity(const unsigned char *p)
 {
   const unsigned char *marker = NULL;
   const unsigned char *start = p;
 /*!re2c
   [&] ([#] ([Xx][A-Fa-f0-9]{1,8}|[0-9]{1,8}) |[A-Za-z][A-Za-z0-9]{1,31} ) [;]
-     { return (p - start); }
+     { return (bufsize_t)(p - start); }
+  .? { return 0; }
+*/
+}
+
+// Returns positive value if a URL begins in a way that is potentially
+// dangerous, with javascript:, vbscript:, file:, or data:, otherwise 0.
+bufsize_t _scan_dangerous_url(const unsigned char *p)
+{
+  const unsigned char *marker = NULL;
+  const unsigned char *start = p;
+/*!re2c
+  'data:image/' ('png'|'gif'|'jpeg'|'webp') { return 0; }
+  'javascript:' | 'vbscript:' | 'file:' | 'data:' { return (bufsize_t)(p - start); }
   .? { return 0; }
 */
 }
+

http://git-wip-us.apache.org/repos/asf/lucy-clownfish/blob/89c7b809/compiler/modules/CommonMark/src/utf8.c
----------------------------------------------------------------------
diff --git a/compiler/modules/CommonMark/src/utf8.c b/compiler/modules/CommonMark/src/utf8.c
index d77c5d1..ffe6652 100644
--- a/compiler/modules/CommonMark/src/utf8.c
+++ b/compiler/modules/CommonMark/src/utf8.c
@@ -30,7 +30,7 @@ static void encode_unknown(cmark_strbuf *buf)
 	cmark_strbuf_put(buf, repl, 3);
 }
 
-static int utf8proc_charlen(const uint8_t *str, int str_len)
+static int utf8proc_charlen(const uint8_t *str, bufsize_t str_len)
 {
 	int length, i;
 
@@ -42,7 +42,7 @@ static int utf8proc_charlen(const uint8_t *str, int str_len)
 	if (!length)
 		return -1;
 
-	if (str_len >= 0 && length > str_len)
+	if (str_len >= 0 && (bufsize_t)length > str_len)
 		return -str_len;
 
 	for (i = 1; i < length; i++) {
@@ -54,23 +54,20 @@ static int utf8proc_charlen(const uint8_t *str, int str_len)
 }
 
 // Validate a single UTF-8 character according to RFC 3629.
-static int utf8proc_valid(const uint8_t *str, int str_len)
+static int utf8proc_valid(const uint8_t *str, bufsize_t str_len)
 {
-	int length = utf8proc_charlen(str, str_len);
+	int length = utf8proc_utf8class[str[0]];
 
-	if (length <= 0)
-		return length;
+	if (!length)
+		return -1;
 
-	switch (length) {
-	case 1:
-		if (str[0] == 0x00) {
-			// ASCII NUL is technically valid but rejected
-			// for security reasons.
-			return -length;
-		}
-		break;
+	if ((bufsize_t)length > str_len)
+		return -str_len;
 
+	switch (length) {
 	case 2:
+		if ((str[1] & 0xC0) != 0x80)
+			return -1;
 		if (str[0] < 0xC2) {
 			// Overlong
 			return -length;
@@ -78,6 +75,10 @@ static int utf8proc_valid(const uint8_t *str, int str_len)
 		break;
 
 	case 3:
+		if ((str[1] & 0xC0) != 0x80)
+			return -1;
+		if ((str[2] & 0xC0) != 0x80)
+			return -2;
 		if (str[0] == 0xE0) {
 			if (str[1] < 0xA0) {
 				// Overlong
@@ -92,6 +93,12 @@ static int utf8proc_valid(const uint8_t *str, int str_len)
 		break;
 
 	case 4:
+		if ((str[1] & 0xC0) != 0x80)
+			return -1;
+		if ((str[2] & 0xC0) != 0x80)
+			return -2;
+		if ((str[3] & 0xC0) != 0x80)
+			return -3;
 		if (str[0] == 0xF0) {
 			if (str[1] < 0x90) {
 				// Overlong
@@ -109,49 +116,47 @@ static int utf8proc_valid(const uint8_t *str, int str_len)
 	return length;
 }
 
-void utf8proc_detab(cmark_strbuf *ob, const uint8_t *line, size_t size)
+void utf8proc_check(cmark_strbuf *ob, const uint8_t *line, bufsize_t size)
 {
-	static const uint8_t whitespace[] = "    ";
-
-	size_t i = 0, tab = 0;
+	bufsize_t i = 0;
 
 	while (i < size) {
-		size_t org = i;
-
-		while (i < size && line[i] != '\t' && line[i] != '\0'
-		       && line[i] < 0x80) {
-			i++;
-			tab++;
+		bufsize_t org = i;
+		int charlen = 0;
+
+		while (i < size) {
+			if (line[i] < 0x80 && line[i] != 0) {
+				i++;
+			} else if (line[i] >= 0x80) {
+				charlen = utf8proc_valid(line + i, size - i);
+				if (charlen < 0) {
+					charlen = -charlen;
+					break;
+				}
+				i += charlen;
+			} else if (line[i] == 0) {
+				// ASCII NUL is technically valid but rejected
+				// for security reasons.
+				charlen = 1;
+				break;
+			}
 		}
 
-		if (i > org)
+		if (i > org) {
 			cmark_strbuf_put(ob, line + org, i - org);
+		}
 
-		if (i >= size)
+		if (i >= size) {
 			break;
-
-		if (line[i] == '\t') {
-			int numspaces = 4 - (tab % 4);
-			cmark_strbuf_put(ob, whitespace, numspaces);
-			i += 1;
-			tab += numspaces;
 		} else {
-			int charlen = utf8proc_valid(line + i, size - i);
-
-			if (charlen >= 0) {
-				cmark_strbuf_put(ob, line + i, charlen);
-			} else {
-				encode_unknown(ob);
-				charlen = -charlen;
-			}
-
+			// Invalid UTF-8
+			encode_unknown(ob);
 			i += charlen;
-			tab += 1;
 		}
 	}
 }
 
-int utf8proc_iterate(const uint8_t *str, int str_len, int32_t *dst)
+int utf8proc_iterate(const uint8_t *str, bufsize_t str_len, int32_t *dst)
 {
 	int length;
 	int32_t uc = -1;
@@ -172,8 +177,7 @@ int utf8proc_iterate(const uint8_t *str, int str_len, int32_t *dst)
 	case 3:
 		uc = ((str[0] & 0x0F) << 12) + ((str[1] & 0x3F) <<  6)
 		     + (str[2] & 0x3F);
-		if (uc < 0x800 || (uc >= 0xD800 && uc < 0xE000) ||
-		    (uc >= 0xFDD0 && uc < 0xFDF0)) uc = -1;
+		if (uc < 0x800 || (uc >= 0xD800 && uc < 0xE000)) uc = -1;
 		break;
 	case 4:
 		uc = ((str[0] & 0x07) << 18) + ((str[1] & 0x3F) << 12)
@@ -182,7 +186,7 @@ int utf8proc_iterate(const uint8_t *str, int str_len, int32_t *dst)
 		break;
 	}
 
-	if (uc < 0 || ((uc & 0xFFFF) >= 0xFFFE))
+	if (uc < 0)
 		return -1;
 
 	*dst = uc;
@@ -192,7 +196,7 @@ int utf8proc_iterate(const uint8_t *str, int str_len, int32_t *dst)
 void utf8proc_encode_char(int32_t uc, cmark_strbuf *buf)
 {
 	uint8_t dst[4];
-	int len = 0;
+	bufsize_t len = 0;
 
 	assert(uc >= 0);
 
@@ -228,7 +232,7 @@ void utf8proc_encode_char(int32_t uc, cmark_strbuf *buf)
 	cmark_strbuf_put(buf, dst, len);
 }
 
-void utf8proc_case_fold(cmark_strbuf *dest, const uint8_t *str, int len)
+void utf8proc_case_fold(cmark_strbuf *dest, const uint8_t *str, bufsize_t len)
 {
 	int32_t c;
 
@@ -236,7 +240,7 @@ void utf8proc_case_fold(cmark_strbuf *dest, const uint8_t *str, int len)
 	utf8proc_encode_char(x, dest)
 
 	while (len > 0) {
-		int char_len = utf8proc_iterate(str, len, &c);
+		bufsize_t char_len = utf8proc_iterate(str, len, &c);
 
 		if (char_len >= 0) {
 #include "case_fold_switch.inc"

http://git-wip-us.apache.org/repos/asf/lucy-clownfish/blob/89c7b809/compiler/modules/CommonMark/src/utf8.h
----------------------------------------------------------------------
diff --git a/compiler/modules/CommonMark/src/utf8.h b/compiler/modules/CommonMark/src/utf8.h
index 7df1573..9f1a4ec 100644
--- a/compiler/modules/CommonMark/src/utf8.h
+++ b/compiler/modules/CommonMark/src/utf8.h
@@ -8,10 +8,10 @@
 extern "C" {
 #endif
 
-void utf8proc_case_fold(cmark_strbuf *dest, const uint8_t *str, int len);
+void utf8proc_case_fold(cmark_strbuf *dest, const uint8_t *str, bufsize_t len);
 void utf8proc_encode_char(int32_t uc, cmark_strbuf *buf);
-int utf8proc_iterate(const uint8_t *str, int str_len, int32_t *dst);
-void utf8proc_detab(cmark_strbuf *dest, const uint8_t *line, size_t size);
+int utf8proc_iterate(const uint8_t *str, bufsize_t str_len, int32_t *dst);
+void utf8proc_check(cmark_strbuf *dest, const uint8_t *line, bufsize_t size);
 int utf8proc_is_space(int32_t uc);
 int utf8proc_is_punctuation(int32_t uc);
 

http://git-wip-us.apache.org/repos/asf/lucy-clownfish/blob/89c7b809/compiler/modules/CommonMark/src/xml.c
----------------------------------------------------------------------
diff --git a/compiler/modules/CommonMark/src/xml.c b/compiler/modules/CommonMark/src/xml.c
index f630aba..7eec5a6 100644
--- a/compiler/modules/CommonMark/src/xml.c
+++ b/compiler/modules/CommonMark/src/xml.c
@@ -11,14 +11,9 @@
 
 // Functions to convert cmark_nodes to XML strings.
 
-static void escape_xml(cmark_strbuf *dest, const unsigned char *source, int length)
+static void escape_xml(cmark_strbuf *dest, const unsigned char *source, bufsize_t length)
 {
-	if (source != NULL) {
-		if (length < 0)
-			length = strlen((char *)source);
-
-		houdini_escape_html0(dest, source, (size_t)length, 0);
-	}
+	houdini_escape_html0(dest, source, length, 0);
 }
 
 struct render_state {
@@ -36,7 +31,7 @@ static inline void indent(struct render_state *state)
 
 static int
 S_render_node(cmark_node *node, cmark_event_type ev_type,
-              struct render_state *state, long options)
+              struct render_state *state, int options)
 {
 	cmark_strbuf *xml = state->xml;
 	bool literal = false;
@@ -118,10 +113,12 @@ S_render_node(cmark_node *node, cmark_event_type ev_type,
 		case CMARK_NODE_LINK:
 		case CMARK_NODE_IMAGE:
 			cmark_strbuf_puts(xml, " destination=\"");
-			escape_xml(xml, node->as.link.url, -1);
+			escape_xml(xml, node->as.link.url.data,
+			           node->as.link.url.len);
 			cmark_strbuf_putc(xml, '"');
 			cmark_strbuf_puts(xml, " title=\"");
-			escape_xml(xml, node->as.link.title, -1);
+			escape_xml(xml, node->as.link.title.data,
+			           node->as.link.title.len);
 			cmark_strbuf_putc(xml, '"');
 			break;
 		default:
@@ -145,7 +142,7 @@ S_render_node(cmark_node *node, cmark_event_type ev_type,
 	return 1;
 }
 
-char *cmark_render_xml(cmark_node *root, long options)
+char *cmark_render_xml(cmark_node *root, int options)
 {
 	char *result;
 	cmark_strbuf xml = GH_BUF_INIT;
@@ -153,10 +150,6 @@ char *cmark_render_xml(cmark_node *root, long options)
 	cmark_node *cur;
 	struct render_state state = { &xml, 0 };
 
-	if (options & CMARK_OPT_NORMALIZE) {
-		cmark_consolidate_text_nodes(root);
-	}
-
 	cmark_iter *iter = cmark_iter_new(root);
 
 	cmark_strbuf_puts(state.xml,
@@ -170,6 +163,5 @@ char *cmark_render_xml(cmark_node *root, long options)
 	result = (char *)cmark_strbuf_detach(&xml);
 
 	cmark_iter_free(iter);
-	cmark_strbuf_free(&xml);
 	return result;
 }

http://git-wip-us.apache.org/repos/asf/lucy-clownfish/blob/89c7b809/compiler/src/CFCCHtml.c
----------------------------------------------------------------------
diff --git a/compiler/src/CFCCHtml.c b/compiler/src/CFCCHtml.c
index 0409a7b..34b4336 100644
--- a/compiler/src/CFCCHtml.c
+++ b/compiler/src/CFCCHtml.c
@@ -756,7 +756,10 @@ S_html_create_inheritance(CFCClass *klass) {
 
 static char*
 S_md_to_html(CFCClass *klass, const char *md) {
-    cmark_node *doc = cmark_parse_document(md, strlen(md));
+    int options = CMARK_OPT_SMART
+                  | CMARK_OPT_VALIDATE_UTF8
+                  | CMARK_OPT_SAFE;
+    cmark_node *doc = cmark_parse_document(md, strlen(md), options);
     S_convert_uris(klass, doc);
     char *html = cmark_render_html(doc, CMARK_OPT_DEFAULT);
     cmark_node_free(doc);

http://git-wip-us.apache.org/repos/asf/lucy-clownfish/blob/89c7b809/compiler/src/CFCCMan.c
----------------------------------------------------------------------
diff --git a/compiler/src/CFCCMan.c b/compiler/src/CFCCMan.c
index 354d91f..79248c8 100644
--- a/compiler/src/CFCCMan.c
+++ b/compiler/src/CFCCMan.c
@@ -410,7 +410,11 @@ S_man_create_inheritance(CFCClass *klass) {
 
 static char*
 S_md_to_man(CFCClass *klass, const char *md, int needs_indent) {
-    cmark_node *doc = cmark_parse_document(md, strlen(md));
+    int options = CMARK_OPT_NORMALIZE
+                  | CMARK_OPT_SMART
+                  | CMARK_OPT_VALIDATE_UTF8
+                  | CMARK_OPT_SAFE;
+    cmark_node *doc = cmark_parse_document(md, strlen(md), options);
     char *result = S_nodes_to_man(klass, doc, needs_indent);
     cmark_node_free(doc);
 

http://git-wip-us.apache.org/repos/asf/lucy-clownfish/blob/89c7b809/compiler/src/CFCPerlPod.c
----------------------------------------------------------------------
diff --git a/compiler/src/CFCPerlPod.c b/compiler/src/CFCPerlPod.c
index 24d6c4b..8fc2eae 100644
--- a/compiler/src/CFCPerlPod.c
+++ b/compiler/src/CFCPerlPod.c
@@ -322,7 +322,11 @@ CFCPerlPod_gen_subroutine_pod(CFCFunction *func,
 
 char*
 CFCPerlPod_md_to_pod(const char *md, CFCClass *klass, int header_level) {
-    cmark_node *doc = cmark_parse_document(md, strlen(md));
+    int options = CMARK_OPT_NORMALIZE
+                  | CMARK_OPT_SMART
+                  | CMARK_OPT_VALIDATE_UTF8
+                  | CMARK_OPT_SAFE;
+    cmark_node *doc = cmark_parse_document(md, strlen(md), options);
     char *pod = S_nodes_to_pod(doc, klass, header_level);
     cmark_node_free(doc);
 


[06/20] lucy-clownfish git commit: Upgrade libcmark to 0.21.0

Posted by nw...@apache.org.
http://git-wip-us.apache.org/repos/asf/lucy-clownfish/blob/89c7b809/compiler/modules/CommonMark/src/inlines.c
----------------------------------------------------------------------
diff --git a/compiler/modules/CommonMark/src/inlines.c b/compiler/modules/CommonMark/src/inlines.c
index 2487f63..7ea308d 100644
--- a/compiler/modules/CommonMark/src/inlines.c
+++ b/compiler/modules/CommonMark/src/inlines.c
@@ -14,6 +14,15 @@
 #include "inlines.h"
 
 
+static const char *EMDASH = "\xE2\x80\x94";
+static const char *ENDASH = "\xE2\x80\x93";
+static const char *ELLIPSES = "\xE2\x80\xA6";
+static const char *LEFTDOUBLEQUOTE = "\xE2\x80\x9C";
+static const char *RIGHTDOUBLEQUOTE = "\xE2\x80\x9D";
+static const char *LEFTSINGLEQUOTE = "\xE2\x80\x98";
+static const char *RIGHTSINGLEQUOTE = "\xE2\x80\x99";
+
+
 // Macros for creating various kinds of simple.
 #define make_str(s) make_literal(CMARK_NODE_TEXT, s)
 #define make_code(s) make_literal(CMARK_NODE_CODE, s)
@@ -27,8 +36,8 @@ typedef struct delimiter {
 	struct delimiter *previous;
 	struct delimiter *next;
 	cmark_node *inl_text;
+	bufsize_t position;
 	unsigned char delim_char;
-	int position;
 	bool can_open;
 	bool can_close;
 	bool active;
@@ -36,45 +45,53 @@ typedef struct delimiter {
 
 typedef struct {
 	cmark_chunk input;
-	int pos;
+	bufsize_t pos;
 	cmark_reference_map *refmap;
 	delimiter *last_delim;
 } subject;
 
+static inline bool
+S_is_line_end_char(char c)
+{
+	return (c == '\n' || c == '\r');
+}
+
 static delimiter*
 S_insert_emph(subject *subj, delimiter *opener, delimiter *closer);
 
-static int parse_inline(subject* subj, cmark_node * parent);
+static int parse_inline(subject* subj, cmark_node * parent, int options);
 
 static void subject_from_buf(subject *e, cmark_strbuf *buffer,
                              cmark_reference_map *refmap);
-static int subject_find_special_char(subject *subj);
+static bufsize_t subject_find_special_char(subject *subj, int options);
 
-static unsigned char *cmark_clean_autolink(cmark_chunk *url, int is_email)
+static cmark_chunk cmark_clean_autolink(cmark_chunk *url, int is_email)
 {
 	cmark_strbuf buf = GH_BUF_INIT;
 
 	cmark_chunk_trim(url);
 
-	if (url->len == 0)
-		return NULL;
+	if (url->len == 0) {
+		cmark_chunk result = CMARK_CHUNK_EMPTY;
+		return result;
+	}
 
 	if (is_email)
 		cmark_strbuf_puts(&buf, "mailto:");
 
 	houdini_unescape_html_f(&buf, url->data, url->len);
-	return cmark_strbuf_detach(&buf);
+	return cmark_chunk_buf_detach(&buf);
 }
 
-static inline cmark_node *make_link(cmark_node *label, unsigned char *url, unsigned char *title)
+static inline cmark_node *make_link(cmark_node *label, cmark_chunk *url, cmark_chunk *title)
 {
 	cmark_node* e = (cmark_node *)calloc(1, sizeof(*e));
 	if(e != NULL) {
 		e->type = CMARK_NODE_LINK;
 		e->first_child   = label;
 		e->last_child    = label;
-		e->as.link.url   = url;
-		e->as.link.title = title;
+		e->as.link.url   = *url;
+		e->as.link.title = *title;
 		e->next = NULL;
 		label->parent = e;
 	}
@@ -83,7 +100,9 @@ static inline cmark_node *make_link(cmark_node *label, unsigned char *url, unsig
 
 static inline cmark_node* make_autolink(cmark_node* label, cmark_chunk url, int is_email)
 {
-	return make_link(label, cmark_clean_autolink(&url, is_email), NULL);
+	cmark_chunk clean_url = cmark_clean_autolink(&url, is_email);
+	cmark_chunk title = CMARK_CHUNK_EMPTY;
+	return make_link(label, &clean_url, &title);
 }
 
 // Create an inline with a literal string value.
@@ -125,19 +144,20 @@ static inline cmark_node* make_simple(cmark_node_type t)
 	return e;
 }
 
-static unsigned char *bufdup(const unsigned char *buf)
+// Duplicate a chunk by creating a copy of the buffer not by reusing the
+// buffer like cmark_chunk_dup does.
+static cmark_chunk chunk_clone(cmark_chunk *src)
 {
-	unsigned char *new_buf = NULL;
+	cmark_chunk c;
+	bufsize_t len = src->len;
 
-	if (buf) {
-		int len = strlen((char *)buf);
-		new_buf = (unsigned char *)calloc(len + 1, sizeof(*new_buf));
-		if(new_buf != NULL) {
-			memcpy(new_buf, buf, len + 1);
-		}
-	}
+	c.len   = len;
+	c.data  = (unsigned char *)malloc(len + 1);
+	c.alloc = 1;
+	memcpy(c.data, src->data, len);
+	c.data[len] = '\0';
 
-	return new_buf;
+	return c;
 }
 
 static void subject_from_buf(subject *e, cmark_strbuf *buffer,
@@ -149,8 +169,6 @@ static void subject_from_buf(subject *e, cmark_strbuf *buffer,
 	e->pos = 0;
 	e->refmap = refmap;
 	e->last_delim = NULL;
-
-	cmark_chunk_rtrim(&e->input);
 }
 
 static inline int isbacktick(int c)
@@ -160,10 +178,13 @@ static inline int isbacktick(int c)
 
 static inline unsigned char peek_char(subject *subj)
 {
+	// NULL bytes should have been stripped out by now.  If they're
+	// present, it's a programming error:
+	assert(!(subj->pos < subj->input.len && subj->input.data[subj->pos] == 0));
 	return (subj->pos < subj->input.len) ? subj->input.data[subj->pos] : 0;
 }
 
-static inline unsigned char peek_at(subject *subj, int pos)
+static inline unsigned char peek_at(subject *subj, bufsize_t pos)
 {
 	return subj->input.data[pos];
 }
@@ -177,12 +198,38 @@ static inline int is_eof(subject* subj)
 // Advance the subject.  Doesn't check for eof.
 #define advance(subj) (subj)->pos += 1
 
+static inline bool
+skip_spaces(subject *subj)
+{
+	bool skipped = false;
+	while (peek_char(subj) == ' ' || peek_char(subj) == '\t') {
+		advance(subj);
+		skipped = true;
+	}
+	return skipped;
+}
+
+static inline bool
+skip_line_end(subject *subj)
+{
+	bool seen_line_end_char = false;
+	if (peek_char(subj) == '\r') {
+		advance(subj);
+		seen_line_end_char = true;
+	}
+	if (peek_char(subj) == '\n') {
+		advance(subj);
+		seen_line_end_char = true;
+	}
+	return seen_line_end_char || is_eof(subj);
+}
+
 // Take characters while a predicate holds, and return a string.
 static inline cmark_chunk take_while(subject* subj, int (*f)(int))
 {
 	unsigned char c;
-	int startpos = subj->pos;
-	int len = 0;
+	bufsize_t startpos = subj->pos;
+	bufsize_t len = 0;
 
 	while ((c = peek_char(subj)) && (*f)(c)) {
 		advance(subj);
@@ -197,7 +244,7 @@ static inline cmark_chunk take_while(subject* subj, int (*f)(int))
 // parsed).  Return 0 if you don't find matching closing
 // backticks, otherwise return the position in the subject
 // after the closing backticks.
-static int scan_to_closing_backticks(subject* subj, int openticklength)
+static bufsize_t scan_to_closing_backticks(subject* subj, bufsize_t openticklength)
 {
 	// read non backticks
 	unsigned char c;
@@ -207,7 +254,7 @@ static int scan_to_closing_backticks(subject* subj, int openticklength)
 	if (is_eof(subj)) {
 		return 0;  // did not find closing ticks, return 0
 	}
-	int numticks = 0;
+	bufsize_t numticks = 0;
 	while (peek_char(subj) == '`') {
 		advance(subj);
 		numticks++;
@@ -223,8 +270,8 @@ static int scan_to_closing_backticks(subject* subj, int openticklength)
 static cmark_node* handle_backticks(subject *subj)
 {
 	cmark_chunk openticks = take_while(subj, isbacktick);
-	int startpos = subj->pos;
-	int endpos = scan_to_closing_backticks(subj, openticks.len);
+	bufsize_t startpos = subj->pos;
+	bufsize_t endpos = scan_to_closing_backticks(subj, openticks.len);
 
 	if (endpos == 0) { // not found
 		subj->pos = startpos; // rewind
@@ -246,10 +293,11 @@ static int
 scan_delims(subject* subj, unsigned char c, bool * can_open, bool * can_close)
 {
 	int numdelims = 0;
-	int before_char_pos;
+	bufsize_t before_char_pos;
 	int32_t after_char = 0;
 	int32_t before_char = 0;
 	int len;
+	bool left_flanking, right_flanking;
 
 	if (subj->pos == 0) {
 		before_char = 10;
@@ -267,9 +315,14 @@ scan_delims(subject* subj, unsigned char c, bool * can_open, bool * can_close)
 		}
 	}
 
-	while (peek_char(subj) == c) {
+	if (c == '\'' || c == '"') {
 		numdelims++;
-		advance(subj);
+		advance(subj);  // limit to 1 delim for quotes
+	} else {
+		while (peek_char(subj) == c) {
+			numdelims++;
+			advance(subj);
+		}
 	}
 
 	len = utf8proc_iterate(subj->input.data + subj->pos,
@@ -277,19 +330,25 @@ scan_delims(subject* subj, unsigned char c, bool * can_open, bool * can_close)
 	if (len == -1) {
 		after_char = 10;
 	}
-	*can_open = numdelims > 0 && !utf8proc_is_space(after_char) &&
-	            !(utf8proc_is_punctuation(after_char) &&
-	              !utf8proc_is_space(before_char) &&
-	              !utf8proc_is_punctuation(before_char));
-	*can_close = numdelims > 0 && !utf8proc_is_space(before_char) &&
-	             !(utf8proc_is_punctuation(before_char) &&
-	               !utf8proc_is_space(after_char) &&
-	               !utf8proc_is_punctuation(after_char));
+	left_flanking = numdelims > 0 && !utf8proc_is_space(after_char) &&
+	                !(utf8proc_is_punctuation(after_char) &&
+	                  !utf8proc_is_space(before_char) &&
+	                  !utf8proc_is_punctuation(before_char));
+	right_flanking = numdelims > 0 && !utf8proc_is_space(before_char) &&
+	                 !(utf8proc_is_punctuation(before_char) &&
+	                   !utf8proc_is_space(after_char) &&
+	                   !utf8proc_is_punctuation(after_char));
 	if (c == '_') {
-		*can_open = *can_open && !(before_char < 128 &&
-		                           cmark_isalnum((char)before_char));
-		*can_close = *can_close && !(before_char < 128 &&
-		                             cmark_isalnum((char)after_char));
+		*can_open = left_flanking &&
+		            (!right_flanking || utf8proc_is_punctuation(before_char));
+		*can_close = right_flanking &&
+		             (!left_flanking || utf8proc_is_punctuation(after_char));
+	} else if (c == '\'' || c == '"') {
+		*can_open = left_flanking && !right_flanking;
+		*can_close = right_flanking;
+	} else {
+		*can_open = left_flanking;
+		*can_close = right_flanking;
 	}
 	return numdelims;
 }
@@ -300,10 +359,10 @@ static void print_delimiters(subject *subj)
 	delimiter *delim;
 	delim = subj->last_delim;
 	while (delim != NULL) {
-		printf("Item at %p: %d %d %d next(%p) prev(%p)\n",
-		       delim, delim->delim_char,
+		printf("Item at stack pos %p, text pos %d: %d %d %d next(%p) prev(%p)\n",
+		       (void*)delim, delim->position, delim->delim_char,
 		       delim->can_open, delim->can_close,
-		       delim->next, delim->previous);
+		       (void*)delim->next, (void*)delim->previous);
 		delim = delim->previous;
 	}
 }
@@ -347,59 +406,175 @@ static void push_delimiter(subject *subj, unsigned char c, bool can_open,
 	subj->last_delim = delim;
 }
 
-// Parse strong/emph or a fallback.
-// Assumes the subject has '_' or '*' at the current position.
-static cmark_node* handle_strong_emph(subject* subj, unsigned char c)
+// Assumes the subject has a c at the current position.
+static cmark_node* handle_delim(subject* subj, unsigned char c, bool smart)
 {
-	int numdelims;
+	bufsize_t numdelims;
 	cmark_node * inl_text;
 	bool can_open, can_close;
+	cmark_chunk contents;
 
 	numdelims = scan_delims(subj, c, &can_open, &can_close);
 
-	inl_text = make_str(cmark_chunk_dup(&subj->input, subj->pos - numdelims, numdelims));
+	if (c == '\'' && smart) {
+		contents = cmark_chunk_literal(RIGHTSINGLEQUOTE);
+	} else if (c == '"' && smart) {
+		contents = cmark_chunk_literal(can_close ? RIGHTDOUBLEQUOTE : LEFTDOUBLEQUOTE);
+	} else {
+		contents = cmark_chunk_dup(&subj->input, subj->pos - numdelims, numdelims);
+	}
 
-	if (can_open || can_close) {
+	inl_text = make_str(contents);
+
+	if ((can_open || can_close) &&
+	    (!(c == '\'' || c == '"') || smart)) {
 		push_delimiter(subj, c, can_open, can_close, inl_text);
 	}
 
 	return inl_text;
 }
 
-static void process_emphasis(subject *subj, delimiter *start_delim)
+// Assumes we have a hyphen at the current position.
+static cmark_node* handle_hyphen(subject* subj, bool smart)
+{
+	int startpos = subj->pos;
+
+	advance(subj);
+
+	if (!smart || peek_char(subj) != '-') {
+		return make_str(cmark_chunk_literal("-"));
+	}
+
+	while (smart && peek_char(subj) == '-') {
+		advance(subj);
+	}
+
+	int numhyphens = subj->pos - startpos;
+	int en_count = 0;
+	int em_count = 0;
+	int i;
+	cmark_strbuf buf = GH_BUF_INIT;
+
+	if (numhyphens % 3 == 0) { // if divisible by 3, use all em dashes
+		em_count = numhyphens / 3;
+	} else if (numhyphens % 2 == 0) { // if divisible by 2, use all en dashes
+		en_count = numhyphens / 2;
+	} else if (numhyphens % 3 == 2) { // use one en dash at end
+		en_count = 1;
+		em_count = (numhyphens - 2) / 3;
+	} else { // use two en dashes at the end
+		en_count = 2;
+		em_count = (numhyphens - 4) / 3;
+	}
+
+	for (i = em_count; i > 0; i--) {
+		cmark_strbuf_puts(&buf, EMDASH);
+	}
+
+	for (i = en_count; i > 0; i--) {
+		cmark_strbuf_puts(&buf, ENDASH);
+	}
+
+	return make_str(cmark_chunk_buf_detach(&buf));
+}
+
+// Assumes we have a period at the current position.
+static cmark_node* handle_period(subject* subj, bool smart)
+{
+	advance(subj);
+	if (smart && peek_char(subj) == '.') {
+		advance(subj);
+		if (peek_char(subj) == '.') {
+			advance(subj);
+			return make_str(cmark_chunk_literal(ELLIPSES));
+		} else {
+			return make_str(cmark_chunk_literal(".."));
+		}
+	} else {
+		return make_str(cmark_chunk_literal("."));
+	}
+}
+
+static void process_emphasis(subject *subj, delimiter *stack_bottom)
 {
 	delimiter *closer = subj->last_delim;
 	delimiter *opener;
+	delimiter *old_closer;
+	bool opener_found;
+	delimiter *openers_bottom[128];
+
+	// initialize openers_bottom:
+	openers_bottom['*'] = stack_bottom;
+	openers_bottom['_'] = stack_bottom;
+	openers_bottom['\''] = stack_bottom;
+	openers_bottom['"'] = stack_bottom;
 
 	// move back to first relevant delim.
-	while (closer != NULL && closer->previous != start_delim) {
+	while (closer != NULL && closer->previous != stack_bottom) {
 		closer = closer->previous;
 	}
 
 	// now move forward, looking for closers, and handling each
 	while (closer != NULL) {
 		if (closer->can_close &&
-		    (closer->delim_char == '*' || closer->delim_char == '_')) {
+		    (closer->delim_char == '*' || closer->delim_char == '_' ||
+		     closer->delim_char == '"' || closer->delim_char == '\'')) {
 			// Now look backwards for first matching opener:
 			opener = closer->previous;
-			while (opener != NULL && opener != start_delim) {
+			opener_found = false;
+			while (opener != NULL && opener != stack_bottom &&
+			       opener != openers_bottom[closer->delim_char]) {
 				if (opener->delim_char == closer->delim_char &&
 				    opener->can_open) {
+					opener_found = true;
 					break;
 				}
 				opener = opener->previous;
 			}
-			if (opener != NULL && opener != start_delim) {
-				closer = S_insert_emph(subj, opener, closer);
-			} else {
+			old_closer = closer;
+			if (closer->delim_char == '*' || closer->delim_char == '_') {
+				if (opener_found) {
+					closer = S_insert_emph(subj, opener, closer);
+				} else {
+					closer = closer->next;
+				}
+			} else if (closer->delim_char == '\'') {
+				cmark_chunk_free(&closer->inl_text->as.literal);
+				closer->inl_text->as.literal =
+				    cmark_chunk_literal(RIGHTSINGLEQUOTE);
+				if (opener_found) {
+					cmark_chunk_free(&opener->inl_text->as.literal);
+					opener->inl_text->as.literal =
+					    cmark_chunk_literal(LEFTSINGLEQUOTE);
+				}
 				closer = closer->next;
+			} else if (closer->delim_char == '"') {
+				cmark_chunk_free(&closer->inl_text->as.literal);
+				closer->inl_text->as.literal =
+				    cmark_chunk_literal(RIGHTDOUBLEQUOTE);
+				if (opener_found) {
+					cmark_chunk_free(&opener->inl_text->as.literal);
+					opener->inl_text->as.literal =
+					    cmark_chunk_literal(LEFTDOUBLEQUOTE);
+				}
+				closer = closer->next;
+			}
+			if (!opener_found) {
+				// set lower bound for future searches for openers:
+				openers_bottom[old_closer->delim_char] = old_closer->previous;
+				if (!old_closer->can_open) {
+					// we can remove a closer that can't be an
+					// opener, once we've seen there's no
+					// matching opener:
+					remove_delimiter(subj, old_closer);
+				}
 			}
 		} else {
 			closer = closer->next;
 		}
 	}
-	// free all delimiters in list until start_delim:
-	while (subj->last_delim != start_delim) {
+	// free all delimiters in list until stack_bottom:
+	while (subj->last_delim != stack_bottom) {
 		remove_delimiter(subj, subj->last_delim);
 	}
 }
@@ -408,11 +583,11 @@ static delimiter*
 S_insert_emph(subject *subj, delimiter *opener, delimiter *closer)
 {
 	delimiter *delim, *tmp_delim;
-	int use_delims;
+	bufsize_t use_delims;
 	cmark_node *opener_inl = opener->inl_text;
 	cmark_node *closer_inl = closer->inl_text;
-	int opener_num_chars = opener_inl->as.literal.len;
-	int closer_num_chars = closer_inl->as.literal.len;
+	bufsize_t opener_num_chars = opener_inl->as.literal.len;
+	bufsize_t closer_num_chars = closer_inl->as.literal.len;
 	cmark_node *tmp, *emph, *first_child, *last_child;
 
 	// calculate the actual number of characters used from this closer
@@ -491,8 +666,7 @@ static cmark_node* handle_backslash(subject *subj)
 	if (cmark_ispunct(nextchar)) {  // only ascii symbols and newline can be escaped
 		advance(subj);
 		return make_str(cmark_chunk_dup(&subj->input, subj->pos - 1, 1));
-	} else if (nextchar == '\n') {
-		advance(subj);
+	} else if (!is_eof(subj) && skip_line_end(subj)) {
 		return make_linebreak();
 	} else {
 		return make_str(cmark_chunk_literal("\\"));
@@ -504,7 +678,7 @@ static cmark_node* handle_backslash(subject *subj)
 static cmark_node* handle_entity(subject* subj)
 {
 	cmark_strbuf ent = GH_BUF_INIT;
-	size_t len;
+	bufsize_t len;
 
 	advance(subj);
 
@@ -526,7 +700,7 @@ static cmark_node *make_str_with_entities(cmark_chunk *content)
 {
 	cmark_strbuf unescaped = GH_BUF_INIT;
 
-	if (houdini_unescape_html(&unescaped, content->data, (size_t)content->len)) {
+	if (houdini_unescape_html(&unescaped, content->data, content->len)) {
 		return make_str(cmark_chunk_buf_detach(&unescaped));
 	} else {
 		return make_str(*content);
@@ -535,14 +709,16 @@ static cmark_node *make_str_with_entities(cmark_chunk *content)
 
 // Clean a URL: remove surrounding whitespace and surrounding <>,
 // and remove \ that escape punctuation.
-unsigned char *cmark_clean_url(cmark_chunk *url)
+cmark_chunk cmark_clean_url(cmark_chunk *url)
 {
 	cmark_strbuf buf = GH_BUF_INIT;
 
 	cmark_chunk_trim(url);
 
-	if (url->len == 0)
-		return NULL;
+	if (url->len == 0) {
+		cmark_chunk result = CMARK_CHUNK_EMPTY;
+		return result;
+	}
 
 	if (url->data[0] == '<' && url->data[url->len - 1] == '>') {
 		houdini_unescape_html_f(&buf, url->data + 1, url->len - 2);
@@ -551,16 +727,18 @@ unsigned char *cmark_clean_url(cmark_chunk *url)
 	}
 
 	cmark_strbuf_unescape(&buf);
-	return cmark_strbuf_detach(&buf);
+	return cmark_chunk_buf_detach(&buf);
 }
 
-unsigned char *cmark_clean_title(cmark_chunk *title)
+cmark_chunk cmark_clean_title(cmark_chunk *title)
 {
 	cmark_strbuf buf = GH_BUF_INIT;
 	unsigned char first, last;
 
-	if (title->len == 0)
-		return NULL;
+	if (title->len == 0) {
+		cmark_chunk result = CMARK_CHUNK_EMPTY;
+		return result;
+	}
 
 	first = title->data[0];
 	last = title->data[title->len - 1];
@@ -575,14 +753,14 @@ unsigned char *cmark_clean_title(cmark_chunk *title)
 	}
 
 	cmark_strbuf_unescape(&buf);
-	return cmark_strbuf_detach(&buf);
+	return cmark_chunk_buf_detach(&buf);
 }
 
 // Parse an autolink or HTML tag.
 // Assumes the subject has a '<' character at the current position.
 static cmark_node* handle_pointy_brace(subject* subj)
 {
-	int matchlen = 0;
+	bufsize_t matchlen = 0;
 	cmark_chunk contents;
 
 	advance(subj);  // advance past first <
@@ -629,7 +807,7 @@ static cmark_node* handle_pointy_brace(subject* subj)
 // encountered.  Backticks in labels do not start code spans.
 static int link_label(subject* subj, cmark_chunk *raw_label)
 {
-	int startpos = subj->pos;
+	bufsize_t startpos = subj->pos;
 	int length = 0;
 	unsigned char c;
 
@@ -659,6 +837,7 @@ static int link_label(subject* subj, cmark_chunk *raw_label)
 
 	if (c == ']') { // match found
 		*raw_label = cmark_chunk_dup(&subj->input, startpos + 1, subj->pos - (startpos + 1));
+		cmark_chunk_trim(raw_label);
 		advance(subj);  // advance past ]
 		return 1;
 	}
@@ -672,14 +851,14 @@ noMatch:
 // Return a link, an image, or a literal close bracket.
 static cmark_node* handle_close_bracket(subject* subj, cmark_node *parent)
 {
-	int initial_pos;
-	int starturl, endurl, starttitle, endtitle, endall;
-	int n;
-	int sps;
+	bufsize_t initial_pos;
+	bufsize_t starturl, endurl, starttitle, endtitle, endall;
+	bufsize_t n;
+	bufsize_t sps;
 	cmark_reference *ref;
 	bool is_image = false;
 	cmark_chunk url_chunk, title_chunk;
-	unsigned char *url, *title;
+	cmark_chunk url, title;
 	delimiter *opener;
 	cmark_node *link_text;
 	cmark_node *inl;
@@ -767,8 +946,8 @@ static cmark_node* handle_close_bracket(subject* subj, cmark_node *parent)
 	cmark_chunk_free(&raw_label);
 
 	if (ref != NULL) { // found
-		url = bufdup(ref->url);
-		title = bufdup(ref->title);
+		url   = chunk_clone(&ref->url);
+		title = chunk_clone(&ref->title);
 		goto match;
 	} else {
 		goto noMatch;
@@ -785,7 +964,7 @@ match:
 	inl->type = is_image ? NODE_IMAGE : NODE_LINK;
 	cmark_chunk_free(&inl->as.literal);
 	inl->first_child = link_text;
-	process_emphasis(subj, opener->previous);
+	process_emphasis(subj, opener);
 	inl->as.link.url   = url;
 	inl->as.link.title = title;
 	inl->next = NULL;
@@ -800,10 +979,10 @@ match:
 	}
 	parent->last_child = inl;
 
-	// process_emphasis will remove this delimiter and all later ones.
 	// Now, if we have a link, we also want to deactivate earlier link
 	// delimiters. (This code can be removed if we decide to allow links
 	// inside links.)
+	remove_delimiter(subj, opener);
 	if (!is_image) {
 		opener = subj->last_delim;
 		while (opener != NULL) {
@@ -825,13 +1004,11 @@ match:
 // Assumes the subject has a newline at the current position.
 static cmark_node* handle_newline(subject *subj)
 {
-	int nlpos = subj->pos;
+	bufsize_t nlpos = subj->pos;
 	// skip over newline
 	advance(subj);
 	// skip spaces at beginning of line
-	while (peek_char(subj) == ' ') {
-		advance(subj);
-	}
+	skip_spaces(subj);
 	if (nlpos > 1 &&
 	    peek_at(subj, nlpos - 1) == ' ' &&
 	    peek_at(subj, nlpos - 2) == ' ') {
@@ -841,11 +1018,11 @@ static cmark_node* handle_newline(subject *subj)
 	}
 }
 
-static int subject_find_special_char(subject *subj)
+static bufsize_t subject_find_special_char(subject *subj, int options)
 {
-	// "\n\\`&_*[]<!"
+	// "\r\n\\`&_*[]<!"
 	static const int8_t SPECIAL_CHARS[256] = {
-		0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0,
+		0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 1, 0, 0,
 		0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
 		0, 1, 0, 0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 0, 0,
 		0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0,
@@ -863,11 +1040,34 @@ static int subject_find_special_char(subject *subj)
 		0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0
 	};
 
-	int n = subj->pos + 1;
+	// " ' . -
+	static const char SMART_PUNCT_CHARS[] = {
+		0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+		0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+		0, 0, 1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 1, 1, 0,
+		0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+		0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+		0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+		0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+		0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+		0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+		0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+		0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+		0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+		0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+		0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+		0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+		0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+	};
+
+	bufsize_t n = subj->pos + 1;
 
 	while (n < subj->input.len) {
 		if (SPECIAL_CHARS[subj->input.data[n]])
 			return n;
+		if (options & CMARK_OPT_SMART &&
+		    SMART_PUNCT_CHARS[subj->input.data[n]])
+			return n;
 		n++;
 	}
 
@@ -876,17 +1076,18 @@ static int subject_find_special_char(subject *subj)
 
 // Parse an inline, advancing subject, and add it as a child of parent.
 // Return 0 if no inline can be parsed, 1 otherwise.
-static int parse_inline(subject* subj, cmark_node * parent)
+static int parse_inline(subject* subj, cmark_node * parent, int options)
 {
 	cmark_node* new_inl = NULL;
 	cmark_chunk contents;
 	unsigned char c;
-	int endpos;
+	bufsize_t endpos;
 	c = peek_char(subj);
 	if (c == 0) {
 		return 0;
 	}
 	switch(c) {
+	case '\r':
 	case '\n':
 		new_inl = handle_newline(subj);
 		break;
@@ -904,7 +1105,15 @@ static int parse_inline(subject* subj, cmark_node * parent)
 		break;
 	case '*':
 	case '_':
-		new_inl = handle_strong_emph(subj, c);
+	case '\'':
+	case '"':
+		new_inl = handle_delim(subj, c, options & CMARK_OPT_SMART);
+		break;
+	case '-':
+		new_inl = handle_hyphen(subj, options & CMARK_OPT_SMART);
+		break;
+	case '.':
+		new_inl = handle_period(subj, options & CMARK_OPT_SMART);
 		break;
 	case '[':
 		advance(subj);
@@ -925,12 +1134,12 @@ static int parse_inline(subject* subj, cmark_node * parent)
 		}
 		break;
 	default:
-		endpos = subject_find_special_char(subj);
+		endpos = subject_find_special_char(subj, options);
 		contents = cmark_chunk_dup(&subj->input, subj->pos, endpos - subj->pos);
 		subj->pos = endpos;
 
 		// if we're at a newline, strip trailing spaces.
-		if (peek_char(subj) == '\n') {
+		if (S_is_line_end_char(peek_char(subj))) {
 			cmark_chunk_rtrim(&contents);
 		}
 
@@ -944,12 +1153,13 @@ static int parse_inline(subject* subj, cmark_node * parent)
 }
 
 // Parse inlines from parent's string_content, adding as children of parent.
-extern void cmark_parse_inlines(cmark_node* parent, cmark_reference_map *refmap)
+extern void cmark_parse_inlines(cmark_node* parent, cmark_reference_map *refmap, int options)
 {
 	subject subj;
 	subject_from_buf(&subj, &parent->string_content, refmap);
+	cmark_chunk_rtrim(&subj.input);
 
-	while (!is_eof(&subj) && parse_inline(&subj, parent)) ;
+	while (!is_eof(&subj) && parse_inline(&subj, parent, options)) ;
 
 	process_emphasis(&subj, NULL);
 }
@@ -957,11 +1167,9 @@ extern void cmark_parse_inlines(cmark_node* parent, cmark_reference_map *refmap)
 // Parse zero or more space characters, including at most one newline.
 static void spnl(subject* subj)
 {
-	bool seen_newline = false;
-	while (peek_char(subj) == ' ' ||
-	       (!seen_newline &&
-	        (seen_newline = peek_char(subj) == '\n'))) {
-		advance(subj);
+	skip_spaces(subj);
+	if (skip_line_end(subj)) {
+		skip_spaces(subj);
 	}
 }
 
@@ -969,7 +1177,7 @@ static void spnl(subject* subj)
 // Modify refmap if a reference is encountered.
 // Return 0 if no reference found, otherwise position of subject
 // after reference is parsed.
-int cmark_parse_reference_inline(cmark_strbuf *input, cmark_reference_map *refmap)
+bufsize_t cmark_parse_reference_inline(cmark_strbuf *input, cmark_reference_map *refmap)
 {
 	subject subj;
 
@@ -977,13 +1185,13 @@ int cmark_parse_reference_inline(cmark_strbuf *input, cmark_reference_map *refma
 	cmark_chunk url;
 	cmark_chunk title;
 
-	int matchlen = 0;
-	int beforetitle;
+	bufsize_t matchlen = 0;
+	bufsize_t beforetitle;
 
 	subject_from_buf(&subj, input, NULL);
 
 	// parse label:
-	if (!link_label(&subj, &lab))
+	if (!link_label(&subj, &lab) || lab.len == 0)
 		return 0;
 
 	// colon:
@@ -1014,14 +1222,19 @@ int cmark_parse_reference_inline(cmark_strbuf *input, cmark_reference_map *refma
 		subj.pos = beforetitle;
 		title = cmark_chunk_literal("");
 	}
+
 	// parse final spaces and newline:
-	while (peek_char(&subj) == ' ') {
-		advance(&subj);
-	}
-	if (peek_char(&subj) == '\n') {
-		advance(&subj);
-	} else if (peek_char(&subj) != 0) {
-		return 0;
+	skip_spaces(&subj);
+	if (!skip_line_end(&subj)) {
+		if (matchlen) { // try rewinding before title
+			subj.pos = beforetitle;
+			skip_spaces(&subj);
+			if (!skip_line_end(&subj)) {
+				return 0;
+			}
+		} else {
+			return 0;
+		}
 	}
 	// insert reference into refmap
 	cmark_reference_create(refmap, &lab, &url, &title);

http://git-wip-us.apache.org/repos/asf/lucy-clownfish/blob/89c7b809/compiler/modules/CommonMark/src/inlines.h
----------------------------------------------------------------------
diff --git a/compiler/modules/CommonMark/src/inlines.h b/compiler/modules/CommonMark/src/inlines.h
index d2ccfb4..f8847fc 100644
--- a/compiler/modules/CommonMark/src/inlines.h
+++ b/compiler/modules/CommonMark/src/inlines.h
@@ -5,12 +5,12 @@
 extern "C" {
 #endif
 
-unsigned char *cmark_clean_url(cmark_chunk *url);
-unsigned char *cmark_clean_title(cmark_chunk *title);
+cmark_chunk cmark_clean_url(cmark_chunk *url);
+cmark_chunk cmark_clean_title(cmark_chunk *title);
 
-void cmark_parse_inlines(cmark_node* parent, cmark_reference_map *refmap);
+void cmark_parse_inlines(cmark_node* parent, cmark_reference_map *refmap, int options);
 
-int cmark_parse_reference_inline(cmark_strbuf *input, cmark_reference_map *refmap);
+bufsize_t cmark_parse_reference_inline(cmark_strbuf *input, cmark_reference_map *refmap);
 
 #ifdef __cplusplus
 }

http://git-wip-us.apache.org/repos/asf/lucy-clownfish/blob/89c7b809/compiler/modules/CommonMark/src/iterator.c
----------------------------------------------------------------------
diff --git a/compiler/modules/CommonMark/src/iterator.c b/compiler/modules/CommonMark/src/iterator.c
index 4daec2d..f18e3bf 100644
--- a/compiler/modules/CommonMark/src/iterator.c
+++ b/compiler/modules/CommonMark/src/iterator.c
@@ -108,6 +108,12 @@ cmark_iter_get_event_type(cmark_iter *iter)
 	return iter->cur.ev_type;
 }
 
+cmark_node*
+cmark_iter_get_root(cmark_iter *iter)
+{
+	return iter->root;
+}
+
 
 void cmark_consolidate_text_nodes(cmark_node *root)
 {
@@ -123,18 +129,20 @@ void cmark_consolidate_text_nodes(cmark_node *root)
 		    cur->next &&
 		    cur->next->type == CMARK_NODE_TEXT) {
 			cmark_strbuf_clear(&buf);
-			cmark_strbuf_puts(&buf, cmark_node_get_literal(cur));
+			cmark_strbuf_put(&buf, cur->as.literal.data, cur->as.literal.len);
 			tmp = cur->next;
 			while (tmp && tmp->type == CMARK_NODE_TEXT) {
-				cmark_iter_get_node(iter); // advance pointer
-				cmark_strbuf_puts(&buf, cmark_node_get_literal(tmp));
+				cmark_iter_next(iter); // advance pointer
+				cmark_strbuf_put(&buf, tmp->as.literal.data, tmp->as.literal.len);
 				next = tmp->next;
 				cmark_node_free(tmp);
 				tmp = next;
 			}
-			cmark_node_set_literal(cur, (char *)cmark_strbuf_detach(&buf));
+			cmark_chunk_free(&cur->as.literal);
+			cur->as.literal = cmark_chunk_buf_detach(&buf);
 		}
 	}
 
+	cmark_strbuf_free(&buf);
 	cmark_iter_free(iter);
 }

http://git-wip-us.apache.org/repos/asf/lucy-clownfish/blob/89c7b809/compiler/modules/CommonMark/src/latex.c
----------------------------------------------------------------------
diff --git a/compiler/modules/CommonMark/src/latex.c b/compiler/modules/CommonMark/src/latex.c
new file mode 100644
index 0000000..782b0c0
--- /dev/null
+++ b/compiler/modules/CommonMark/src/latex.c
@@ -0,0 +1,430 @@
+#include <stdlib.h>
+#include <stdio.h>
+#include <string.h>
+#include <assert.h>
+#include <ctype.h>
+
+#include "config.h"
+#include "cmark.h"
+#include "node.h"
+#include "buffer.h"
+#include "utf8.h"
+#include "scanners.h"
+#include "render.h"
+
+#define safe_strlen(s) cmark_strbuf_safe_strlen(s)
+#define OUT(s, wrap, escaping) renderer->out(renderer, s, wrap, escaping)
+#define LIT(s) renderer->out(renderer, s, false, LITERAL)
+#define CR() renderer->cr(renderer)
+#define BLANKLINE() renderer->blankline(renderer)
+
+static inline void outc(cmark_renderer *renderer,
+                        cmark_escaping escape,
+                        int32_t c,
+                        unsigned char nextc)
+{
+	if (escape == LITERAL) {
+		cmark_render_code_point(renderer, c);
+		return;
+	}
+
+	switch(c) {
+	case 123: // '{'
+	case 125: // '}'
+	case 35: // '#'
+	case 37: // '%'
+	case 38: // '&'
+		cmark_render_ascii(renderer, "\\");
+		cmark_render_code_point(renderer, c);
+		break;
+	case 36: // '$'
+	case 95: // '_'
+		if (escape == NORMAL) {
+			cmark_render_ascii(renderer, "\\");
+		}
+		cmark_render_code_point(renderer, c);
+		break;
+	case 45 : // '-'
+		if (nextc == 45) { // prevent ligature
+			cmark_render_ascii(renderer, "\\-");
+		} else {
+			cmark_render_ascii(renderer, "-");
+		}
+		break;
+	case 126: // '~'
+		if (escape == NORMAL) {
+			cmark_render_ascii(renderer, "\\textasciitilde{}");
+		} else {
+			cmark_render_code_point(renderer, c);
+		}
+		break;
+	case 94: // '^'
+		cmark_render_ascii(renderer, "\\^{}");
+		break;
+	case 92: // '\\'
+		if (escape == URL) {
+			// / acts as path sep even on windows:
+			cmark_render_ascii(renderer, "/");
+		} else {
+			cmark_render_ascii(renderer, "\\textbackslash{}");
+		}
+		break;
+	case 124: // '|'
+		cmark_render_ascii(renderer, "\\textbar{}");
+		break;
+	case 60: // '<'
+		cmark_render_ascii(renderer, "\\textless{}");
+		break;
+	case 62: // '>'
+		cmark_render_ascii(renderer, "\\textgreater{}");
+		break;
+	case 91: // '['
+	case 93: // ']'
+		cmark_render_ascii(renderer, "{");
+		cmark_render_code_point(renderer, c);
+		cmark_render_ascii(renderer, "}");
+		break;
+	case 34: // '"'
+		cmark_render_ascii(renderer, "\\textquotedbl{}");
+		// requires \usepackage[T1]{fontenc}
+		break;
+	case 39: // '\''
+		cmark_render_ascii(renderer, "\\textquotesingle{}");
+		// requires \usepackage{textcomp}
+		break;
+	case 160: // nbsp
+		cmark_render_ascii(renderer, "~");
+		break;
+	case 8230: // hellip
+		cmark_render_ascii(renderer, "\\ldots{}");
+		break;
+	case 8216: // lsquo
+		if (escape == NORMAL) {
+			cmark_render_ascii(renderer, "`");
+		} else {
+			cmark_render_code_point(renderer, c);
+		}
+		break;
+	case 8217: // rsquo
+		if (escape == NORMAL) {
+			cmark_render_ascii(renderer, "\'");
+		} else {
+			cmark_render_code_point(renderer, c);
+		}
+		break;
+	case 8220: // ldquo
+		if (escape == NORMAL) {
+			cmark_render_ascii(renderer, "``");
+		} else {
+			cmark_render_code_point(renderer, c);
+		}
+		break;
+	case 8221: // rdquo
+		if (escape == NORMAL) {
+			cmark_render_ascii(renderer, "''");
+		} else {
+			cmark_render_code_point(renderer, c);
+		}
+		break;
+	case 8212: // emdash
+		if (escape == NORMAL) {
+			cmark_render_ascii(renderer, "---");
+		} else {
+			cmark_render_code_point(renderer, c);
+		}
+		break;
+	case 8211: // endash
+		if (escape == NORMAL) {
+			cmark_render_ascii(renderer, "--");
+		} else {
+			cmark_render_code_point(renderer, c);
+		}
+		break;
+	default:
+		cmark_render_code_point(renderer, c);
+	}
+}
+
+typedef enum  {
+	NO_LINK,
+	URL_AUTOLINK,
+	EMAIL_AUTOLINK,
+	NORMAL_LINK
+} link_type;
+
+static link_type
+get_link_type(cmark_node *node)
+{
+	size_t title_len, url_len;
+	cmark_node *link_text;
+	char *realurl;
+	int realurllen;
+	bool isemail = false;
+
+	if (node->type != CMARK_NODE_LINK) {
+		return NO_LINK;
+	}
+
+	const char* url = cmark_node_get_url(node);
+	cmark_chunk url_chunk = cmark_chunk_literal(url);
+
+	url_len = safe_strlen(url);
+	if (url_len == 0 || scan_scheme(&url_chunk, 0) == 0) {
+		return NO_LINK;
+	}
+
+	const char* title = cmark_node_get_title(node);
+	title_len = safe_strlen(title);
+	// if it has a title, we can't treat it as an autolink:
+	if (title_len > 0) {
+		return NORMAL_LINK;
+	}
+
+	link_text = node->first_child;
+	cmark_consolidate_text_nodes(link_text);
+	realurl = (char*)url;
+	realurllen = url_len;
+	if (strncmp(realurl, "mailto:", 7) == 0) {
+		realurl += 7;
+		realurllen -= 7;
+		isemail = true;
+	}
+	if (realurllen == link_text->as.literal.len &&
+	    strncmp(realurl,
+	            (char*)link_text->as.literal.data,
+	            link_text->as.literal.len) == 0) {
+		if (isemail) {
+			return EMAIL_AUTOLINK;
+		} else {
+			return URL_AUTOLINK;
+		}
+	} else {
+		return NORMAL_LINK;
+	}
+}
+
+static int
+S_get_enumlevel(cmark_node *node)
+{
+	int enumlevel = 0;
+	cmark_node *tmp = node;
+	while (tmp) {
+		if (tmp->type == CMARK_NODE_LIST &&
+		    cmark_node_get_list_type(node) == CMARK_ORDERED_LIST) {
+			enumlevel++;
+		}
+		tmp = tmp->parent;
+	}
+	return enumlevel;
+}
+
+static int
+S_render_node(cmark_renderer *renderer,
+              cmark_node *node,
+              cmark_event_type ev_type,
+              int options)
+{
+	int list_number;
+	char list_number_string[20];
+	bool entering = (ev_type == CMARK_EVENT_ENTER);
+	cmark_list_type list_type;
+	const char* roman_numerals[] = { "", "i", "ii", "iii", "iv", "v",
+	                                 "vi", "vii", "viii", "ix", "x"
+	                               };
+
+	// avoid warning about unused parameter:
+	(void)(options);
+
+	switch (node->type) {
+	case CMARK_NODE_DOCUMENT:
+		break;
+
+	case CMARK_NODE_BLOCK_QUOTE:
+		if (entering) {
+			LIT("\\begin{quote}");
+			CR();
+		} else {
+			LIT("\\end{quote}");
+			BLANKLINE();
+		}
+		break;
+
+	case CMARK_NODE_LIST:
+		list_type = cmark_node_get_list_type(node);
+		if (entering) {
+			LIT("\\begin{");
+			LIT(list_type == CMARK_ORDERED_LIST ?
+			    "enumerate" : "itemize");
+			LIT("}");
+			CR();
+			list_number = cmark_node_get_list_start(node);
+			if (list_number > 1) {
+				sprintf(list_number_string,
+				        "%d", list_number);
+				LIT("\\setcounter{enum");
+				LIT((char *)roman_numerals[S_get_enumlevel(node)]);
+				LIT("}{");
+				OUT(list_number_string, false, NORMAL);
+				LIT("}");
+				CR();
+			}
+		} else {
+			LIT("\\end{");
+			LIT(list_type == CMARK_ORDERED_LIST ?
+			    "enumerate" : "itemize");
+			LIT("}");
+			BLANKLINE();
+		}
+		break;
+
+	case CMARK_NODE_ITEM:
+		if (entering) {
+			LIT("\\item ");
+		} else {
+			CR();
+		}
+		break;
+
+	case CMARK_NODE_HEADER:
+		if (entering) {
+			switch (cmark_node_get_header_level(node)) {
+			case 1:
+				LIT("\\section");
+				break;
+			case 2:
+				LIT("\\subsection");
+				break;
+			case 3:
+				LIT("\\subsubsection");
+				break;
+			case 4:
+				LIT("\\paragraph");
+				break;
+			case 5:
+				LIT("\\subparagraph");
+				break;
+			}
+			LIT("{");
+		} else {
+			LIT("}");
+			BLANKLINE();
+		}
+		break;
+
+	case CMARK_NODE_CODE_BLOCK:
+		CR();
+		LIT("\\begin{verbatim}");
+		CR();
+		OUT(cmark_node_get_literal(node), false, LITERAL);
+		CR();
+		LIT("\\end{verbatim}");
+		BLANKLINE();
+		break;
+
+	case CMARK_NODE_HTML:
+		break;
+
+	case CMARK_NODE_HRULE:
+		BLANKLINE();
+		LIT("\\begin{center}\\rule{0.5\\linewidth}{\\linethickness}\\end{center}");
+		BLANKLINE();
+		break;
+
+	case CMARK_NODE_PARAGRAPH:
+		if (!entering) {
+			BLANKLINE();
+		}
+		break;
+
+	case CMARK_NODE_TEXT:
+		OUT(cmark_node_get_literal(node), true, NORMAL);
+		break;
+
+	case CMARK_NODE_LINEBREAK:
+		LIT("\\\\");
+		CR();
+		break;
+
+	case CMARK_NODE_SOFTBREAK:
+		if (renderer->width == 0) {
+			CR();
+		} else {
+			OUT(" ", true, NORMAL);
+		}
+		break;
+
+	case CMARK_NODE_CODE:
+		LIT("\\texttt{");
+		OUT(cmark_node_get_literal(node), false, NORMAL);
+		LIT("}");
+		break;
+
+	case CMARK_NODE_INLINE_HTML:
+		break;
+
+	case CMARK_NODE_STRONG:
+		if (entering) {
+			LIT("\\textbf{");
+		} else {
+			LIT("}");
+		}
+		break;
+
+	case CMARK_NODE_EMPH:
+		if (entering) {
+			LIT("\\emph{");
+		} else {
+			LIT("}");
+		}
+		break;
+
+	case CMARK_NODE_LINK:
+		if (entering) {
+			const char* url = cmark_node_get_url(node);
+			// requires \usepackage{hyperref}
+			switch(get_link_type(node)) {
+			case URL_AUTOLINK:
+				LIT("\\url{");
+				OUT(url, false, URL);
+				break;
+			case EMAIL_AUTOLINK:
+				LIT("\\href{");
+				OUT(url, false, URL);
+				LIT("}\\nolinkurl{");
+				break;
+			case NORMAL_LINK:
+				LIT("\\href{");
+				OUT(url, false, URL);
+				LIT("}{");
+				break;
+			case NO_LINK:
+				LIT("{");  // error?
+			}
+		} else {
+			LIT("}");
+		}
+
+		break;
+
+	case CMARK_NODE_IMAGE:
+		if (entering) {
+			LIT("\\protect\\includegraphics{");
+			// requires \include{graphicx}
+			OUT(cmark_node_get_url(node), false, URL);
+			LIT("}");
+			return 0;
+		}
+		break;
+
+	default:
+		assert(false);
+		break;
+	}
+
+	return 1;
+}
+
+char *cmark_render_latex(cmark_node *root, int options, int width)
+{
+	return cmark_render(root, options, width, outc, S_render_node);
+}

http://git-wip-us.apache.org/repos/asf/lucy-clownfish/blob/89c7b809/compiler/modules/CommonMark/src/libcmark.pc.in
----------------------------------------------------------------------
diff --git a/compiler/modules/CommonMark/src/libcmark.pc.in b/compiler/modules/CommonMark/src/libcmark.pc.in
deleted file mode 100644
index 9c3a9a9..0000000
--- a/compiler/modules/CommonMark/src/libcmark.pc.in
+++ /dev/null
@@ -1,10 +0,0 @@
-prefix=@CMAKE_INSTALL_PREFIX@
-exec_prefix=@CMAKE_INSTALL_PREFIX@
-libdir=@CMAKE_INSTALL_PREFIX@/lib
-includedir=@CMAKE_INSTALL_PREFIX@/include
-
-Name: libcmark
-Description: CommonMark parsing, rendering, and manipulation
-Version: @PROJECT_VERSION@
-Libs: -L${libdir} -lcmark
-Cflags: -I${includedir}

http://git-wip-us.apache.org/repos/asf/lucy-clownfish/blob/89c7b809/compiler/modules/CommonMark/src/man.c
----------------------------------------------------------------------
diff --git a/compiler/modules/CommonMark/src/man.c b/compiler/modules/CommonMark/src/man.c
index 2c8a3a5..6ff33f5 100644
--- a/compiler/modules/CommonMark/src/man.c
+++ b/compiler/modules/CommonMark/src/man.c
@@ -7,72 +7,84 @@
 #include "cmark.h"
 #include "node.h"
 #include "buffer.h"
+#include "utf8.h"
+#include "render.h"
 
-// Functions to convert cmark_nodes to groff man strings.
+#define OUT(s, wrap, escaping) renderer->out(renderer, s, wrap, escaping)
+#define LIT(s) renderer->out(renderer, s, false, LITERAL)
+#define CR() renderer->cr(renderer)
+#define BLANKLINE() renderer->blankline(renderer)
 
-static void escape_man(cmark_strbuf *dest, const unsigned char *source, int length)
+// Functions to convert cmark_nodes to groff man strings.
+static
+void S_outc(cmark_renderer *renderer,
+            cmark_escaping escape,
+            int32_t c,
+            unsigned char nextc)
 {
-	int i;
-	unsigned char c;
-
-	for (i = 0; i < length; i++) {
-		c = source[i];
-		if (c == '.' && i == 0) {
-			cmark_strbuf_puts(dest, "\\&.");
-		} else if (c == '\'' && i == 0) {
-			cmark_strbuf_puts(dest, "\\&'");
-		} else if (c == '-') {
-			cmark_strbuf_puts(dest, "\\-");
-		} else if (c == '\\') {
-			cmark_strbuf_puts(dest, "\\e");
+	(void)(nextc);
+
+	if (escape == LITERAL) {
+		cmark_render_code_point(renderer, c);
+		return;
+	}
+
+	switch(c) {
+	case 46:
+		if (renderer->begin_line) {
+			cmark_render_ascii(renderer, "\\&.");
+		} else {
+			cmark_render_code_point(renderer, c);
+		}
+		break;
+	case 39:
+		if (renderer->begin_line) {
+			cmark_render_ascii(renderer, "\\&'");
 		} else {
-			cmark_strbuf_putc(dest, source[i]);
+			cmark_render_code_point(renderer, c);
 		}
+		break;
+	case 45:
+		cmark_render_ascii(renderer, "\\-");
+		break;
+	case 92:
+		cmark_render_ascii(renderer, "\\e");
+		break;
+	case 8216: // left single quote
+		cmark_render_ascii(renderer, "\\[oq]");
+		break;
+	case 8217: // right single quote
+		cmark_render_ascii(renderer, "\\[cq]");
+		break;
+	case 8220: // left double quote
+		cmark_render_ascii(renderer, "\\[lq]");
+		break;
+	case 8221: // right double quote
+		cmark_render_ascii(renderer, "\\[rq]");
+		break;
+	case 8212: // em dash
+		cmark_render_ascii(renderer, "\\[em]");
+		break;
+	case 8211: // en dash
+		cmark_render_ascii(renderer, "\\[en]");
+		break;
+	default:
+		cmark_render_code_point(renderer, c);
 	}
 }
 
-static inline void cr(cmark_strbuf *man)
-{
-	if (man->size && man->ptr[man->size - 1] != '\n')
-		cmark_strbuf_putc(man, '\n');
-}
-
-struct render_state {
-	cmark_strbuf* man;
-	cmark_node *plain;
-};
-
 static int
-S_render_node(cmark_node *node, cmark_event_type ev_type,
-              struct render_state *state)
+S_render_node(cmark_renderer *renderer,
+              cmark_node *node,
+              cmark_event_type ev_type,
+              int options)
 {
 	cmark_node *tmp;
-	cmark_strbuf *man = state->man;
 	int list_number;
 	bool entering = (ev_type == CMARK_EVENT_ENTER);
 
-	if (state->plain == node) { // back at original node
-		state->plain = NULL;
-	}
-
-	if (state->plain != NULL) {
-		switch(node->type) {
-		case CMARK_NODE_TEXT:
-		case CMARK_NODE_CODE:
-			escape_man(man, node->as.literal.data,
-			           node->as.literal.len);
-			break;
-
-		case CMARK_NODE_LINEBREAK:
-		case CMARK_NODE_SOFTBREAK:
-			cmark_strbuf_putc(man, ' ');
-			break;
-
-		default:
-			break;
-		}
-		return 1;
-	}
+	// avoid unused parameter error:
+	(void)(options);
 
 	switch (node->type) {
 	case CMARK_NODE_DOCUMENT:
@@ -80,13 +92,13 @@ S_render_node(cmark_node *node, cmark_event_type ev_type,
 
 	case CMARK_NODE_BLOCK_QUOTE:
 		if (entering) {
-			cr(man);
-			cmark_strbuf_puts(man, ".RS");
-			cr(man);
+			CR();
+			LIT(".RS");
+			CR();
 		} else {
-			cr(man);
-			cmark_strbuf_puts(man, ".RE");
-			cr(man);
+			CR();
+			LIT(".RE");
+			CR();
 		}
 		break;
 
@@ -95,11 +107,11 @@ S_render_node(cmark_node *node, cmark_event_type ev_type,
 
 	case CMARK_NODE_ITEM:
 		if (entering) {
-			cr(man);
-			cmark_strbuf_puts(man, ".IP ");
+			CR();
+			LIT(".IP ");
 			if (cmark_node_get_list_type(node->parent) ==
 			    CMARK_BULLET_LIST) {
-				cmark_strbuf_puts(man, "\\[bu] 2");
+				LIT("\\[bu] 2");
 			} else {
 				list_number = cmark_node_get_list_start(node->parent);
 				tmp = node;
@@ -107,43 +119,45 @@ S_render_node(cmark_node *node, cmark_event_type ev_type,
 					tmp = tmp->prev;
 					list_number += 1;
 				}
-				cmark_strbuf_printf(man, "\"%d.\" 4", list_number);
+				char list_number_s[20];
+				sprintf(list_number_s, "\"%d.\" 4", list_number);
+				LIT(list_number_s);
 			}
-			cr(man);
+			CR();
 		} else {
-			cr(man);
+			CR();
 		}
 		break;
 
 	case CMARK_NODE_HEADER:
 		if (entering) {
-			cr(man);
-			cmark_strbuf_puts(man,
-			                  cmark_node_get_header_level(node) == 1 ?
-			                  ".SH" : ".SS");
-			cr(man);
+			CR();
+			LIT(cmark_node_get_header_level(node) == 1 ?
+			    ".SH" : ".SS");
+			CR();
 		} else {
-			cr(man);
+			CR();
 		}
 		break;
 
 	case CMARK_NODE_CODE_BLOCK:
-		cr(man);
-		cmark_strbuf_puts(man, ".IP\n.nf\n\\f[C]\n");
-		escape_man(man, node->as.code.literal.data,
-		           node->as.code.literal.len);
-		cr(man);
-		cmark_strbuf_puts(man, "\\f[]\n.fi");
-		cr(man);
+		CR();
+		LIT(".IP\n.nf\n\\f[C]\n");
+		OUT(cmark_node_get_literal(node),
+		    false,
+		    NORMAL);
+		CR();
+		LIT("\\f[]\n.fi");
+		CR();
 		break;
 
 	case CMARK_NODE_HTML:
 		break;
 
 	case CMARK_NODE_HRULE:
-		cr(man);
-		cmark_strbuf_puts(man, ".PP\n  *  *  *  *  *");
-		cr(man);
+		CR();
+		LIT(".PP\n  *  *  *  *  *");
+		CR();
 		break;
 
 	case CMARK_NODE_PARAGRAPH:
@@ -154,32 +168,36 @@ S_render_node(cmark_node *node, cmark_event_type ev_type,
 			    node->prev == NULL) {
 				// no blank line or .PP
 			} else {
-				cr(man);
-				cmark_strbuf_puts(man, ".PP\n");
+				CR();
+				LIT(".PP");
+				CR();
 			}
 		} else {
-			cr(man);
+			CR();
 		}
 		break;
 
 	case CMARK_NODE_TEXT:
-		escape_man(man, node->as.literal.data,
-		           node->as.literal.len);
+		OUT(cmark_node_get_literal(node), true, NORMAL);
 		break;
 
 	case CMARK_NODE_LINEBREAK:
-		cmark_strbuf_puts(man, ".PD 0\n.P\n.PD");
-		cr(man);
+		LIT(".PD 0\n.P\n.PD");
+		CR();
 		break;
 
 	case CMARK_NODE_SOFTBREAK:
-		cmark_strbuf_putc(man, '\n');
+		if (renderer->width == 0) {
+			CR();
+		} else {
+			OUT(" ", true, LITERAL);
+		}
 		break;
 
 	case CMARK_NODE_CODE:
-		cmark_strbuf_puts(man, "\\f[C]");
-		escape_man(man, node->as.literal.data, node->as.literal.len);
-		cmark_strbuf_puts(man, "\\f[]");
+		LIT("\\f[C]");
+		OUT(cmark_node_get_literal(node), true, NORMAL);
+		LIT("\\f[]");
 		break;
 
 	case CMARK_NODE_INLINE_HTML:
@@ -187,33 +205,33 @@ S_render_node(cmark_node *node, cmark_event_type ev_type,
 
 	case CMARK_NODE_STRONG:
 		if (entering) {
-			cmark_strbuf_puts(man, "\\f[B]");
+			LIT("\\f[B]");
 		} else {
-			cmark_strbuf_puts(man, "\\f[]");
+			LIT("\\f[]");
 		}
 		break;
 
 	case CMARK_NODE_EMPH:
 		if (entering) {
-			cmark_strbuf_puts(man, "\\f[I]");
+			LIT("\\f[I]");
 		} else {
-			cmark_strbuf_puts(man, "\\f[]");
+			LIT("\\f[]");
 		}
 		break;
 
 	case CMARK_NODE_LINK:
 		if (!entering) {
-			cmark_strbuf_printf(man, " (%s)",
-			                    cmark_node_get_url(node));
+			LIT(" (");
+			OUT(cmark_node_get_url(node), true, URL);
+			LIT(")");
 		}
 		break;
 
 	case CMARK_NODE_IMAGE:
 		if (entering) {
-			cmark_strbuf_puts(man, "[IMAGE: ");
-			state->plain = node;
+			LIT("[IMAGE: ");
 		} else {
-			cmark_strbuf_puts(man, "]");
+			LIT("]");
 		}
 		break;
 
@@ -222,28 +240,10 @@ S_render_node(cmark_node *node, cmark_event_type ev_type,
 		break;
 	}
 
-	// cmark_strbuf_putc(man, 'x');
 	return 1;
 }
 
-char *cmark_render_man(cmark_node *root, long options)
+char *cmark_render_man(cmark_node *root, int options, int width)
 {
-	char *result;
-	cmark_strbuf man = GH_BUF_INIT;
-	struct render_state state = { &man, NULL };
-	cmark_node *cur;
-	cmark_event_type ev_type;
-	cmark_iter *iter = cmark_iter_new(root);
-
-	if (options == 0) options = 0; // avoid warning about unused parameters
-
-	while ((ev_type = cmark_iter_next(iter)) != CMARK_EVENT_DONE) {
-		cur = cmark_iter_get_node(iter);
-		S_render_node(cur, ev_type, &state);
-	}
-	result = (char *)cmark_strbuf_detach(&man);
-
-	cmark_iter_free(iter);
-	cmark_strbuf_free(&man);
-	return result;
+	return cmark_render(root, options, width, S_outc, S_render_node);
 }

http://git-wip-us.apache.org/repos/asf/lucy-clownfish/blob/89c7b809/compiler/modules/CommonMark/src/node.c
----------------------------------------------------------------------
diff --git a/compiler/modules/CommonMark/src/node.c b/compiler/modules/CommonMark/src/node.c
index 3785a27..7b1bb10 100644
--- a/compiler/modules/CommonMark/src/node.c
+++ b/compiler/modules/CommonMark/src/node.c
@@ -7,6 +7,73 @@
 static void
 S_node_unlink(cmark_node *node);
 
+static inline bool
+S_is_block(cmark_node *node)
+{
+	if (node == NULL) {
+		return false;
+	}
+	return node->type >= CMARK_NODE_FIRST_BLOCK
+	       && node->type <= CMARK_NODE_LAST_BLOCK;
+}
+
+static inline bool
+S_is_inline(cmark_node *node)
+{
+	if (node == NULL) {
+		return false;
+	}
+	return node->type >= CMARK_NODE_FIRST_INLINE
+	       && node->type <= CMARK_NODE_LAST_INLINE;
+}
+
+static bool
+S_can_contain(cmark_node *node, cmark_node *child)
+{
+	cmark_node *cur;
+
+	if (node == NULL || child == NULL) {
+		return false;
+	}
+
+	// Verify that child is not an ancestor of node or equal to node.
+	cur = node;
+	do {
+		if (cur == child) {
+			return false;
+		}
+		cur = cur->parent;
+	} while (cur != NULL);
+
+	if (child->type == CMARK_NODE_DOCUMENT) {
+		return false;
+	}
+
+	switch (node->type) {
+	case CMARK_NODE_DOCUMENT:
+	case CMARK_NODE_BLOCK_QUOTE:
+	case CMARK_NODE_ITEM:
+		return S_is_block(child)
+		       && child->type != CMARK_NODE_ITEM;
+
+	case CMARK_NODE_LIST:
+		return child->type == CMARK_NODE_ITEM;
+
+	case CMARK_NODE_PARAGRAPH:
+	case CMARK_NODE_HEADER:
+	case CMARK_NODE_EMPH:
+	case CMARK_NODE_STRONG:
+	case CMARK_NODE_LINK:
+	case CMARK_NODE_IMAGE:
+		return S_is_inline(child);
+
+	default:
+		break;
+	}
+
+	return false;
+}
+
 cmark_node*
 cmark_node_new(cmark_node_type type)
 {
@@ -39,7 +106,9 @@ void S_free_nodes(cmark_node *e)
 {
 	cmark_node *next;
 	while (e != NULL) {
-		cmark_strbuf_free(&e->string_content);
+		if (S_is_block(e)) {
+			cmark_strbuf_free(&e->string_content);
+		}
 		switch (e->type) {
 		case NODE_CODE_BLOCK:
 			cmark_chunk_free(&e->as.code.info);
@@ -53,8 +122,8 @@ void S_free_nodes(cmark_node *e)
 			break;
 		case NODE_LINK:
 		case NODE_IMAGE:
-			free(e->as.link.url);
-			free(e->as.link.title);
+			cmark_chunk_free(&e->as.link.url);
+			cmark_chunk_free(&e->as.link.title);
 			break;
 		default:
 			break;
@@ -189,13 +258,24 @@ cmark_node_last_child(cmark_node *node)
 	}
 }
 
-static char*
-S_strdup(const char *str)
+void*
+cmark_node_get_user_data(cmark_node *node)
 {
-	size_t size = strlen(str) + 1;
-	char *dup = (char *)malloc(size);
-	memcpy(dup, str, size);
-	return dup;
+	if (node == NULL) {
+		return NULL;
+	} else {
+		return node->user_data;
+	}
+}
+
+int
+cmark_node_set_user_data(cmark_node *node, void *user_data)
+{
+	if (node == NULL) {
+		return 0;
+	}
+	node->user_data = user_data;
+	return 1;
 }
 
 const char*
@@ -448,7 +528,7 @@ cmark_node_get_url(cmark_node *node)
 	switch (node->type) {
 	case NODE_LINK:
 	case NODE_IMAGE:
-		return (char *)node->as.link.url;
+		return cmark_chunk_to_cstr(&node->as.link.url);
 	default:
 		break;
 	}
@@ -466,8 +546,7 @@ cmark_node_set_url(cmark_node *node, const char *url)
 	switch (node->type) {
 	case NODE_LINK:
 	case NODE_IMAGE:
-		free(node->as.link.url);
-		node->as.link.url = (unsigned char *)S_strdup(url);
+		cmark_chunk_set_cstr(&node->as.link.url, url);
 		return 1;
 	default:
 		break;
@@ -486,7 +565,7 @@ cmark_node_get_title(cmark_node *node)
 	switch (node->type) {
 	case NODE_LINK:
 	case NODE_IMAGE:
-		return (char *)node->as.link.title;
+		return cmark_chunk_to_cstr(&node->as.link.title);
 	default:
 		break;
 	}
@@ -504,8 +583,7 @@ cmark_node_set_title(cmark_node *node, const char *title)
 	switch (node->type) {
 	case NODE_LINK:
 	case NODE_IMAGE:
-		free(node->as.link.title);
-		node->as.link.title = (unsigned char *)S_strdup(title);
+		cmark_chunk_set_cstr(&node->as.link.title, title);
 		return 1;
 	default:
 		break;
@@ -550,73 +628,6 @@ cmark_node_get_end_column(cmark_node *node)
 	return node->end_column;
 }
 
-static inline bool
-S_is_block(cmark_node *node)
-{
-	if (node == NULL) {
-		return false;
-	}
-	return node->type >= CMARK_NODE_FIRST_BLOCK
-	       && node->type <= CMARK_NODE_LAST_BLOCK;
-}
-
-static inline bool
-S_is_inline(cmark_node *node)
-{
-	if (node == NULL) {
-		return false;
-	}
-	return node->type >= CMARK_NODE_FIRST_INLINE
-	       && node->type <= CMARK_NODE_LAST_INLINE;
-}
-
-static bool
-S_can_contain(cmark_node *node, cmark_node *child)
-{
-	cmark_node *cur;
-
-	if (node == NULL || child == NULL) {
-		return false;
-	}
-
-	// Verify that child is not an ancestor of node or equal to node.
-	cur = node;
-	do {
-		if (cur == child) {
-			return false;
-		}
-		cur = cur->parent;
-	} while (cur != NULL);
-
-	if (child->type == CMARK_NODE_DOCUMENT) {
-		return false;
-	}
-
-	switch (node->type) {
-	case CMARK_NODE_DOCUMENT:
-	case CMARK_NODE_BLOCK_QUOTE:
-	case CMARK_NODE_ITEM:
-		return S_is_block(child)
-		       && child->type != CMARK_NODE_ITEM;
-
-	case CMARK_NODE_LIST:
-		return child->type == CMARK_NODE_ITEM;
-
-	case CMARK_NODE_PARAGRAPH:
-	case CMARK_NODE_HEADER:
-	case CMARK_NODE_EMPH:
-	case CMARK_NODE_STRONG:
-	case CMARK_NODE_LINK:
-	case CMARK_NODE_IMAGE:
-		return S_is_inline(child);
-
-	default:
-		break;
-	}
-
-	return false;
-}
-
 // Unlink a node without adjusting its next, prev, and parent pointers.
 static void
 S_node_unlink(cmark_node *node)

http://git-wip-us.apache.org/repos/asf/lucy-clownfish/blob/89c7b809/compiler/modules/CommonMark/src/node.h
----------------------------------------------------------------------
diff --git a/compiler/modules/CommonMark/src/node.h b/compiler/modules/CommonMark/src/node.h
index c0c43d3..b579408 100644
--- a/compiler/modules/CommonMark/src/node.h
+++ b/compiler/modules/CommonMark/src/node.h
@@ -6,6 +6,7 @@ extern "C" {
 #endif
 
 #include <stdio.h>
+#include <stdint.h>
 
 #include "cmark.h"
 #include "buffer.h"
@@ -22,12 +23,13 @@ typedef struct {
 } cmark_list;
 
 typedef struct {
-	bool              fenced;
-	int               fence_length;
-	int               fence_offset;
-	unsigned char     fence_char;
 	cmark_chunk       info;
 	cmark_chunk       literal;
+	int               fence_length;
+	/* fence_offset must be 0-3, so we can use int8_t */
+	int8_t            fence_offset;
+	unsigned char     fence_char;
+	bool              fenced;
 } cmark_code;
 
 typedef struct {
@@ -36,23 +38,26 @@ typedef struct {
 } cmark_header;
 
 typedef struct {
-	unsigned char *url;
-	unsigned char *title;
+	cmark_chunk url;
+	cmark_chunk title;
 } cmark_link;
 
 struct cmark_node {
-	cmark_node_type type;
-
 	struct cmark_node *next;
 	struct cmark_node *prev;
 	struct cmark_node *parent;
 	struct cmark_node *first_child;
 	struct cmark_node *last_child;
 
+	void *user_data;
+
 	int start_line;
 	int start_column;
 	int end_line;
 	int end_column;
+
+	cmark_node_type type;
+
 	bool open;
 	bool last_line_blank;
 
@@ -64,6 +69,7 @@ struct cmark_node {
 		cmark_code        code;
 		cmark_header      header;
 		cmark_link        link;
+		int               html_block_type;
 	} as;
 };
 

http://git-wip-us.apache.org/repos/asf/lucy-clownfish/blob/89c7b809/compiler/modules/CommonMark/src/parser.h
----------------------------------------------------------------------
diff --git a/compiler/modules/CommonMark/src/parser.h b/compiler/modules/CommonMark/src/parser.h
index 3c8def9..01a7aeb 100644
--- a/compiler/modules/CommonMark/src/parser.h
+++ b/compiler/modules/CommonMark/src/parser.h
@@ -16,9 +16,16 @@ struct cmark_parser {
 	struct cmark_node* root;
 	struct cmark_node* current;
 	int line_number;
+	bufsize_t offset;
+	bufsize_t column;
+	bufsize_t first_nonspace;
+	bufsize_t first_nonspace_column;
+	int indent;
+	bool blank;
 	cmark_strbuf *curline;
-	int last_line_length;
+	bufsize_t last_line_length;
 	cmark_strbuf *linebuf;
+	int options;
 };
 
 #ifdef __cplusplus

http://git-wip-us.apache.org/repos/asf/lucy-clownfish/blob/89c7b809/compiler/modules/CommonMark/src/references.c
----------------------------------------------------------------------
diff --git a/compiler/modules/CommonMark/src/references.c b/compiler/modules/CommonMark/src/references.c
index 37bf4cb..1d3d56d 100644
--- a/compiler/modules/CommonMark/src/references.c
+++ b/compiler/modules/CommonMark/src/references.c
@@ -20,8 +20,8 @@ static void reference_free(cmark_reference *ref)
 {
 	if(ref != NULL) {
 		free(ref->label);
-		free(ref->url);
-		free(ref->title);
+		cmark_chunk_free(&ref->url);
+		cmark_chunk_free(&ref->title);
 		free(ref);
 	}
 }

http://git-wip-us.apache.org/repos/asf/lucy-clownfish/blob/89c7b809/compiler/modules/CommonMark/src/references.h
----------------------------------------------------------------------
diff --git a/compiler/modules/CommonMark/src/references.h b/compiler/modules/CommonMark/src/references.h
index 69325bb..a360cd5 100644
--- a/compiler/modules/CommonMark/src/references.h
+++ b/compiler/modules/CommonMark/src/references.h
@@ -12,8 +12,8 @@ extern "C" {
 struct cmark_reference {
 	struct cmark_reference *next;
 	unsigned char *label;
-	unsigned char *url;
-	unsigned char *title;
+	cmark_chunk url;
+	cmark_chunk title;
 	unsigned int hash;
 };
 

http://git-wip-us.apache.org/repos/asf/lucy-clownfish/blob/89c7b809/compiler/modules/CommonMark/src/render.c
----------------------------------------------------------------------
diff --git a/compiler/modules/CommonMark/src/render.c b/compiler/modules/CommonMark/src/render.c
new file mode 100644
index 0000000..2f1faac
--- /dev/null
+++ b/compiler/modules/CommonMark/src/render.c
@@ -0,0 +1,186 @@
+#include <stdlib.h>
+#include "buffer.h"
+#include "chunk.h"
+#include "cmark.h"
+#include "utf8.h"
+#include "render.h"
+
+static inline
+void S_cr(cmark_renderer *renderer)
+{
+	if (renderer->need_cr < 1) {
+		renderer->need_cr = 1;
+	}
+}
+
+static inline
+void S_blankline(cmark_renderer *renderer)
+{
+	if (renderer->need_cr < 2) {
+		renderer->need_cr = 2;
+	}
+}
+
+static
+void S_out(cmark_renderer *renderer,
+           const char *source,
+           bool wrap,
+           cmark_escaping escape)
+{
+	int length = cmark_strbuf_safe_strlen(source);
+	unsigned char nextc;
+	int32_t c;
+	int i = 0;
+	int len;
+	cmark_chunk remainder = cmark_chunk_literal("");
+	int k = renderer->buffer->size - 1;
+
+	wrap = wrap && !renderer->no_wrap;
+
+	if (renderer->in_tight_list_item && renderer->need_cr > 1) {
+		renderer->need_cr = 1;
+	}
+	while (renderer->need_cr) {
+		if (k < 0 || renderer->buffer->ptr[k] == '\n') {
+			k -= 1;
+		} else {
+			cmark_strbuf_putc(renderer->buffer, '\n');
+			if (renderer->need_cr > 1) {
+				cmark_strbuf_put(renderer->buffer, renderer->prefix->ptr,
+				                 renderer->prefix->size);
+			}
+		}
+		renderer->column = 0;
+		renderer->begin_line = true;
+		renderer->need_cr -= 1;
+	}
+
+	while (i < length) {
+		if (renderer->begin_line) {
+			cmark_strbuf_put(renderer->buffer, renderer->prefix->ptr,
+			                 renderer->prefix->size);
+			// note: this assumes prefix is ascii:
+			renderer->column = renderer->prefix->size;
+		}
+
+		len = utf8proc_iterate((const uint8_t *)source + i, length - i, &c);
+		if (len == -1) { // error condition
+			return;  // return without rendering rest of string
+		}
+		nextc = source[i + len];
+		if (c == 32 && wrap) {
+			if (!renderer->begin_line) {
+				cmark_strbuf_putc(renderer->buffer, ' ');
+				renderer->column += 1;
+				renderer->begin_line = false;
+				renderer->last_breakable = renderer->buffer->size -
+				                           1;
+				// skip following spaces
+				while (source[i + 1] == ' ') {
+					i++;
+				}
+			}
+
+		} else if (c == 10) {
+			cmark_strbuf_putc(renderer->buffer, '\n');
+			renderer->column = 0;
+			renderer->begin_line = true;
+			renderer->last_breakable = 0;
+		} else if (escape == LITERAL) {
+			cmark_render_code_point(renderer, c);
+			renderer->begin_line = false;
+		} else {
+			(renderer->outc)(renderer, escape, c, nextc);
+			renderer->begin_line = false;
+		}
+
+		// If adding the character went beyond width, look for an
+		// earlier place where the line could be broken:
+		if (renderer->width > 0 &&
+		    renderer->column > renderer->width &&
+		    !renderer->begin_line &&
+		    renderer->last_breakable > 0) {
+
+			// copy from last_breakable to remainder
+			cmark_chunk_set_cstr(&remainder, (char *) renderer->buffer->ptr + renderer->last_breakable + 1);
+			// truncate at last_breakable
+			cmark_strbuf_truncate(renderer->buffer, renderer->last_breakable);
+			// add newline, prefix, and remainder
+			cmark_strbuf_putc(renderer->buffer, '\n');
+			cmark_strbuf_put(renderer->buffer, renderer->prefix->ptr,
+			                 renderer->prefix->size);
+			cmark_strbuf_put(renderer->buffer, remainder.data, remainder.len);
+			renderer->column = renderer->prefix->size + remainder.len;
+			cmark_chunk_free(&remainder);
+			renderer->last_breakable = 0;
+			renderer->begin_line = false;
+		}
+
+		i += len;
+	}
+}
+
+// Assumes no newlines, assumes ascii content:
+void
+cmark_render_ascii(cmark_renderer* renderer, const char* s)
+{
+	int origsize = renderer->buffer->size;
+	cmark_strbuf_puts(renderer->buffer, s);
+	renderer->column += renderer->buffer->size - origsize;
+}
+
+void
+cmark_render_code_point(cmark_renderer *renderer, uint32_t c)
+{
+	utf8proc_encode_char(c, renderer->buffer);
+	renderer->column += 1;
+}
+
+char*
+cmark_render(cmark_node *root,
+             int options,
+             int width,
+             void (*outc)(cmark_renderer*,
+                          cmark_escaping,
+                          int32_t,
+                          unsigned char),
+             int (*render_node)(cmark_renderer *renderer,
+                                cmark_node *node,
+                                cmark_event_type ev_type,
+                                int options))
+{
+	cmark_strbuf pref = GH_BUF_INIT;
+	cmark_strbuf buf = GH_BUF_INIT;
+	cmark_node *cur;
+	cmark_event_type ev_type;
+	char *result;
+	cmark_iter *iter = cmark_iter_new(root);
+
+	cmark_renderer renderer = { &buf, &pref, 0, width,
+	                            0, 0, true, false, false,
+	                            outc, S_cr, S_blankline, S_out
+	                          };
+
+	while ((ev_type = cmark_iter_next(iter)) != CMARK_EVENT_DONE) {
+		cur = cmark_iter_get_node(iter);
+		if (!render_node(&renderer, cur, ev_type, options)) {
+			// a false value causes us to skip processing
+			// the node's contents.  this is used for
+			// autolinks.
+			cmark_iter_reset(iter, cur, CMARK_EVENT_EXIT);
+		}
+	}
+
+	// ensure final newline
+	if (renderer.buffer->ptr[renderer.buffer->size - 1] != '\n') {
+		cmark_strbuf_putc(renderer.buffer, '\n');
+	}
+
+	result = (char *)cmark_strbuf_detach(renderer.buffer);
+
+	cmark_iter_free(iter);
+	cmark_strbuf_free(renderer.prefix);
+	cmark_strbuf_free(renderer.buffer);
+
+	return result;
+}

http://git-wip-us.apache.org/repos/asf/lucy-clownfish/blob/89c7b809/compiler/modules/CommonMark/src/render.h
----------------------------------------------------------------------
diff --git a/compiler/modules/CommonMark/src/render.h b/compiler/modules/CommonMark/src/render.h
new file mode 100644
index 0000000..ca541bc
--- /dev/null
+++ b/compiler/modules/CommonMark/src/render.h
@@ -0,0 +1,66 @@
+#ifndef CMARK_RENDER_H
+#define CMARK_RENDER_H
+
+#ifdef __cplusplus
+extern "C" {
+#endif
+
+#include <stdlib.h>
+#include "buffer.h"
+#include "chunk.h"
+
+typedef enum  {
+	LITERAL,
+	NORMAL,
+	TITLE,
+	URL
+} cmark_escaping;
+
+struct cmark_renderer {
+	cmark_strbuf* buffer;
+	cmark_strbuf* prefix;
+	int column;
+	int width;
+	int need_cr;
+	bufsize_t last_breakable;
+	bool begin_line;
+	bool no_wrap;
+	bool in_tight_list_item;
+	void (*outc)(struct cmark_renderer*,
+		     cmark_escaping,
+		     int32_t,
+		     unsigned char);
+	void (*cr)(struct cmark_renderer*);
+	void (*blankline)(struct cmark_renderer*);
+	void (*out)(struct cmark_renderer*,
+		    const char *,
+		    bool,
+		    cmark_escaping);
+};
+
+typedef struct cmark_renderer cmark_renderer;
+
+void
+cmark_render_ascii(cmark_renderer *renderer, const char* s);
+
+void
+cmark_render_code_point(cmark_renderer *renderer, uint32_t c);
+
+char*
+cmark_render(cmark_node *root,
+	     int options,
+	     int width,
+	     void (*outc)(cmark_renderer*,
+			  cmark_escaping,
+			  int32_t,
+			  unsigned char),
+	     int (*render_node)(cmark_renderer *renderer,
+				cmark_node *node,
+				cmark_event_type ev_type,
+				int options));
+
+#ifdef __cplusplus
+}
+#endif
+
+#endif


[19/20] lucy-clownfish git commit: Warn about non-public resources in Clownfish URIs

Posted by nw...@apache.org.
Warn about non-public resources in Clownfish URIs


Project: http://git-wip-us.apache.org/repos/asf/lucy-clownfish/repo
Commit: http://git-wip-us.apache.org/repos/asf/lucy-clownfish/commit/04a18321
Tree: http://git-wip-us.apache.org/repos/asf/lucy-clownfish/tree/04a18321
Diff: http://git-wip-us.apache.org/repos/asf/lucy-clownfish/diff/04a18321

Branch: refs/heads/master
Commit: 04a18321eee563d6dcb85b0fe6300a5054a74675
Parents: 1a6ff50
Author: Nick Wellnhofer <we...@aevum.de>
Authored: Sun Jul 26 23:13:14 2015 +0200
Committer: Nick Wellnhofer <we...@aevum.de>
Committed: Thu Aug 6 18:19:19 2015 +0200

----------------------------------------------------------------------
 compiler/src/CFCCHtml.c | 41 ++++++++++++++++++++---------------------
 compiler/src/CFCUri.c   | 23 +++++++++++++++++++++--
 2 files changed, 41 insertions(+), 23 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/lucy-clownfish/blob/04a18321/compiler/src/CFCCHtml.c
----------------------------------------------------------------------
diff --git a/compiler/src/CFCCHtml.c b/compiler/src/CFCCHtml.c
index c51da80..e36cb10 100644
--- a/compiler/src/CFCCHtml.c
+++ b/compiler/src/CFCCHtml.c
@@ -174,9 +174,6 @@ static char*
 S_cfc_uri_to_url(CFCUri *uri_obj, CFCClass *base, int dir_level);
 
 static char*
-S_struct_sym_to_url(const char *struct_sym, CFCClass *base, int dir_level);
-
-static char*
 S_class_to_url(CFCClass *klass, CFCClass *base, int dir_level);
 
 static char*
@@ -1058,26 +1055,40 @@ S_transform_link(cmark_node *link, CFCClass *doc_class, int dir_level) {
 }
 
 static char*
-S_type_to_html(CFCClass *klass, CFCType *type) {
+S_type_to_html(CFCClass *doc_class, CFCType *type) {
     const char *type_c = CFCType_to_c(type);
 
     if (CFCType_is_object(type)) {
-        const char *struct_sym = CFCClass_full_struct_sym(klass);
-        const char *specifier  = CFCType_get_specifier(type);
         const char *underscore = strchr(type_c, '_');
 
         if (underscore) {
+            const char *doc_struct_sym = CFCClass_full_struct_sym(doc_class);
+            const char *specifier      = CFCType_get_specifier(type);
+            CFCClass *klass = NULL;
+
+            // Don't link to doc class.
+            if (strcmp(specifier, doc_struct_sym) != 0) {
+                klass = CFCClass_fetch_by_struct_sym(specifier);
+                if (!klass) {
+                    CFCUtil_warn("Class '%s' not found", specifier);
+                }
+                else if (!CFCClass_public(klass)) {
+                    CFCUtil_warn("Non-public class '%s' used in public method",
+                                 specifier);
+                    klass = NULL;
+                }
+            }
+
             size_t  offset = underscore + 1 - type_c;
             char   *prefix = CFCUtil_strndup(specifier, offset);
             char   *retval;
 
-            if (strcmp(specifier, struct_sym) == 0) {
-                // Don't link types of the same class.
+            if (!klass) {
                 retval = CFCUtil_sprintf("<span class=\"prefix\">%s</span>%s",
                                          prefix, type_c + offset);
             }
             else {
-                char *url = S_struct_sym_to_url(specifier, klass, 0);
+                char *url = S_class_to_url(klass, doc_class, 0);
                 const char *pattern =
                     "<span class=\"prefix\">%s</span>"
                     "<a href=\"%s\">%s</a>";
@@ -1130,21 +1141,9 @@ S_cfc_uri_to_url(CFCUri *uri_obj, CFCClass *doc_class, int dir_level) {
     return url;
 }
 
-// Return a relative URL to the class with full struct sym `struct_sym`.
-static char*
-S_struct_sym_to_url(const char *struct_sym, CFCClass *base, int dir_level) {
-    if (!struct_sym) { return CFCUtil_strdup("not_found.html"); }
-
-    CFCClass *klass = CFCClass_fetch_by_struct_sym(struct_sym);
-
-    return S_class_to_url(klass, base, dir_level);
-}
-
 // Return a relative URL to a class.
 static char*
 S_class_to_url(CFCClass *klass, CFCClass *base, int dir_level) {
-    if (!klass) { return CFCUtil_strdup("not_found.html"); }
-
     const char *class_name = CFCClass_get_name(klass);
     char *path    = CFCUtil_global_replace(class_name, "::", CHY_DIR_SEP);
     char *url     = CFCUtil_sprintf("%s.html", path);

http://git-wip-us.apache.org/repos/asf/lucy-clownfish/blob/04a18321/compiler/src/CFCUri.c
----------------------------------------------------------------------
diff --git a/compiler/src/CFCUri.c b/compiler/src/CFCUri.c
index 2a7cd5d..7ac8a7e 100644
--- a/compiler/src/CFCUri.c
+++ b/compiler/src/CFCUri.c
@@ -23,6 +23,8 @@
 #include "CFCUri.h"
 #include "CFCClass.h"
 #include "CFCDocument.h"
+#include "CFCFunction.h"
+#include "CFCMethod.h"
 #include "CFCUtil.h"
 
 struct CFCUri {
@@ -167,25 +169,42 @@ S_resolve(CFCUri *self, const char *parcel, const char *struct_sym,
     }
 
     if (klass) {
+        if (!CFCClass_public(klass)) {
+            CFCUtil_warn("Non-public class '%s' in Clownfish URI: %s",
+                          CFCClass_get_struct_sym(klass), self->string);
+        }
+
         self->type  = CFC_URI_CLASS;
         self->klass = klass;
         CFCBase_incref((CFCBase*)klass);
 
         if (callable) {
             if (islower(callable[0])) {
-                if (!CFCClass_function(klass, callable)) {
+                CFCFunction *function = CFCClass_function(klass, callable);
+
+                if (!function) {
                     CFCUtil_warn("Unknown function '%s' in Clownfish URI: %s",
                                  callable, self->string);
                 }
+                else if (!CFCFunction_public(function)) {
+                    CFCUtil_warn("Non-public function '%s' in Clownfish URI:"
+                                 " %s", callable, self->string);
+                }
 
                 self->type     = CFC_URI_FUNCTION;
                 self->callable = CFCUtil_strdup(callable);
             }
             else {
-                if (!CFCClass_method(klass, callable)) {
+                CFCMethod *method = CFCClass_method(klass, callable);
+
+                if (!method) {
                     CFCUtil_warn("Unknown method '%s' in Clownfish URI: %s",
                                  callable, self->string);
                 }
+                else if (!CFCMethod_public(method)) {
+                    CFCUtil_warn("Non-public method '%s' in Clownfish URI:"
+                                 " %s", callable, self->string);
+                }
 
                 self->type     = CFC_URI_METHOD;
                 self->callable = CFCUtil_strdup(callable);


[20/20] lucy-clownfish git commit: Allow Clownfish URIs without "cfish:" scheme

Posted by nw...@apache.org.
Allow Clownfish URIs without "cfish:" scheme


Project: http://git-wip-us.apache.org/repos/asf/lucy-clownfish/repo
Commit: http://git-wip-us.apache.org/repos/asf/lucy-clownfish/commit/c0f9515f
Tree: http://git-wip-us.apache.org/repos/asf/lucy-clownfish/tree/c0f9515f
Diff: http://git-wip-us.apache.org/repos/asf/lucy-clownfish/diff/c0f9515f

Branch: refs/heads/master
Commit: c0f9515f9ab91c8ad0ccd558e549e0e7841538f1
Parents: 520a87e
Author: Nick Wellnhofer <we...@aevum.de>
Authored: Sun Jul 26 19:58:32 2015 +0200
Committer: Nick Wellnhofer <we...@aevum.de>
Committed: Thu Aug 6 18:19:19 2015 +0200

----------------------------------------------------------------------
 compiler/src/CFCBindCore.c         |  2 +-
 compiler/src/CFCUri.c              | 12 ++++++------
 runtime/core/Clownfish/CharBuf.cfh |  4 ++--
 runtime/core/Clownfish/Class.cfh   |  2 +-
 4 files changed, 10 insertions(+), 10 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/lucy-clownfish/blob/c0f9515f/compiler/src/CFCBindCore.c
----------------------------------------------------------------------
diff --git a/compiler/src/CFCBindCore.c b/compiler/src/CFCBindCore.c
index 5c8eae2..e5b23ce 100644
--- a/compiler/src/CFCBindCore.c
+++ b/compiler/src/CFCBindCore.c
@@ -239,7 +239,7 @@ S_write_parcel_h(CFCBindCore *self, CFCParcel *parcel) {
         "(*cfish_destroy_t)(void *vself);\n"
         "extern CFISH_VISIBLE uint32_t CFISH_Obj_Destroy_OFFSET;\n"
         "\n"
-        "/** Invoke the [](cfish:.Destroy) method found in `klass` on\n"
+        "/** Invoke the [](.Destroy) method found in `klass` on\n"
         " * `self`.\n"
         " *\n"
         " * TODO: Eliminate this function if we can arrive at a proper SUPER syntax.\n"

http://git-wip-us.apache.org/repos/asf/lucy-clownfish/blob/c0f9515f/compiler/src/CFCUri.c
----------------------------------------------------------------------
diff --git a/compiler/src/CFCUri.c b/compiler/src/CFCUri.c
index 8c7c555..2a7cd5d 100644
--- a/compiler/src/CFCUri.c
+++ b/compiler/src/CFCUri.c
@@ -57,7 +57,7 @@ S_next_component(char **iter);
 
 int
 CFCUri_is_clownfish_uri(const char *uri) {
-    return strncmp(uri, "cfish:", 6) == 0;
+    return strncmp(uri, "cfish:", 6) == 0 || !strchr(uri, ':');
 }
 
 CFCUri*
@@ -70,10 +70,6 @@ CFCUri*
 CFCUri_init(CFCUri *self, const char *uri, CFCClass *doc_class) {
     CFCUTIL_NULL_CHECK(uri);
 
-    if (strncmp(uri, "cfish:", 6) != 0) {
-        CFCUtil_die("Invalid clownfish URI: %s", uri);
-    }
-
     self->string    = CFCUtil_strdup(uri);
     self->doc_class = (CFCClass*)CFCBase_incref((CFCBase*)doc_class);
 
@@ -93,7 +89,11 @@ CFCUri_destroy(CFCUri *self) {
 
 static void
 S_parse(CFCUri *self) {
-    const char *uri_part = self->string + sizeof("cfish:") - 1;
+    const char *uri_part = self->string;
+
+    if (strncmp(uri_part, "cfish:", 6) == 0) {
+        uri_part += 6;
+    }
 
     if (strcmp(uri_part, "@null") == 0) {
         self->type = CFC_URI_NULL;

http://git-wip-us.apache.org/repos/asf/lucy-clownfish/blob/c0f9515f/runtime/core/Clownfish/CharBuf.cfh
----------------------------------------------------------------------
diff --git a/runtime/core/Clownfish/CharBuf.cfh b/runtime/core/Clownfish/CharBuf.cfh
index 6e7cc56..788c0d4 100644
--- a/runtime/core/Clownfish/CharBuf.cfh
+++ b/runtime/core/Clownfish/CharBuf.cfh
@@ -92,7 +92,7 @@ final class Clownfish::CharBuf nickname CB
      * hex:      %x32
      *
      * Note that all Clownfish Objects, including CharBufs, are printed via
-     * %o (which invokes [](cfish:Obj.To_String)).
+     * %o (which invokes [](Obj.To_String)).
      */
     void
     VCatF(CharBuf *self, const char *pattern, va_list args);
@@ -143,7 +143,7 @@ final class Clownfish::CharBuf nickname CB
     To_String(CharBuf *self);
 
     /** Return the content of the CharBuf as String and clear the CharBuf.
-     * This is more efficient than [](cfish:.To_String).
+     * This is more efficient than [](.To_String).
      */
     public incremented String*
     Yield_String(CharBuf *self);

http://git-wip-us.apache.org/repos/asf/lucy-clownfish/blob/c0f9515f/runtime/core/Clownfish/Class.cfh
----------------------------------------------------------------------
diff --git a/runtime/core/Clownfish/Class.cfh b/runtime/core/Clownfish/Class.cfh
index c32d316..ab08415 100644
--- a/runtime/core/Clownfish/Class.cfh
+++ b/runtime/core/Clownfish/Class.cfh
@@ -48,7 +48,7 @@ final class Clownfish::Class inherits Clownfish::Obj {
      * will be created using [parent] as a base.
      *
      * If [parent] is NULL, an attempt will be made to find it using
-     * [](cfish:.find_parent_class).  If the attempt fails, an error will
+     * [](.find_parent_class).  If the attempt fails, an error will
      * result.
      */
     inert Class*


[03/20] lucy-clownfish git commit: Ignore code blocks of other host languages

Posted by nw...@apache.org.
Ignore code blocks of other host languages


Project: http://git-wip-us.apache.org/repos/asf/lucy-clownfish/repo
Commit: http://git-wip-us.apache.org/repos/asf/lucy-clownfish/commit/7973bf5b
Tree: http://git-wip-us.apache.org/repos/asf/lucy-clownfish/tree/7973bf5b
Diff: http://git-wip-us.apache.org/repos/asf/lucy-clownfish/diff/7973bf5b

Branch: refs/heads/master
Commit: 7973bf5b99e0128520ae32a2c5680bf37912652f
Parents: d11a489
Author: Nick Wellnhofer <we...@aevum.de>
Authored: Sun Jul 26 03:04:25 2015 +0200
Committer: Nick Wellnhofer <we...@aevum.de>
Committed: Thu Aug 6 18:19:19 2015 +0200

----------------------------------------------------------------------
 compiler/src/CFCCHtml.c       | 60 ++++++++++++++++++++++++++++++++------
 compiler/src/CFCCMan.c        | 60 +++++++++++++++++++++++++++++---------
 compiler/src/CFCDocuComment.c | 15 ++++++++++
 compiler/src/CFCDocuComment.h |  9 ++++++
 compiler/src/CFCPerlPod.c     | 42 +++++++++++++++++++-------
 5 files changed, 152 insertions(+), 34 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/lucy-clownfish/blob/7973bf5b/compiler/src/CFCCHtml.c
----------------------------------------------------------------------
diff --git a/compiler/src/CFCCHtml.c b/compiler/src/CFCCHtml.c
index 3c953fe..aa240b0 100644
--- a/compiler/src/CFCCHtml.c
+++ b/compiler/src/CFCCHtml.c
@@ -159,10 +159,13 @@ static char*
 S_md_to_html(const char *md, CFCClass *klass, int dir_level);
 
 static void
-S_convert_uris(cmark_node *node, CFCClass *klass, int dir_level);
+S_transform_doc(cmark_node *node, CFCClass *klass, int dir_level);
+
+static int
+S_transform_code_block(cmark_node *node, int found_matching_code_block);
 
 static void
-S_convert_uri(cmark_node *link, CFCClass *klass, int dir_level);
+S_transform_link(cmark_node *link, CFCClass *klass, int dir_level);
 
 static char*
 S_type_to_html(CFCClass *klass, CFCType *type);
@@ -939,7 +942,7 @@ S_md_to_html(const char *md, CFCClass *klass, int dir_level) {
                   | CMARK_OPT_VALIDATE_UTF8
                   | CMARK_OPT_SAFE;
     cmark_node *doc = cmark_parse_document(md, strlen(md), options);
-    S_convert_uris(doc, klass, dir_level);
+    S_transform_doc(doc, klass, dir_level);
     char *html = cmark_render_html(doc, CMARK_OPT_DEFAULT);
     cmark_node_free(doc);
 
@@ -947,25 +950,64 @@ S_md_to_html(const char *md, CFCClass *klass, int dir_level) {
 }
 
 static void
-S_convert_uris(cmark_node *node, CFCClass *klass, int dir_level) {
+S_transform_doc(cmark_node *node, CFCClass *klass, int dir_level) {
+    int found_matching_code_block = false;
     cmark_iter *iter = cmark_iter_new(node);
     cmark_event_type ev_type;
 
     while (CMARK_EVENT_DONE != (ev_type = cmark_iter_next(iter))) {
         cmark_node *cur = cmark_iter_get_node(iter);
+        cmark_node_type type = cmark_node_get_type(cur);
+
+        switch (type) {
+            case CMARK_NODE_CODE_BLOCK:
+                found_matching_code_block
+                    = S_transform_code_block(cur, found_matching_code_block);
+                break;
+
+            case CMARK_NODE_LINK:
+                if (ev_type == CMARK_EVENT_EXIT) {
+                    S_transform_link(cur, klass, dir_level);
+                }
+                break;
 
-        if (ev_type == CMARK_EVENT_EXIT
-            && cmark_node_get_type(cur) == NODE_LINK
-        ) {
-            S_convert_uri(cur, klass, dir_level);
+            default:
+                break;
         }
     }
 
     cmark_iter_free(iter);
 }
 
+static int
+S_transform_code_block(cmark_node *code_block, int found_matching_code_block) {
+    int is_host = CFCMarkdown_code_block_is_host(code_block, "c");
+
+    if (is_host) {
+        found_matching_code_block = true;
+    }
+
+    if (CFCMarkdown_code_block_is_last(code_block)) {
+        if (!found_matching_code_block) {
+            cmark_node *warning
+                = cmark_node_new(CMARK_NODE_CODE_BLOCK);
+            cmark_node_set_literal(warning,
+                                   "Code example for C is missing");
+            cmark_node_insert_after(code_block, warning);
+        }
+        else {
+            // Reset.
+            found_matching_code_block = false;
+        }
+    }
+
+    if (!is_host) { cmark_node_free(code_block); }
+
+    return found_matching_code_block;
+}
+
 static void
-S_convert_uri(cmark_node *link, CFCClass *klass, int dir_level) {
+S_transform_link(cmark_node *link, CFCClass *klass, int dir_level) {
     const char *uri_string = cmark_node_get_url(link);
     if (!uri_string || !CFCUri_is_clownfish_uri(uri_string)) {
         return;

http://git-wip-us.apache.org/repos/asf/lucy-clownfish/blob/7973bf5b/compiler/src/CFCCMan.c
----------------------------------------------------------------------
diff --git a/compiler/src/CFCCMan.c b/compiler/src/CFCCMan.c
index 79248c8..6089ca3 100644
--- a/compiler/src/CFCCMan.c
+++ b/compiler/src/CFCCMan.c
@@ -427,6 +427,7 @@ S_nodes_to_man(CFCClass *klass, cmark_node *node, int needs_indent) {
     int level      = needs_indent ? 1 : 0;
     int has_indent = needs_indent;
     int has_vspace = true;
+    int found_matching_code_block = false;
     cmark_iter *iter = cmark_iter_new(node);
     cmark_event_type ev_type;
 
@@ -497,23 +498,54 @@ S_nodes_to_man(CFCClass *klass, cmark_node *node, int needs_indent) {
                 break;
 
             case CMARK_NODE_CODE_BLOCK: {
-                if (level > 0) {
-                    result = CFCUtil_cat(result, ".RS\n", NULL);
-                }
+                int is_host = CFCMarkdown_code_block_is_host(node, "c");
 
-                const char *content = cmark_node_get_literal(node);
-                char *escaped = S_man_escape(content);
-                result = CFCUtil_cat(result, ".IP\n.nf\n.fam C\n", escaped,
-                                     ".fam\n.fi\n", NULL);
-                FREEMEM(escaped);
+                if (is_host) {
+                    found_matching_code_block = true;
 
-                if (level > 0) {
-                    result = CFCUtil_cat(result, ".RE\n", NULL);
-                    has_indent = false;
+                    if (level > 0) {
+                        result = CFCUtil_cat(result, ".RS\n", NULL);
+                    }
+
+                    const char *content = cmark_node_get_literal(node);
+                    char *escaped = S_man_escape(content);
+                    result = CFCUtil_cat(result, ".IP\n.nf\n.fam C\n", escaped,
+                                         ".fam\n.fi\n", NULL);
+                    FREEMEM(escaped);
+
+                    if (level > 0) {
+                        result = CFCUtil_cat(result, ".RE\n", NULL);
+                        has_indent = false;
+                    }
+                    else {
+                        has_indent = true;
+                        has_vspace = false;
+                    }
                 }
-                else {
-                    has_indent = true;
-                    has_vspace = false;
+
+                if (CFCMarkdown_code_block_is_last(node)) {
+                    if (!found_matching_code_block) {
+                        if (level > 0) {
+                            result = CFCUtil_cat(result, ".RS\n", NULL);
+                        }
+                        result = CFCUtil_cat(result,
+                            ".IP\n.nf\n.fam C\n"
+                            "Code example for Perl is missing\n",
+                            ".fam\n.fi\n",
+                            NULL);
+                        if (level > 0) {
+                            result = CFCUtil_cat(result, ".RE\n", NULL);
+                            has_indent = false;
+                        }
+                        else {
+                            has_indent = true;
+                            has_vspace = false;
+                        }
+                    }
+                    else {
+                        // Reset.
+                        found_matching_code_block = false;
+                    }
                 }
 
                 break;

http://git-wip-us.apache.org/repos/asf/lucy-clownfish/blob/7973bf5b/compiler/src/CFCDocuComment.c
----------------------------------------------------------------------
diff --git a/compiler/src/CFCDocuComment.c b/compiler/src/CFCDocuComment.c
index d88335f..ce59275 100644
--- a/compiler/src/CFCDocuComment.c
+++ b/compiler/src/CFCDocuComment.c
@@ -16,6 +16,7 @@
 
 #include <ctype.h>
 #include <string.h>
+#include <cmark.h>
 
 #define CFC_NEED_BASE_STRUCT_DEF
 #include "CFCBase.h"
@@ -253,3 +254,17 @@ CFCDocuComment_get_retval(CFCDocuComment *self) {
     return self->retval;
 }
 
+int
+CFCMarkdown_code_block_is_host(cmark_node *code_block, const char *lang) {
+    const char *fence_info = cmark_node_get_fence_info(code_block);
+    return !fence_info
+           || fence_info[0] == '\0'
+           || strcmp(fence_info, lang) == 0;
+}
+
+int
+CFCMarkdown_code_block_is_last(cmark_node *code_block) {
+    cmark_node *next = cmark_node_next(code_block);
+    return !next || cmark_node_get_type(next) != CMARK_NODE_CODE_BLOCK;
+}
+

http://git-wip-us.apache.org/repos/asf/lucy-clownfish/blob/7973bf5b/compiler/src/CFCDocuComment.h
----------------------------------------------------------------------
diff --git a/compiler/src/CFCDocuComment.h b/compiler/src/CFCDocuComment.h
index 910f191..8b44c83 100644
--- a/compiler/src/CFCDocuComment.h
+++ b/compiler/src/CFCDocuComment.h
@@ -26,6 +26,8 @@ extern "C" {
 
 typedef struct CFCDocuComment CFCDocuComment;
 
+struct cmark_node;
+
 /** Parse comment text.
  */
 CFCDocuComment*
@@ -53,6 +55,13 @@ CFCDocuComment_get_param_docs(CFCDocuComment *self);
 const char*
 CFCDocuComment_get_retval(CFCDocuComment *self);
 
+int
+CFCMarkdown_code_block_is_host(struct cmark_node *code_block,
+                               const char *lang);
+
+int
+CFCMarkdown_code_block_is_last(struct cmark_node *code_block);
+
 #ifdef __cplusplus
 }
 #endif

http://git-wip-us.apache.org/repos/asf/lucy-clownfish/blob/7973bf5b/compiler/src/CFCPerlPod.c
----------------------------------------------------------------------
diff --git a/compiler/src/CFCPerlPod.c b/compiler/src/CFCPerlPod.c
index 8fc2eae..fa221e4 100644
--- a/compiler/src/CFCPerlPod.c
+++ b/compiler/src/CFCPerlPod.c
@@ -340,6 +340,7 @@ S_nodes_to_pod(cmark_node *node, CFCClass *klass, int header_level) {
         return result;
     }
 
+    int found_matching_code_block = false;
     cmark_iter *iter = cmark_iter_new(node);
     cmark_event_type ev_type;
 
@@ -388,18 +389,37 @@ S_nodes_to_pod(cmark_node *node, CFCClass *klass, int header_level) {
                 break;
 
             case CMARK_NODE_CODE_BLOCK: {
-                const char *content = cmark_node_get_literal(node);
-                char *copy = CFCUtil_strdup(content);
-                // Chomp trailing newline.
-                size_t len = strlen(copy);
-                if (len > 0 && copy[len-1] == '\n') {
-                    copy[len-1] = '\0';
+                int is_host = CFCMarkdown_code_block_is_host(node, "perl");
+
+                if (is_host) {
+                    found_matching_code_block = true;
+
+                    const char *content = cmark_node_get_literal(node);
+                    char *copy = CFCUtil_strdup(content);
+                    // Chomp trailing newline.
+                    size_t len = strlen(copy);
+                    if (len > 0 && copy[len-1] == '\n') {
+                        copy[len-1] = '\0';
+                    }
+                    char *indented
+                        = CFCUtil_global_replace(copy, "\n", "\n    ");
+                    result
+                        = CFCUtil_cat(result, "    ", indented, "\n\n", NULL);
+                    FREEMEM(indented);
+                    FREEMEM(copy);
+                }
+
+                if (CFCMarkdown_code_block_is_last(node)) {
+                    if (!found_matching_code_block) {
+                        result = CFCUtil_cat(result,
+                            "    Code example for Perl is missing\n\n");
+                    }
+                    else {
+                        // Reset.
+                        found_matching_code_block = false;
+                    }
                 }
-                char *indented
-                    = CFCUtil_global_replace(copy, "\n", "\n    ");
-                result = CFCUtil_cat(result, "    ", indented, "\n\n", NULL);
-                FREEMEM(indented);
-                FREEMEM(copy);
+
                 break;
             }
 


[05/20] lucy-clownfish git commit: Upgrade libcmark to 0.21.0

Posted by nw...@apache.org.
http://git-wip-us.apache.org/repos/asf/lucy-clownfish/blob/89c7b809/compiler/modules/CommonMark/src/scanners.c
----------------------------------------------------------------------
diff --git a/compiler/modules/CommonMark/src/scanners.c b/compiler/modules/CommonMark/src/scanners.c
index 21c0744..75fdb46 100644
--- a/compiler/modules/CommonMark/src/scanners.c
+++ b/compiler/modules/CommonMark/src/scanners.c
@@ -1,11 +1,11 @@
-/* Generated by re2c 0.13.6 */
+/* Generated by re2c 0.14.3 */
 #include <stdlib.h>
 #include "chunk.h"
 #include "scanners.h"
 
-int _scan_at(int (*scanner)(const unsigned char *), cmark_chunk *c, int offset)
+bufsize_t _scan_at(bufsize_t (*scanner)(const unsigned char *), cmark_chunk *c, bufsize_t offset)
 {
-	int res;
+	bufsize_t res;
 	unsigned char *ptr = (unsigned char *)c->data;
 	unsigned char lim = ptr[c->len];
 
@@ -18,105 +18,133 @@ int _scan_at(int (*scanner)(const unsigned char *), cmark_chunk *c, int offset)
 
 
 
-// Try to match URI autolink after first <, returning number of chars matched.
-int _scan_autolink_uri(const unsigned char *p)
+// Try to match a scheme including colon.
+bufsize_t _scan_scheme(const unsigned char *p)
 {
   const unsigned char *marker = NULL;
   const unsigned char *start = p;
 
 {
 	unsigned char yych;
-	static const unsigned char yybm[] = {
-		  0,   0,   0,   0,   0,   0,   0,   0, 
-		  0,   0,   0,   0,   0,   0,   0,   0, 
-		  0,   0,   0,   0,   0,   0,   0,   0, 
-		  0,   0,   0,   0,   0,   0,   0,   0, 
-		  0, 128, 128, 128, 128, 128, 128, 128, 
-		128, 128, 128, 128, 128, 128, 128, 128, 
-		128, 128, 128, 128, 128, 128, 128, 128, 
-		128, 128, 128, 128,   0, 128,   0, 128, 
-		128, 128, 128, 128, 128, 128, 128, 128, 
-		128, 128, 128, 128, 128, 128, 128, 128, 
-		128, 128, 128, 128, 128, 128, 128, 128, 
-		128, 128, 128, 128,   0, 128, 128, 128, 
-		128, 128, 128, 128, 128, 128, 128, 128, 
-		128, 128, 128, 128, 128, 128, 128, 128, 
-		128, 128, 128, 128, 128, 128, 128, 128, 
-		128, 128, 128, 128, 128, 128, 128, 128, 
-		128, 128, 128, 128, 128, 128, 128, 128, 
-		128, 128, 128, 128, 128, 128, 128, 128, 
-		128, 128, 128, 128, 128, 128, 128, 128, 
-		128, 128, 128, 128, 128, 128, 128, 128, 
-		128, 128, 128, 128, 128, 128, 128, 128, 
-		128, 128, 128, 128, 128, 128, 128, 128, 
-		128, 128, 128, 128, 128, 128, 128, 128, 
-		128, 128, 128, 128, 128, 128, 128, 128, 
-		128, 128, 128, 128, 128, 128, 128, 128, 
-		128, 128, 128, 128, 128, 128, 128, 128, 
-		128, 128, 128, 128, 128, 128, 128, 128, 
-		128, 128, 128, 128, 128, 128, 128, 128, 
-		128, 128, 128, 128, 128, 128, 128, 128, 
-		128, 128, 128, 128, 128, 128, 128, 128, 
-		128, 128, 128, 128, 128, 128, 128, 128, 
-		128, 128, 128, 128, 128, 128, 128, 128, 
-	};
 
-	yych = *p;
-	switch (yych) {
-	case '\n':	goto yy2;
-	case 'A':
-	case 'a':	goto yy6;
-	case 'B':
-	case 'b':	goto yy24;
-	case 'C':
-	case 'c':	goto yy3;
-	case 'D':
-	case 'd':	goto yy4;
-	case 'E':
-	case 'e':	goto yy25;
-	case 'F':
-	case 'f':	goto yy7;
-	case 'G':
-	case 'g':	goto yy8;
-	case 'H':
-	case 'h':	goto yy9;
-	case 'I':
-	case 'i':	goto yy10;
-	case 'J':
-	case 'j':	goto yy5;
-	case 'K':
-	case 'k':	goto yy26;
-	case 'L':
-	case 'l':	goto yy11;
-	case 'M':
-	case 'm':	goto yy12;
-	case 'N':
-	case 'n':	goto yy13;
-	case 'O':
-	case 'o':	goto yy14;
-	case 'P':
-	case 'p':	goto yy15;
-	case 'Q':
-	case 'q':	goto yy27;
-	case 'R':
-	case 'r':	goto yy16;
-	case 'S':
-	case 's':	goto yy17;
-	case 'T':
-	case 't':	goto yy18;
-	case 'U':
-	case 'u':	goto yy19;
-	case 'V':
-	case 'v':	goto yy20;
-	case 'W':
-	case 'w':	goto yy21;
-	case 'X':
-	case 'x':	goto yy22;
-	case 'Y':
-	case 'y':	goto yy28;
-	case 'Z':
-	case 'z':	goto yy23;
-	default:	goto yy29;
+	yych = *(marker = p);
+	if (yych <= 'c') {
+		if (yych <= 'M') {
+			if (yych <= 'E') {
+				if (yych <= 'A') {
+					if (yych == '\n') goto yy2;
+					if (yych <= '@') goto yy29;
+					goto yy6;
+				} else {
+					if (yych <= 'B') goto yy24;
+					if (yych <= 'C') goto yy3;
+					if (yych <= 'D') goto yy4;
+					goto yy25;
+				}
+			} else {
+				if (yych <= 'I') {
+					if (yych <= 'F') goto yy7;
+					if (yych <= 'G') goto yy8;
+					if (yych <= 'H') goto yy9;
+					goto yy10;
+				} else {
+					if (yych <= 'J') goto yy5;
+					if (yych <= 'K') goto yy26;
+					if (yych <= 'L') goto yy11;
+					goto yy12;
+				}
+			}
+		} else {
+			if (yych <= 'U') {
+				if (yych <= 'Q') {
+					if (yych <= 'N') goto yy13;
+					if (yych <= 'O') goto yy14;
+					if (yych <= 'P') goto yy15;
+					goto yy27;
+				} else {
+					if (yych <= 'R') goto yy16;
+					if (yych <= 'S') goto yy17;
+					if (yych <= 'T') goto yy18;
+					goto yy19;
+				}
+			} else {
+				if (yych <= 'Y') {
+					if (yych <= 'V') goto yy20;
+					if (yych <= 'W') goto yy21;
+					if (yych <= 'X') goto yy22;
+					goto yy28;
+				} else {
+					if (yych <= '`') {
+						if (yych <= 'Z') goto yy23;
+						goto yy29;
+					} else {
+						if (yych <= 'a') goto yy6;
+						if (yych <= 'b') goto yy24;
+						goto yy3;
+					}
+				}
+			}
+		}
+	} else {
+		if (yych <= 't') {
+			if (yych <= 'k') {
+				if (yych <= 'g') {
+					if (yych <= 'd') goto yy4;
+					if (yych <= 'e') goto yy25;
+					if (yych <= 'f') goto yy7;
+					goto yy8;
+				} else {
+					if (yych <= 'h') goto yy9;
+					if (yych <= 'i') goto yy10;
+					if (yych <= 'j') goto yy5;
+					goto yy26;
+				}
+			} else {
+				if (yych <= 'o') {
+					if (yych <= 'l') goto yy11;
+					if (yych <= 'm') goto yy12;
+					if (yych <= 'n') goto yy13;
+					goto yy14;
+				} else {
+					if (yych <= 'q') {
+						if (yych <= 'p') goto yy15;
+						goto yy27;
+					} else {
+						if (yych <= 'r') goto yy16;
+						if (yych <= 's') goto yy17;
+						goto yy18;
+					}
+				}
+			}
+		} else {
+			if (yych <= 0xC1) {
+				if (yych <= 'x') {
+					if (yych <= 'u') goto yy19;
+					if (yych <= 'v') goto yy20;
+					if (yych <= 'w') goto yy21;
+					goto yy22;
+				} else {
+					if (yych <= 'y') goto yy28;
+					if (yych <= 'z') goto yy23;
+					if (yych <= 0x7F) goto yy29;
+				}
+			} else {
+				if (yych <= 0xED) {
+					if (yych <= 0xDF) goto yy30;
+					if (yych <= 0xE0) goto yy32;
+					if (yych <= 0xEC) goto yy33;
+					goto yy37;
+				} else {
+					if (yych <= 0xF0) {
+						if (yych <= 0xEF) goto yy33;
+						goto yy34;
+					} else {
+						if (yych <= 0xF3) goto yy35;
+						if (yych <= 0xF4) goto yy36;
+					}
+				}
+			}
+		}
 	}
 yy2:
 	{ return 0; }
@@ -124,50 +152,50 @@ yy3:
 	yych = *(marker = ++p);
 	switch (yych) {
 	case 'A':
-	case 'a':	goto yy443;
+	case 'a':	goto yy447;
 	case 'H':
-	case 'h':	goto yy442;
+	case 'h':	goto yy446;
 	case 'I':
-	case 'i':	goto yy445;
+	case 'i':	goto yy449;
 	case 'O':
-	case 'o':	goto yy441;
+	case 'o':	goto yy445;
 	case 'R':
-	case 'r':	goto yy444;
+	case 'r':	goto yy448;
 	case 'V':
-	case 'v':	goto yy440;
+	case 'v':	goto yy444;
 	default:	goto yy2;
 	}
 yy4:
 	yych = *(marker = ++p);
 	switch (yych) {
 	case 'A':
-	case 'a':	goto yy416;
+	case 'a':	goto yy420;
 	case 'I':
-	case 'i':	goto yy415;
+	case 'i':	goto yy419;
 	case 'L':
-	case 'l':	goto yy413;
+	case 'l':	goto yy417;
 	case 'N':
-	case 'n':	goto yy414;
+	case 'n':	goto yy418;
 	case 'O':
-	case 'o':	goto yy417;
+	case 'o':	goto yy421;
 	case 'T':
-	case 't':	goto yy412;
+	case 't':	goto yy416;
 	case 'V':
-	case 'v':	goto yy411;
+	case 'v':	goto yy415;
 	default:	goto yy2;
 	}
 yy5:
 	yych = *(marker = ++p);
 	if (yych <= 'M') {
-		if (yych == 'A') goto yy403;
+		if (yych == 'A') goto yy407;
 		if (yych <= 'L') goto yy2;
-		goto yy402;
+		goto yy406;
 	} else {
 		if (yych <= 'a') {
 			if (yych <= '`') goto yy2;
-			goto yy403;
+			goto yy407;
 		} else {
-			if (yych == 'm') goto yy402;
+			if (yych == 'm') goto yy406;
 			goto yy2;
 		}
 	}
@@ -175,48 +203,48 @@ yy6:
 	yych = *(marker = ++p);
 	switch (yych) {
 	case 'A':
-	case 'a':	goto yy384;
+	case 'a':	goto yy388;
 	case 'B':
-	case 'b':	goto yy383;
+	case 'b':	goto yy387;
 	case 'C':
-	case 'c':	goto yy382;
+	case 'c':	goto yy386;
 	case 'D':
-	case 'd':	goto yy381;
+	case 'd':	goto yy385;
 	case 'F':
-	case 'f':	goto yy380;
+	case 'f':	goto yy384;
 	case 'I':
-	case 'i':	goto yy379;
+	case 'i':	goto yy383;
 	case 'P':
-	case 'p':	goto yy378;
+	case 'p':	goto yy382;
 	case 'T':
-	case 't':	goto yy377;
+	case 't':	goto yy381;
 	case 'W':
-	case 'w':	goto yy34;
+	case 'w':	goto yy41;
 	default:	goto yy2;
 	}
 yy7:
 	yych = *(marker = ++p);
 	if (yych <= 'T') {
 		if (yych <= 'E') {
-			if (yych == 'A') goto yy364;
+			if (yych == 'A') goto yy368;
 			if (yych <= 'D') goto yy2;
-			goto yy363;
+			goto yy367;
 		} else {
-			if (yych == 'I') goto yy362;
+			if (yych == 'I') goto yy366;
 			if (yych <= 'S') goto yy2;
-			goto yy365;
+			goto yy369;
 		}
 	} else {
 		if (yych <= 'e') {
-			if (yych == 'a') goto yy364;
+			if (yych == 'a') goto yy368;
 			if (yych <= 'd') goto yy2;
-			goto yy363;
+			goto yy367;
 		} else {
 			if (yych <= 'i') {
 				if (yych <= 'h') goto yy2;
-				goto yy362;
+				goto yy366;
 			} else {
-				if (yych == 't') goto yy365;
+				if (yych == 't') goto yy369;
 				goto yy2;
 			}
 		}
@@ -225,15 +253,15 @@ yy8:
 	yych = *(marker = ++p);
 	switch (yych) {
 	case 'E':
-	case 'e':	goto yy347;
+	case 'e':	goto yy351;
 	case 'G':
-	case 'g':	goto yy34;
+	case 'g':	goto yy41;
 	case 'I':
-	case 'i':	goto yy345;
+	case 'i':	goto yy349;
 	case 'O':
-	case 'o':	goto yy346;
+	case 'o':	goto yy350;
 	case 'T':
-	case 't':	goto yy344;
+	case 't':	goto yy348;
 	default:	goto yy2;
 	}
 yy9:
@@ -241,18 +269,18 @@ yy9:
 	if (yych <= 'S') {
 		if (yych <= '3') {
 			if (yych <= '2') goto yy2;
-			goto yy340;
+			goto yy344;
 		} else {
-			if (yych == 'C') goto yy338;
+			if (yych == 'C') goto yy342;
 			goto yy2;
 		}
 	} else {
 		if (yych <= 'c') {
-			if (yych <= 'T') goto yy339;
+			if (yych <= 'T') goto yy343;
 			if (yych <= 'b') goto yy2;
-			goto yy338;
+			goto yy342;
 		} else {
-			if (yych == 't') goto yy339;
+			if (yych == 't') goto yy343;
 			goto yy2;
 		}
 	}
@@ -260,33 +288,33 @@ yy10:
 	yych = *(marker = ++p);
 	switch (yych) {
 	case 'A':
-	case 'a':	goto yy320;
+	case 'a':	goto yy324;
 	case 'C':
-	case 'c':	goto yy317;
+	case 'c':	goto yy321;
 	case 'M':
-	case 'm':	goto yy319;
+	case 'm':	goto yy323;
 	case 'N':
-	case 'n':	goto yy318;
+	case 'n':	goto yy322;
 	case 'P':
-	case 'p':	goto yy316;
+	case 'p':	goto yy320;
 	case 'R':
-	case 'r':	goto yy315;
+	case 'r':	goto yy319;
 	case 'T':
-	case 't':	goto yy314;
+	case 't':	goto yy318;
 	default:	goto yy2;
 	}
 yy11:
 	yych = *(marker = ++p);
 	if (yych <= 'D') {
-		if (yych == 'A') goto yy308;
+		if (yych == 'A') goto yy312;
 		if (yych <= 'C') goto yy2;
-		goto yy307;
+		goto yy311;
 	} else {
 		if (yych <= 'a') {
 			if (yych <= '`') goto yy2;
-			goto yy308;
+			goto yy312;
 		} else {
-			if (yych == 'd') goto yy307;
+			if (yych == 'd') goto yy311;
 			goto yy2;
 		}
 	}
@@ -294,50 +322,50 @@ yy12:
 	yych = *(marker = ++p);
 	switch (yych) {
 	case 'A':
-	case 'a':	goto yy274;
+	case 'a':	goto yy278;
 	case 'E':
-	case 'e':	goto yy273;
+	case 'e':	goto yy277;
 	case 'I':
-	case 'i':	goto yy276;
+	case 'i':	goto yy280;
 	case 'M':
-	case 'm':	goto yy272;
+	case 'm':	goto yy276;
 	case 'S':
-	case 's':	goto yy271;
+	case 's':	goto yy275;
 	case 'T':
-	case 't':	goto yy275;
+	case 't':	goto yy279;
 	case 'U':
-	case 'u':	goto yy270;
+	case 'u':	goto yy274;
 	case 'V':
-	case 'v':	goto yy269;
+	case 'v':	goto yy273;
 	default:	goto yy2;
 	}
 yy13:
 	yych = *(marker = ++p);
 	switch (yych) {
 	case 'E':
-	case 'e':	goto yy264;
+	case 'e':	goto yy268;
 	case 'F':
-	case 'f':	goto yy263;
+	case 'f':	goto yy267;
 	case 'I':
-	case 'i':	goto yy262;
+	case 'i':	goto yy266;
 	case 'N':
-	case 'n':	goto yy261;
+	case 'n':	goto yy265;
 	case 'O':
-	case 'o':	goto yy260;
+	case 'o':	goto yy264;
 	default:	goto yy2;
 	}
 yy14:
 	yych = *(marker = ++p);
 	if (yych <= 'P') {
-		if (yych == 'I') goto yy246;
+		if (yych == 'I') goto yy250;
 		if (yych <= 'O') goto yy2;
-		goto yy247;
+		goto yy251;
 	} else {
 		if (yych <= 'i') {
 			if (yych <= 'h') goto yy2;
-			goto yy246;
+			goto yy250;
 		} else {
-			if (yych == 'p') goto yy247;
+			if (yych == 'p') goto yy251;
 			goto yy2;
 		}
 	}
@@ -345,35 +373,35 @@ yy15:
 	yych = *(marker = ++p);
 	if (yych <= 'S') {
 		if (yych <= 'L') {
-			if (yych == 'A') goto yy228;
+			if (yych == 'A') goto yy232;
 			if (yych <= 'K') goto yy2;
-			goto yy227;
+			goto yy231;
 		} else {
 			if (yych <= 'O') {
 				if (yych <= 'N') goto yy2;
-				goto yy229;
+				goto yy233;
 			} else {
 				if (yych <= 'Q') goto yy2;
-				if (yych <= 'R') goto yy226;
-				goto yy225;
+				if (yych <= 'R') goto yy230;
+				goto yy229;
 			}
 		}
 	} else {
 		if (yych <= 'n') {
 			if (yych <= 'a') {
 				if (yych <= '`') goto yy2;
-				goto yy228;
+				goto yy232;
 			} else {
-				if (yych == 'l') goto yy227;
+				if (yych == 'l') goto yy231;
 				goto yy2;
 			}
 		} else {
 			if (yych <= 'q') {
-				if (yych <= 'o') goto yy229;
+				if (yych <= 'o') goto yy233;
 				goto yy2;
 			} else {
-				if (yych <= 'r') goto yy226;
-				if (yych <= 's') goto yy225;
+				if (yych <= 'r') goto yy230;
+				if (yych <= 's') goto yy229;
 				goto yy2;
 			}
 		}
@@ -382,23 +410,23 @@ yy16:
 	yych = *(marker = ++p);
 	if (yych <= 'T') {
 		if (yych <= 'L') {
-			if (yych == 'E') goto yy215;
+			if (yych == 'E') goto yy219;
 			goto yy2;
 		} else {
-			if (yych <= 'M') goto yy214;
+			if (yych <= 'M') goto yy218;
 			if (yych <= 'R') goto yy2;
-			if (yych <= 'S') goto yy213;
-			goto yy212;
+			if (yych <= 'S') goto yy217;
+			goto yy216;
 		}
 	} else {
 		if (yych <= 'm') {
-			if (yych == 'e') goto yy215;
+			if (yych == 'e') goto yy219;
 			if (yych <= 'l') goto yy2;
-			goto yy214;
+			goto yy218;
 		} else {
 			if (yych <= 'r') goto yy2;
-			if (yych <= 's') goto yy213;
-			if (yych <= 't') goto yy212;
+			if (yych <= 's') goto yy217;
+			if (yych <= 't') goto yy216;
 			goto yy2;
 		}
 	}
@@ -406,75 +434,75 @@ yy17:
 	yych = *(marker = ++p);
 	switch (yych) {
 	case 'E':
-	case 'e':	goto yy168;
+	case 'e':	goto yy172;
 	case 'F':
-	case 'f':	goto yy167;
+	case 'f':	goto yy171;
 	case 'G':
-	case 'g':	goto yy166;
+	case 'g':	goto yy170;
 	case 'H':
-	case 'h':	goto yy171;
+	case 'h':	goto yy175;
 	case 'I':
-	case 'i':	goto yy170;
+	case 'i':	goto yy174;
 	case 'K':
-	case 'k':	goto yy165;
+	case 'k':	goto yy169;
 	case 'M':
-	case 'm':	goto yy164;
+	case 'm':	goto yy168;
 	case 'N':
-	case 'n':	goto yy169;
+	case 'n':	goto yy173;
 	case 'O':
-	case 'o':	goto yy163;
+	case 'o':	goto yy167;
 	case 'P':
-	case 'p':	goto yy162;
+	case 'p':	goto yy166;
 	case 'S':
-	case 's':	goto yy161;
+	case 's':	goto yy165;
 	case 'T':
-	case 't':	goto yy160;
+	case 't':	goto yy164;
 	case 'V':
-	case 'v':	goto yy159;
+	case 'v':	goto yy163;
 	default:	goto yy2;
 	}
 yy18:
 	yych = *(marker = ++p);
 	switch (yych) {
 	case 'A':
-	case 'a':	goto yy135;
+	case 'a':	goto yy139;
 	case 'E':
-	case 'e':	goto yy131;
+	case 'e':	goto yy135;
 	case 'F':
-	case 'f':	goto yy134;
+	case 'f':	goto yy138;
 	case 'H':
-	case 'h':	goto yy130;
+	case 'h':	goto yy134;
 	case 'I':
-	case 'i':	goto yy132;
+	case 'i':	goto yy136;
 	case 'N':
-	case 'n':	goto yy133;
+	case 'n':	goto yy137;
 	case 'V':
-	case 'v':	goto yy34;
+	case 'v':	goto yy41;
 	default:	goto yy2;
 	}
 yy19:
 	yych = *(marker = ++p);
 	if (yych <= 'T') {
 		if (yych <= 'N') {
-			if (yych == 'D') goto yy122;
+			if (yych == 'D') goto yy126;
 			if (yych <= 'M') goto yy2;
-			goto yy121;
+			goto yy125;
 		} else {
-			if (yych == 'R') goto yy123;
+			if (yych == 'R') goto yy127;
 			if (yych <= 'S') goto yy2;
-			goto yy120;
+			goto yy124;
 		}
 	} else {
 		if (yych <= 'n') {
-			if (yych == 'd') goto yy122;
+			if (yych == 'd') goto yy126;
 			if (yych <= 'm') goto yy2;
-			goto yy121;
+			goto yy125;
 		} else {
 			if (yych <= 'r') {
 				if (yych <= 'q') goto yy2;
-				goto yy123;
+				goto yy127;
 			} else {
-				if (yych == 't') goto yy120;
+				if (yych == 't') goto yy124;
 				goto yy2;
 			}
 		}
@@ -482,15 +510,15 @@ yy19:
 yy20:
 	yych = *(marker = ++p);
 	if (yych <= 'I') {
-		if (yych == 'E') goto yy104;
+		if (yych == 'E') goto yy108;
 		if (yych <= 'H') goto yy2;
-		goto yy103;
+		goto yy107;
 	} else {
 		if (yych <= 'e') {
 			if (yych <= 'd') goto yy2;
-			goto yy104;
+			goto yy108;
 		} else {
-			if (yych == 'i') goto yy103;
+			if (yych == 'i') goto yy107;
 			goto yy2;
 		}
 	}
@@ -498,22 +526,22 @@ yy21:
 	yych = *(marker = ++p);
 	if (yych <= 'Y') {
 		if (yych <= 'R') {
-			if (yych == 'E') goto yy93;
+			if (yych == 'E') goto yy97;
 			goto yy2;
 		} else {
-			if (yych <= 'S') goto yy94;
-			if (yych <= 'T') goto yy92;
+			if (yych <= 'S') goto yy98;
+			if (yych <= 'T') goto yy96;
 			if (yych <= 'X') goto yy2;
-			goto yy91;
+			goto yy95;
 		}
 	} else {
 		if (yych <= 's') {
-			if (yych == 'e') goto yy93;
+			if (yych == 'e') goto yy97;
 			if (yych <= 'r') goto yy2;
-			goto yy94;
+			goto yy98;
 		} else {
-			if (yych <= 't') goto yy92;
-			if (yych == 'y') goto yy91;
+			if (yych <= 't') goto yy96;
+			if (yych == 'y') goto yy95;
 			goto yy2;
 		}
 	}
@@ -521,218 +549,227 @@ yy22:
 	yych = *(marker = ++p);
 	if (yych <= 'R') {
 		if (yych <= 'F') {
-			if (yych == 'C') goto yy70;
+			if (yych == 'C') goto yy74;
 			if (yych <= 'E') goto yy2;
-			goto yy68;
+			goto yy72;
 		} else {
-			if (yych == 'M') goto yy69;
+			if (yych == 'M') goto yy73;
 			if (yych <= 'Q') goto yy2;
-			goto yy67;
+			goto yy71;
 		}
 	} else {
 		if (yych <= 'f') {
-			if (yych == 'c') goto yy70;
+			if (yych == 'c') goto yy74;
 			if (yych <= 'e') goto yy2;
-			goto yy68;
+			goto yy72;
 		} else {
 			if (yych <= 'm') {
 				if (yych <= 'l') goto yy2;
-				goto yy69;
+				goto yy73;
 			} else {
-				if (yych == 'r') goto yy67;
+				if (yych == 'r') goto yy71;
 				goto yy2;
 			}
 		}
 	}
 yy23:
 	yych = *(marker = ++p);
-	if (yych == '3') goto yy62;
+	if (yych == '3') goto yy66;
 	goto yy2;
 yy24:
 	yych = *(marker = ++p);
 	if (yych <= 'O') {
 		if (yych <= 'H') {
-			if (yych == 'E') goto yy52;
+			if (yych == 'E') goto yy56;
 			goto yy2;
 		} else {
-			if (yych <= 'I') goto yy51;
+			if (yych <= 'I') goto yy55;
 			if (yych <= 'N') goto yy2;
-			goto yy50;
+			goto yy54;
 		}
 	} else {
 		if (yych <= 'h') {
-			if (yych == 'e') goto yy52;
+			if (yych == 'e') goto yy56;
 			goto yy2;
 		} else {
-			if (yych <= 'i') goto yy51;
-			if (yych == 'o') goto yy50;
+			if (yych <= 'i') goto yy55;
+			if (yych == 'o') goto yy54;
 			goto yy2;
 		}
 	}
 yy25:
 	yych = *(marker = ++p);
-	if (yych == 'D') goto yy48;
-	if (yych == 'd') goto yy48;
+	if (yych == 'D') goto yy52;
+	if (yych == 'd') goto yy52;
 	goto yy2;
 yy26:
 	yych = *(marker = ++p);
-	if (yych == 'E') goto yy43;
-	if (yych == 'e') goto yy43;
+	if (yych == 'E') goto yy47;
+	if (yych == 'e') goto yy47;
 	goto yy2;
 yy27:
 	yych = *(marker = ++p);
-	if (yych == 'U') goto yy40;
-	if (yych == 'u') goto yy40;
+	if (yych == 'U') goto yy44;
+	if (yych == 'u') goto yy44;
 	goto yy2;
 yy28:
 	yych = *(marker = ++p);
-	if (yych == 'M') goto yy30;
-	if (yych == 'm') goto yy30;
+	if (yych == 'M') goto yy38;
+	if (yych == 'm') goto yy38;
 	goto yy2;
 yy29:
 	yych = *++p;
 	goto yy2;
 yy30:
 	yych = *++p;
-	if (yych == 'S') goto yy32;
-	if (yych == 's') goto yy32;
+	if (yych <= 0x7F) goto yy31;
+	if (yych <= 0xBF) goto yy29;
 yy31:
 	p = marker;
 	goto yy2;
 yy32:
 	yych = *++p;
-	if (yych == 'G') goto yy33;
-	if (yych != 'g') goto yy31;
+	if (yych <= 0x9F) goto yy31;
+	if (yych <= 0xBF) goto yy30;
+	goto yy31;
 yy33:
 	yych = *++p;
-	if (yych == 'R') goto yy34;
-	if (yych != 'r') goto yy31;
+	if (yych <= 0x7F) goto yy31;
+	if (yych <= 0xBF) goto yy30;
+	goto yy31;
 yy34:
 	yych = *++p;
-	if (yych != ':') goto yy31;
+	if (yych <= 0x8F) goto yy31;
+	if (yych <= 0xBF) goto yy33;
+	goto yy31;
 yy35:
-	++p;
-	yych = *p;
-	if (yybm[0+yych] & 128) {
-		goto yy35;
-	}
-	if (yych <= '=') goto yy31;
-	if (yych <= '>') goto yy38;
-	++p;
-	yych = *p;
-	if (yych <= '@') {
-		if (yych <= ' ') goto yy31;
-		if (yych <= '/') goto yy35;
-		if (yych <= '9') goto yy31;
-		goto yy35;
-	} else {
-		if (yych <= '`') {
-			if (yych <= 'Z') goto yy31;
-			goto yy35;
-		} else {
-			if (yych <= 'z') goto yy31;
-			if (yych <= '~') goto yy35;
-			goto yy31;
-		}
-	}
+	yych = *++p;
+	if (yych <= 0x7F) goto yy31;
+	if (yych <= 0xBF) goto yy33;
+	goto yy31;
+yy36:
+	yych = *++p;
+	if (yych <= 0x7F) goto yy31;
+	if (yych <= 0x8F) goto yy33;
+	goto yy31;
+yy37:
+	yych = *++p;
+	if (yych <= 0x7F) goto yy31;
+	if (yych <= 0x9F) goto yy30;
+	goto yy31;
 yy38:
-	++p;
-	{ return (p - start); }
+	yych = *++p;
+	if (yych == 'S') goto yy39;
+	if (yych != 's') goto yy31;
+yy39:
+	yych = *++p;
+	if (yych == 'G') goto yy40;
+	if (yych != 'g') goto yy31;
 yy40:
 	yych = *++p;
-	if (yych == 'E') goto yy41;
-	if (yych != 'e') goto yy31;
+	if (yych == 'R') goto yy41;
+	if (yych != 'r') goto yy31;
 yy41:
 	yych = *++p;
-	if (yych == 'R') goto yy42;
-	if (yych != 'r') goto yy31;
+	if (yych != ':') goto yy31;
 yy42:
+	++p;
+	{ return (bufsize_t)(p - start); }
+yy44:
+	yych = *++p;
+	if (yych == 'E') goto yy45;
+	if (yych != 'e') goto yy31;
+yy45:
+	yych = *++p;
+	if (yych == 'R') goto yy46;
+	if (yych != 'r') goto yy31;
+yy46:
 	yych = *++p;
-	if (yych == 'Y') goto yy34;
-	if (yych == 'y') goto yy34;
+	if (yych == 'Y') goto yy41;
+	if (yych == 'y') goto yy41;
 	goto yy31;
-yy43:
+yy47:
 	yych = *++p;
-	if (yych == 'Y') goto yy44;
+	if (yych == 'Y') goto yy48;
 	if (yych != 'y') goto yy31;
-yy44:
+yy48:
 	yych = *++p;
-	if (yych == 'P') goto yy45;
+	if (yych == 'P') goto yy49;
 	if (yych != 'p') goto yy31;
-yy45:
+yy49:
 	yych = *++p;
-	if (yych == 'A') goto yy46;
+	if (yych == 'A') goto yy50;
 	if (yych != 'a') goto yy31;
-yy46:
+yy50:
 	yych = *++p;
-	if (yych == 'R') goto yy47;
+	if (yych == 'R') goto yy51;
 	if (yych != 'r') goto yy31;
-yy47:
+yy51:
 	yych = *++p;
-	if (yych == 'C') goto yy34;
-	if (yych == 'c') goto yy34;
+	if (yych == 'C') goto yy41;
+	if (yych == 'c') goto yy41;
 	goto yy31;
-yy48:
+yy52:
 	yych = *++p;
 	if (yych != '2') goto yy31;
 	yych = *++p;
-	if (yych == 'K') goto yy34;
-	if (yych == 'k') goto yy34;
+	if (yych == 'K') goto yy41;
+	if (yych == 'k') goto yy41;
 	goto yy31;
-yy50:
+yy54:
 	yych = *++p;
-	if (yych == 'L') goto yy61;
-	if (yych == 'l') goto yy61;
+	if (yych == 'L') goto yy65;
+	if (yych == 'l') goto yy65;
 	goto yy31;
-yy51:
+yy55:
 	yych = *++p;
-	if (yych == 'T') goto yy57;
-	if (yych == 't') goto yy57;
+	if (yych == 'T') goto yy61;
+	if (yych == 't') goto yy61;
 	goto yy31;
-yy52:
+yy56:
 	yych = *++p;
-	if (yych == 'S') goto yy53;
+	if (yych == 'S') goto yy57;
 	if (yych != 's') goto yy31;
-yy53:
+yy57:
 	yych = *++p;
-	if (yych == 'H') goto yy54;
+	if (yych == 'H') goto yy58;
 	if (yych != 'h') goto yy31;
-yy54:
+yy58:
 	yych = *++p;
-	if (yych == 'A') goto yy55;
+	if (yych == 'A') goto yy59;
 	if (yych != 'a') goto yy31;
-yy55:
+yy59:
 	yych = *++p;
-	if (yych == 'R') goto yy56;
+	if (yych == 'R') goto yy60;
 	if (yych != 'r') goto yy31;
-yy56:
+yy60:
 	yych = *++p;
-	if (yych == 'E') goto yy34;
-	if (yych == 'e') goto yy34;
+	if (yych == 'E') goto yy41;
+	if (yych == 'e') goto yy41;
 	goto yy31;
-yy57:
+yy61:
 	yych = *++p;
-	if (yych == 'C') goto yy58;
+	if (yych == 'C') goto yy62;
 	if (yych != 'c') goto yy31;
-yy58:
+yy62:
 	yych = *++p;
-	if (yych == 'O') goto yy59;
+	if (yych == 'O') goto yy63;
 	if (yych != 'o') goto yy31;
-yy59:
+yy63:
 	yych = *++p;
-	if (yych == 'I') goto yy60;
+	if (yych == 'I') goto yy64;
 	if (yych != 'i') goto yy31;
-yy60:
+yy64:
 	yych = *++p;
-	if (yych == 'N') goto yy34;
-	if (yych == 'n') goto yy34;
+	if (yych == 'N') goto yy41;
+	if (yych == 'n') goto yy41;
 	goto yy31;
-yy61:
+yy65:
 	yych = *++p;
-	if (yych == 'O') goto yy34;
-	if (yych == 'o') goto yy34;
+	if (yych == 'O') goto yy41;
+	if (yych == 'o') goto yy41;
 	goto yy31;
-yy62:
+yy66:
 	yych = *++p;
 	if (yych != '9') goto yy31;
 	yych = *++p;
@@ -743,2242 +780,2242 @@ yy62:
 	if (yych != '0') goto yy31;
 	yych = *++p;
 	if (yych <= 'Q') goto yy31;
-	if (yych <= 'S') goto yy34;
+	if (yych <= 'S') goto yy41;
 	if (yych <= 'q') goto yy31;
-	if (yych <= 's') goto yy34;
+	if (yych <= 's') goto yy41;
 	goto yy31;
-yy67:
+yy71:
 	yych = *++p;
-	if (yych == 'I') goto yy34;
-	if (yych == 'i') goto yy34;
+	if (yych == 'I') goto yy41;
+	if (yych == 'i') goto yy41;
 	goto yy31;
-yy68:
+yy72:
 	yych = *++p;
-	if (yych == 'I') goto yy89;
-	if (yych == 'i') goto yy89;
+	if (yych == 'I') goto yy93;
+	if (yych == 'i') goto yy93;
 	goto yy31;
-yy69:
+yy73:
 	yych = *++p;
 	if (yych <= 'P') {
-		if (yych == 'L') goto yy79;
+		if (yych == 'L') goto yy83;
 		if (yych <= 'O') goto yy31;
-		goto yy80;
+		goto yy84;
 	} else {
 		if (yych <= 'l') {
 			if (yych <= 'k') goto yy31;
-			goto yy79;
+			goto yy83;
 		} else {
-			if (yych == 'p') goto yy80;
+			if (yych == 'p') goto yy84;
 			goto yy31;
 		}
 	}
-yy70:
+yy74:
 	yych = *++p;
-	if (yych == 'O') goto yy71;
+	if (yych == 'O') goto yy75;
 	if (yych != 'o') goto yy31;
-yy71:
+yy75:
 	yych = *++p;
-	if (yych == 'N') goto yy72;
+	if (yych == 'N') goto yy76;
 	if (yych != 'n') goto yy31;
-yy72:
+yy76:
 	yych = *++p;
-	if (yych == '-') goto yy73;
-	if (yych == ':') goto yy35;
+	if (yych == '-') goto yy77;
+	if (yych == ':') goto yy42;
 	goto yy31;
-yy73:
+yy77:
 	yych = *++p;
-	if (yych == 'U') goto yy74;
+	if (yych == 'U') goto yy78;
 	if (yych != 'u') goto yy31;
-yy74:
+yy78:
 	yych = *++p;
-	if (yych == 'S') goto yy75;
+	if (yych == 'S') goto yy79;
 	if (yych != 's') goto yy31;
-yy75:
+yy79:
 	yych = *++p;
-	if (yych == 'E') goto yy76;
+	if (yych == 'E') goto yy80;
 	if (yych != 'e') goto yy31;
-yy76:
+yy80:
 	yych = *++p;
-	if (yych == 'R') goto yy77;
+	if (yych == 'R') goto yy81;
 	if (yych != 'r') goto yy31;
-yy77:
+yy81:
 	yych = *++p;
-	if (yych == 'I') goto yy78;
+	if (yych == 'I') goto yy82;
 	if (yych != 'i') goto yy31;
-yy78:
+yy82:
 	yych = *++p;
-	if (yych == 'D') goto yy34;
-	if (yych == 'd') goto yy34;
+	if (yych == 'D') goto yy41;
+	if (yych == 'd') goto yy41;
 	goto yy31;
-yy79:
+yy83:
 	yych = *++p;
-	if (yych == 'R') goto yy81;
-	if (yych == 'r') goto yy81;
+	if (yych == 'R') goto yy85;
+	if (yych == 'r') goto yy85;
 	goto yy31;
-yy80:
+yy84:
 	yych = *++p;
-	if (yych == 'P') goto yy34;
-	if (yych == 'p') goto yy34;
+	if (yych == 'P') goto yy41;
+	if (yych == 'p') goto yy41;
 	goto yy31;
-yy81:
+yy85:
 	yych = *++p;
-	if (yych == 'P') goto yy82;
+	if (yych == 'P') goto yy86;
 	if (yych != 'p') goto yy31;
-yy82:
+yy86:
 	yych = *++p;
-	if (yych == 'C') goto yy83;
+	if (yych == 'C') goto yy87;
 	if (yych != 'c') goto yy31;
-yy83:
+yy87:
 	yych = *++p;
 	if (yych != '.') goto yy31;
 	yych = *++p;
-	if (yych == 'B') goto yy85;
+	if (yych == 'B') goto yy89;
 	if (yych != 'b') goto yy31;
-yy85:
+yy89:
 	yych = *++p;
-	if (yych == 'E') goto yy86;
+	if (yych == 'E') goto yy90;
 	if (yych != 'e') goto yy31;
-yy86:
+yy90:
 	yych = *++p;
-	if (yych == 'E') goto yy87;
+	if (yych == 'E') goto yy91;
 	if (yych != 'e') goto yy31;
-yy87:
+yy91:
 	yych = *++p;
-	if (yych == 'P') goto yy88;
+	if (yych == 'P') goto yy92;
 	if (yych != 'p') goto yy31;
-yy88:
+yy92:
 	yych = *++p;
 	if (yych <= 'R') {
-		if (yych == ':') goto yy35;
+		if (yych == ':') goto yy42;
 		goto yy31;
 	} else {
-		if (yych <= 'S') goto yy34;
-		if (yych == 's') goto yy34;
+		if (yych <= 'S') goto yy41;
+		if (yych == 's') goto yy41;
 		goto yy31;
 	}
-yy89:
+yy93:
 	yych = *++p;
-	if (yych == 'R') goto yy90;
+	if (yych == 'R') goto yy94;
 	if (yych != 'r') goto yy31;
-yy90:
+yy94:
 	yych = *++p;
-	if (yych == 'E') goto yy34;
-	if (yych == 'e') goto yy34;
+	if (yych == 'E') goto yy41;
+	if (yych == 'e') goto yy41;
 	goto yy31;
-yy91:
+yy95:
 	yych = *++p;
-	if (yych == 'C') goto yy99;
-	if (yych == 'c') goto yy99;
+	if (yych == 'C') goto yy103;
+	if (yych == 'c') goto yy103;
 	goto yy31;
-yy92:
+yy96:
 	yych = *++p;
-	if (yych == 'A') goto yy98;
-	if (yych == 'a') goto yy98;
+	if (yych == 'A') goto yy102;
+	if (yych == 'a') goto yy102;
 	goto yy31;
-yy93:
+yy97:
 	yych = *++p;
-	if (yych == 'B') goto yy95;
-	if (yych == 'b') goto yy95;
+	if (yych == 'B') goto yy99;
+	if (yych == 'b') goto yy99;
 	goto yy31;
-yy94:
+yy98:
 	yych = *++p;
 	if (yych <= 'R') {
-		if (yych == ':') goto yy35;
+		if (yych == ':') goto yy42;
 		goto yy31;
 	} else {
-		if (yych <= 'S') goto yy34;
-		if (yych == 's') goto yy34;
+		if (yych <= 'S') goto yy41;
+		if (yych == 's') goto yy41;
 		goto yy31;
 	}
-yy95:
+yy99:
 	yych = *++p;
-	if (yych == 'C') goto yy96;
+	if (yych == 'C') goto yy100;
 	if (yych != 'c') goto yy31;
-yy96:
+yy100:
 	yych = *++p;
-	if (yych == 'A') goto yy97;
+	if (yych == 'A') goto yy101;
 	if (yych != 'a') goto yy31;
-yy97:
+yy101:
 	yych = *++p;
-	if (yych == 'L') goto yy34;
-	if (yych == 'l') goto yy34;
+	if (yych == 'L') goto yy41;
+	if (yych == 'l') goto yy41;
 	goto yy31;
-yy98:
+yy102:
 	yych = *++p;
-	if (yych == 'I') goto yy34;
-	if (yych == 'i') goto yy34;
+	if (yych == 'I') goto yy41;
+	if (yych == 'i') goto yy41;
 	goto yy31;
-yy99:
+yy103:
 	yych = *++p;
-	if (yych == 'I') goto yy100;
+	if (yych == 'I') goto yy104;
 	if (yych != 'i') goto yy31;
-yy100:
+yy104:
 	yych = *++p;
-	if (yych == 'W') goto yy101;
+	if (yych == 'W') goto yy105;
 	if (yych != 'w') goto yy31;
-yy101:
+yy105:
 	yych = *++p;
-	if (yych == 'Y') goto yy102;
+	if (yych == 'Y') goto yy106;
 	if (yych != 'y') goto yy31;
-yy102:
+yy106:
 	yych = *++p;
-	if (yych == 'G') goto yy34;
-	if (yych == 'g') goto yy34;
+	if (yych == 'G') goto yy41;
+	if (yych == 'g') goto yy41;
 	goto yy31;
-yy103:
+yy107:
 	yych = *++p;
-	if (yych == 'E') goto yy112;
-	if (yych == 'e') goto yy112;
+	if (yych == 'E') goto yy116;
+	if (yych == 'e') goto yy116;
 	goto yy31;
-yy104:
+yy108:
 	yych = *++p;
 	if (yych <= 'N') {
 		if (yych <= 'L') goto yy31;
-		if (yych >= 'N') goto yy106;
+		if (yych >= 'N') goto yy110;
 	} else {
 		if (yych <= 'l') goto yy31;
-		if (yych <= 'm') goto yy105;
-		if (yych <= 'n') goto yy106;
+		if (yych <= 'm') goto yy109;
+		if (yych <= 'n') goto yy110;
 		goto yy31;
 	}
-yy105:
+yy109:
 	yych = *++p;
-	if (yych == 'M') goto yy111;
-	if (yych == 'm') goto yy111;
+	if (yych == 'M') goto yy115;
+	if (yych == 'm') goto yy115;
 	goto yy31;
-yy106:
+yy110:
 	yych = *++p;
-	if (yych == 'T') goto yy107;
+	if (yych == 'T') goto yy111;
 	if (yych != 't') goto yy31;
-yy107:
+yy111:
 	yych = *++p;
-	if (yych == 'R') goto yy108;
+	if (yych == 'R') goto yy112;
 	if (yych != 'r') goto yy31;
-yy108:
+yy112:
 	yych = *++p;
-	if (yych == 'I') goto yy109;
+	if (yych == 'I') goto yy113;
 	if (yych != 'i') goto yy31;
-yy109:
+yy113:
 	yych = *++p;
-	if (yych == 'L') goto yy110;
+	if (yych == 'L') goto yy114;
 	if (yych != 'l') goto yy31;
-yy110:
+yy114:
 	yych = *++p;
-	if (yych == 'O') goto yy34;
-	if (yych == 'o') goto yy34;
+	if (yych == 'O') goto yy41;
+	if (yych == 'o') goto yy41;
 	goto yy31;
-yy111:
+yy115:
 	yych = *++p;
-	if (yych == 'I') goto yy34;
-	if (yych == 'i') goto yy34;
+	if (yych == 'I') goto yy41;
+	if (yych == 'i') goto yy41;
 	goto yy31;
-yy112:
+yy116:
 	yych = *++p;
-	if (yych == 'W') goto yy113;
+	if (yych == 'W') goto yy117;
 	if (yych != 'w') goto yy31;
-yy113:
+yy117:
 	yych = *++p;
 	if (yych != '-') goto yy31;
 	yych = *++p;
-	if (yych == 'S') goto yy115;
+	if (yych == 'S') goto yy119;
 	if (yych != 's') goto yy31;
-yy115:
+yy119:
 	yych = *++p;
-	if (yych == 'O') goto yy116;
+	if (yych == 'O') goto yy120;
 	if (yych != 'o') goto yy31;
-yy116:
+yy120:
 	yych = *++p;
-	if (yych == 'U') goto yy117;
+	if (yych == 'U') goto yy121;
 	if (yych != 'u') goto yy31;
-yy117:
+yy121:
 	yych = *++p;
-	if (yych == 'R') goto yy118;
+	if (yych == 'R') goto yy122;
 	if (yych != 'r') goto yy31;
-yy118:
+yy122:
 	yych = *++p;
-	if (yych == 'C') goto yy119;
+	if (yych == 'C') goto yy123;
 	if (yych != 'c') goto yy31;
-yy119:
+yy123:
 	yych = *++p;
-	if (yych == 'E') goto yy34;
-	if (yych == 'e') goto yy34;
+	if (yych == 'E') goto yy41;
+	if (yych == 'e') goto yy41;
 	goto yy31;
-yy120:
+yy124:
 	yych = *++p;
-	if (yych == '2') goto yy127;
+	if (yych == '2') goto yy131;
 	goto yy31;
-yy121:
+yy125:
 	yych = *++p;
-	if (yych == 'R') goto yy124;
-	if (yych == 'r') goto yy124;
+	if (yych == 'R') goto yy128;
+	if (yych == 'r') goto yy128;
 	goto yy31;
-yy122:
+yy126:
 	yych = *++p;
-	if (yych == 'P') goto yy34;
-	if (yych == 'p') goto yy34;
+	if (yych == 'P') goto yy41;
+	if (yych == 'p') goto yy41;
 	goto yy31;
-yy123:
+yy127:
 	yych = *++p;
-	if (yych == 'N') goto yy34;
-	if (yych == 'n') goto yy34;
+	if (yych == 'N') goto yy41;
+	if (yych == 'n') goto yy41;
 	goto yy31;
-yy124:
+yy128:
 	yych = *++p;
-	if (yych == 'E') goto yy125;
+	if (yych == 'E') goto yy129;
 	if (yych != 'e') goto yy31;
-yy125:
+yy129:
 	yych = *++p;
-	if (yych == 'A') goto yy126;
+	if (yych == 'A') goto yy130;
 	if (yych != 'a') goto yy31;
-yy126:
+yy130:
 	yych = *++p;
-	if (yych == 'L') goto yy34;
-	if (yych == 'l') goto yy34;
+	if (yych == 'L') goto yy41;
+	if (yych == 'l') goto yy41;
 	goto yy31;
-yy127:
+yy131:
 	yych = *++p;
 	if (yych != '0') goto yy31;
 	yych = *++p;
 	if (yych != '0') goto yy31;
 	yych = *++p;
-	if (yych == '4') goto yy34;
+	if (yych == '4') goto yy41;
 	goto yy31;
-yy130:
+yy134:
 	yych = *++p;
-	if (yych == 'I') goto yy149;
-	if (yych == 'i') goto yy149;
+	if (yych == 'I') goto yy153;
+	if (yych == 'i') goto yy153;
 	goto yy31;
-yy131:
+yy135:
 	yych = *++p;
 	if (yych <= 'L') {
-		if (yych == 'A') goto yy141;
+		if (yych == 'A') goto yy145;
 		if (yych <= 'K') goto yy31;
-		goto yy140;
+		goto yy144;
 	} else {
 		if (yych <= 'a') {
 			if (yych <= '`') goto yy31;
-			goto yy141;
+			goto yy145;
 		} else {
-			if (yych == 'l') goto yy140;
+			if (yych == 'l') goto yy144;
 			goto yy31;
 		}
 	}
-yy132:
+yy136:
 	yych = *++p;
-	if (yych == 'P') goto yy34;
-	if (yych == 'p') goto yy34;
+	if (yych == 'P') goto yy41;
+	if (yych == 'p') goto yy41;
 	goto yy31;
-yy133:
+yy137:
 	yych = *++p;
-	if (yych == '3') goto yy137;
+	if (yych == '3') goto yy141;
 	goto yy31;
-yy134:
+yy138:
 	yych = *++p;
-	if (yych == 'T') goto yy136;
-	if (yych == 't') goto yy136;
+	if (yych == 'T') goto yy140;
+	if (yych == 't') goto yy140;
 	goto yy31;
-yy135:
+yy139:
 	yych = *++p;
-	if (yych == 'G') goto yy34;
-	if (yych == 'g') goto yy34;
+	if (yych == 'G') goto yy41;
+	if (yych == 'g') goto yy41;
 	goto yy31;
-yy136:
+yy140:
 	yych = *++p;
-	if (yych == 'P') goto yy34;
-	if (yych == 'p') goto yy34;
+	if (yych == 'P') goto yy41;
+	if (yych == 'p') goto yy41;
 	goto yy31;
-yy137:
+yy141:
 	yych = *++p;
 	if (yych != '2') goto yy31;
 	yych = *++p;
 	if (yych != '7') goto yy31;
 	yych = *++p;
-	if (yych == '0') goto yy34;
+	if (yych == '0') goto yy41;
 	goto yy31;
-yy140:
+yy144:
 	yych = *++p;
 	if (yych <= 'M') {
-		if (yych == ':') goto yy35;
+		if (yych == ':') goto yy42;
 		goto yy31;
 	} else {
-		if (yych <= 'N') goto yy147;
-		if (yych == 'n') goto yy147;
+		if (yych <= 'N') goto yy151;
+		if (yych == 'n') goto yy151;
 		goto yy31;
 	}
-yy141:
+yy145:
 	yych = *++p;
-	if (yych == 'M') goto yy142;
+	if (yych == 'M') goto yy146;
 	if (yych != 'm') goto yy31;
-yy142:
+yy146:
 	yych = *++p;
-	if (yych == 'S') goto yy143;
+	if (yych == 'S') goto yy147;
 	if (yych != 's') goto yy31;
-yy143:
+yy147:
 	yych = *++p;
-	if (yych == 'P') goto yy144;
+	if (yych == 'P') goto yy148;
 	if (yych != 'p') goto yy31;
-yy144:
+yy148:
 	yych = *++p;
-	if (yych == 'E') goto yy145;
+	if (yych == 'E') goto yy149;
 	if (yych != 'e') goto yy31;
-yy145:
+yy149:
 	yych = *++p;
-	if (yych == 'A') goto yy146;
+	if (yych == 'A') goto yy150;
 	if (yych != 'a') goto yy31;
-yy146:
+yy150:
 	yych = *++p;
-	if (yych == 'K') goto yy34;
-	if (yych == 'k') goto yy34;
+	if (yych == 'K') goto yy41;
+	if (yych == 'k') goto yy41;
 	goto yy31;
-yy147:
+yy151:
 	yych = *++p;
-	if (yych == 'E') goto yy148;
+	if (yych == 'E') goto yy152;
 	if (yych != 'e') goto yy31;
-yy148:
+yy152:
 	yych = *++p;
-	if (yych == 'T') goto yy34;
-	if (yych == 't') goto yy34;
+	if (yych == 'T') goto yy41;
+	if (yych == 't') goto yy41;
 	goto yy31;
-yy149:
+yy153:
 	yych = *++p;
 	if (yych <= 'S') {
-		if (yych == 'N') goto yy150;
+		if (yych == 'N') goto yy154;
 		if (yych <= 'R') goto yy31;
-		goto yy151;
+		goto yy155;
 	} else {
 		if (yych <= 'n') {
 			if (yych <= 'm') goto yy31;
 		} else {
-			if (yych == 's') goto yy151;
+			if (yych == 's') goto yy155;
 			goto yy31;
 		}
 	}
-yy150:
+yy154:
 	yych = *++p;
-	if (yych == 'G') goto yy158;
-	if (yych == 'g') goto yy158;
+	if (yych == 'G') goto yy162;
+	if (yych == 'g') goto yy162;
 	goto yy31;
-yy151:
+yy155:
 	yych = *++p;
-	if (yych == 'M') goto yy152;
+	if (yych == 'M') goto yy156;
 	if (yych != 'm') goto yy31;
-yy152:
+yy156:
 	yych = *++p;
-	if (yych == 'E') goto yy153;
+	if (yych == 'E') goto yy157;
 	if (yych != 'e') goto yy31;
-yy153:
+yy157:
 	yych = *++p;
-	if (yych == 'S') goto yy154;
+	if (yych == 'S') goto yy158;
 	if (yych != 's') goto yy31;
-yy154:
+yy158:
 	yych = *++p;
-	if (yych == 'S') goto yy155;
+	if (yych == 'S') goto yy159;
 	if (yych != 's') goto yy31;
-yy155:
+yy159:
 	yych = *++p;
-	if (yych == 'A') goto yy156;
+	if (yych == 'A') goto yy160;
 	if (yych != 'a') goto yy31;
-yy156:
+yy160:
 	yych = *++p;
-	if (yych == 'G') goto yy157;
+	if (yych == 'G') goto yy161;
 	if (yych != 'g') goto yy31;
-yy157:
+yy161:
 	yych = *++p;
-	if (yych == 'E') goto yy34;
-	if (yych == 'e') goto yy34;
+	if (yych == 'E') goto yy41;
+	if (yych == 'e') goto yy41;
 	goto yy31;
-yy158:
+yy162:
 	yych = *++p;
-	if (yych == 'S') goto yy34;
-	if (yych == 's') goto yy34;
+	if (yych == 'S') goto yy41;
+	if (yych == 's') goto yy41;
 	goto yy31;
-yy159:
+yy163:
 	yych = *++p;
-	if (yych == 'N') goto yy34;
-	if (yych == 'n') goto yy34;
+	if (yych == 'N') goto yy41;
+	if (yych == 'n') goto yy41;
 	goto yy31;
-yy160:
+yy164:
 	yych = *++p;
-	if (yych == 'E') goto yy210;
-	if (yych == 'e') goto yy210;
+	if (yych == 'E') goto yy214;
+	if (yych == 'e') goto yy214;
 	goto yy31;
-yy161:
+yy165:
 	yych = *++p;
-	if (yych == 'H') goto yy34;
-	if (yych == 'h') goto yy34;
+	if (yych == 'H') goto yy41;
+	if (yych == 'h') goto yy41;
 	goto yy31;
-yy162:
+yy166:
 	yych = *++p;
-	if (yych == 'O') goto yy206;
-	if (yych == 'o') goto yy206;
+	if (yych == 'O') goto yy210;
+	if (yych == 'o') goto yy210;
 	goto yy31;
-yy163:
+yy167:
 	yych = *++p;
 	if (yych <= 'L') {
-		if (yych == 'A') goto yy196;
+		if (yych == 'A') goto yy200;
 		if (yych <= 'K') goto yy31;
-		goto yy197;
+		goto yy201;
 	} else {
 		if (yych <= 'a') {
 			if (yych <= '`') goto yy31;
-			goto yy196;
+			goto yy200;
 		} else {
-			if (yych == 'l') goto yy197;
+			if (yych == 'l') goto yy201;
 			goto yy31;
 		}
 	}
-yy164:
+yy168:
 	yych = *++p;
 	if (yych <= 'S') {
-		if (yych == 'B') goto yy34;
+		if (yych == 'B') goto yy41;
 		if (yych <= 'R') goto yy31;
-		goto yy34;
+		goto yy41;
 	} else {
 		if (yych <= 'b') {
 			if (yych <= 'a') goto yy31;
-			goto yy34;
+			goto yy41;
 		} else {
-			if (yych == 's') goto yy34;
+			if (yych == 's') goto yy41;
 			goto yy31;
 		}
 	}
-yy165:
+yy169:
 	yych = *++p;
-	if (yych == 'Y') goto yy194;
-	if (yych == 'y') goto yy194;
+	if (yych == 'Y') goto yy198;
+	if (yych == 'y') goto yy198;
 	goto yy31;
-yy166:
+yy170:
 	yych = *++p;
-	if (yych == 'N') goto yy34;
-	if (yych == 'n') goto yy34;
+	if (yych == 'N') goto yy41;
+	if (yych == 'n') goto yy41;
 	goto yy31;
-yy167:
+yy171:
 	yych = *++p;
-	if (yych == 'T') goto yy193;
-	if (yych == 't') goto yy193;
+	if (yych == 'T') goto yy197;
+	if (yych == 't') goto yy197;
 	goto yy31;
-yy168:
+yy172:
 	yych = *++p;
 	if (yych <= 'S') {
 		if (yych <= 'C') {
 			if (yych <= 'B') goto yy31;
-			goto yy180;
+			goto yy184;
 		} else {
 			if (yych <= 'Q') goto yy31;
-			if (yych <= 'R') goto yy178;
-			goto yy179;
+			if (yych <= 'R') goto yy182;
+			goto yy183;
 		}
 	} else {
 		if (yych <= 'q') {
-			if (yych == 'c') goto yy180;
+			if (yych == 'c') goto yy184;
 			goto yy31;
 		} else {
-			if (yych <= 'r') goto yy178;
-			if (yych <= 's') goto yy179;
+			if (yych <= 'r') goto yy182;
+			if (yych <= 's') goto yy183;
 			goto yy31;
 		}
 	}
-yy169:
+yy173:
 	yych = *++p;
-	if (yych == 'M') goto yy177;
-	if (yych == 'm') goto yy177;
+	if (yych == 'M') goto yy181;
+	if (yych == 'm') goto yy181;
 	goto yy31;
-yy170:
+yy174:
 	yych = *++p;
 	if (yych <= 'P') {
-		if (yych == 'E') goto yy174;
+		if (yych == 'E') goto yy178;
 		if (yych <= 'O') goto yy31;
-		goto yy175;
+		goto yy179;
 	} else {
 		if (yych <= 'e') {
 			if (yych <= 'd') goto yy31;
-			goto yy174;
+			goto yy178;
 		} else {
-			if (yych == 'p') goto yy175;
+			if (yych == 'p') goto yy179;
 			goto yy31;
 		}
 	}
-yy171:
+yy175:
 	yych = *++p;
-	if (yych == 'T') goto yy172;
+	if (yych == 'T') goto yy176;
 	if (yych != 't') goto yy31;
-yy172:
+yy176:
 	yych = *++p;
-	if (yych == 'T') goto yy173;
+	if (yych == 'T') goto yy177;
 	if (yych != 't') goto yy31;
-yy173:
+yy177:
 	yych = *++p;
-	if (yych == 'P') goto yy34;
-	if (yych == 'p') goto yy34;
+	if (yych == 'P') goto yy41;
+	if (yych == 'p') goto yy41;
 	goto yy31;
-yy174:
+yy178:
 	yych = *++p;
-	if (yych == 'V') goto yy176;
-	if (yych == 'v') goto yy176;
+	if (yych == 'V') goto yy180;
+	if (yych == 'v') goto yy180;
 	goto yy31;
-yy175:
+yy179:
 	yych = *++p;
 	if (yych <= 'R') {
-		if (yych == ':') goto yy35;
+		if (yych == ':') goto yy42;
 		goto yy31;
 	} else {
-		if (yych <= 'S') goto yy34;
-		if (yych == 's') goto yy34;
+		if (yych <= 'S') goto yy41;
+		if (yych == 's') goto yy41;
 		goto yy31;
 	}
-yy176:
+yy180:
 	yych = *++p;
-	if (yych == 'E') goto yy34;
-	if (yych == 'e') goto yy34;
+	if (yych == 'E') goto yy41;
+	if (yych == 'e') goto yy41;
 	goto yy31;
-yy177:
+yy181:
 	yych = *++p;
-	if (yych == 'P') goto yy34;
-	if (yych == 'p') goto yy34;
+	if (yych == 'P') goto yy41;
+	if (yych == 'p') goto yy41;
 	goto yy31;
-yy178:
+yy182:
 	yych = *++p;
-	if (yych == 'V') goto yy190;
-	if (yych == 'v') goto yy190;
+	if (yych == 'V') goto yy194;
+	if (yych == 'v') goto yy194;
 	goto yy31;
-yy179:
+yy183:
 	yych = *++p;
-	if (yych == 'S') goto yy187;
-	if (yych == 's') goto yy187;
+	if (yych == 'S') goto yy191;
+	if (yych == 's') goto yy191;
 	goto yy31;
-yy180:
+yy184:
 	yych = *++p;
-	if (yych == 'O') goto yy181;
+	if (yych == 'O') goto yy185;
 	if (yych != 'o') goto yy31;
-yy181:
+yy185:
 	yych = *++p;
-	if (yych == 'N') goto yy182;
+	if (yych == 'N') goto yy186;
 	if (yych != 'n') goto yy31;
-yy182:
+yy186:
 	yych = *++p;
-	if (yych == 'D') goto yy183;
+	if (yych == 'D') goto yy187;
 	if (yych != 'd') goto yy31;
-yy183:
+yy187:
 	yych = *++p;
-	if (yych == 'L') goto yy184;
+	if (yych == 'L') goto yy188;
 	if (yych != 'l') goto yy31;
-yy184:
+yy188:
 	yych = *++p;
-	if (yych == 'I') goto yy185;
+	if (yych == 'I') goto yy189;
 	if (yych != 'i') goto yy31;
-yy185:
+yy189:
 	yych = *++p;
-	if (yych == 'F') goto yy186;
+	if (yych == 'F') goto yy190;
 	if (yych != 'f') goto yy31;
-yy186:
+yy190:
 	yych = *++p;
-	if (yych == 'E') goto yy34;
-	if (yych == 'e') goto yy34;
+	if (yych == 'E') goto yy41;
+	if (yych == 'e') goto yy41;
 	goto yy31;
-yy187:
+yy191:
 	yych = *++p;
-	if (yych == 'I') goto yy188;
+	if (yych == 'I') goto yy192;
 	if (yych != 'i') goto yy31;
-yy188:
+yy192:
 	yych = *++p;
-	if (yych == 'O') goto yy189;
+	if (yych == 'O') goto yy193;
 	if (yych != 'o') goto yy31;
-yy189:
+yy193:
 	yych = *++p;
-	if (yych == 'N') goto yy34;
-	if (yych == 'n') goto yy34;
+	if (yych == 'N') goto yy41;
+	if (yych == 'n') goto yy41;
 	goto yy31;
-yy190:
+yy194:
 	yych = *++p;
-	if (yych == 'I') goto yy191;
+	if (yych == 'I') goto yy195;
 	if (yych != 'i') goto yy31;
-yy191:
+yy195:
 	yych = *++p;
-	if (yych == 'C') goto yy192;
+	if (yych == 'C') goto yy196;
 	if (yych != 'c') goto yy31;
-yy192:
+yy196:
 	yych = *++p;
-	if (yych == 'E') goto yy34;
-	if (yych == 'e') goto yy34;
+	if (yych == 'E') goto yy41;
+	if (yych == 'e') goto yy41;
 	goto yy31;
-yy193:
+yy197:
 	yych = *++p;
-	if (yych == 'P') goto yy34;
-	if (yych == 'p') goto yy34;
+	if (yych == 'P') goto yy41;
+	if (yych == 'p') goto yy41;
 	goto yy31;
-yy194:
+yy198:
 	yych = *++p;
-	if (yych == 'P') goto yy195;
+	if (yych == 'P') goto yy199;
 	if (yych != 'p') goto yy31;
-yy195:
+yy199:
 	yych = *++p;
-	if (yych == 'E') goto yy34;
-	if (yych == 'e') goto yy34;
+	if (yych == 'E') goto yy41;
+	if (yych == 'e') goto yy41;
 	goto yy31;
-yy196:
+yy200:
 	yych = *++p;
-	if (yych == 'P') goto yy200;
-	if (yych == 'p') goto yy200;
+	if (yych == 'P') goto yy204;
+	if (yych == 'p') goto yy204;
 	goto yy31;
-yy197:
+yy201:
 	yych = *++p;
-	if (yych == 'D') goto yy198;
+	if (yych == 'D') goto yy202;
 	if (yych != 'd') goto yy31;
-yy198:
+yy202:
 	yych = *++p;
-	if (yych == 'A') goto yy199;
+	if (yych == 'A') goto yy203;
 	if (yych != 'a') goto yy31;
-yy199:
+yy203:
 	yych = *++p;
-	if (yych == 'T') goto yy34;
-	if (yych == 't') goto yy34;
+	if (yych == 'T') goto yy41;
+	if (yych == 't') goto yy41;
 	goto yy31;
-yy200:
+yy204:
 	yych = *++p;
 	if (yych != '.') goto yy31;
 	yych = *++p;
-	if (yych == 'B') goto yy202;
+	if (yych == 'B') goto yy206;
 	if (yych != 'b') goto yy31;
-yy202:
+yy206:
 	yych = *++p;
-	if (yych == 'E') goto yy203;
+	if (yych == 'E') goto yy207;
 	if (yych != 'e') goto yy31;
-yy203:
+yy207:
 	yych = *++p;
-	if (yych == 'E') goto yy204;
+	if (yych == 'E') goto yy208;
 	if (yych != 'e') goto yy31;
-yy204:
+yy208:
 	yych = *++p;
-	if (yych == 'P') goto yy205;
+	if (yych == 'P') goto yy209;
 	if (yych != 'p') goto yy31;
-yy205:
+yy209:
 	yych = *++p;
 	if (yych <= 'R') {
-		if (yych == ':') goto yy35;
+		if (yych == ':') goto yy42;
 		goto yy31;
 	} else {
-		if (yych <= 'S') goto yy34;
-		if (yych == 's') goto yy34;
+		if (yych <= 'S') goto yy41;
+		if (yych == 's') goto yy41;
 		goto yy31;
 	}
-yy206:
+yy210:
 	yych = *++p;
-	if (yych == 'T') goto yy207;
+	if (yych == 'T') goto yy211;
 	if (yych != 't') goto yy31;
-yy207:
+yy211:
 	yych = *++p;
-	if (yych == 'I') goto yy208;
+	if (yych == 'I') goto yy212;
 	if (yych != 'i') goto yy31;
-yy208:
+yy212:
 	yych = *++p;
-	if (yych == 'F') goto yy209;
+	if (yych == 'F') goto yy213;
 	if (yych != 'f') goto yy31;
-yy209:
+yy213:
 	yych = *++p;
-	if (yych == 'Y') goto yy34;
-	if (yych == 'y') goto yy34;
+	if (yych == 'Y') goto yy41;
+	if (yych == 'y') goto yy41;
 	goto yy31;
-yy210:
+yy214:
 	yych = *++p;
-	if (yych == 'A') goto yy211;
+	if (yych == 'A') goto yy215;
 	if (yych != 'a') goto yy31;
-yy211:
+yy215:
 	yych = *++p;
-	if (yych == 'M') goto yy34;
-	if (yych == 'm') goto yy34;
+	if (yych == 'M') goto yy41;
+	if (yych == 'm') goto yy41;
 	goto yy31;
-yy212:
+yy216:
 	yych = *++p;
 	if (yych <= 'S') {
-		if (yych == 'M') goto yy224;
+		if (yych == 'M') goto yy228;
 		if (yych <= 'R') goto yy31;
-		goto yy223;
+		goto yy227;
 	} else {
 		if (yych <= 'm') {
 			if (yych <= 'l') goto yy31;
-			goto yy224;
+			goto yy228;
 		} else {
-			if (yych == 's') goto yy223;
+			if (yych == 's') goto yy227;
 			goto yy31;
 		}
 	}
-yy213:
+yy217:
 	yych = *++p;
-	if (yych == 'Y') goto yy221;
-	if (yych == 'y') goto yy221;
+	if (yych == 'Y') goto yy225;
+	if (yych == 'y') goto yy225;
 	goto yy31;
-yy214:
+yy218:
 	yych = *++p;
-	if (yych == 'I') goto yy34;
-	if (yych == 'i') goto yy34;
+	if (yych == 'I') goto yy41;
+	if (yych == 'i') goto yy41;
 	goto yy31;
-yy215:
+yy219:
 	yych = *++p;
-	if (yych == 'S') goto yy216;
+	if (yych == 'S') goto yy220;
 	if (yych != 's') goto yy31;
-yy216:
+yy220:
 	yych = *++p;
 	if (yych <= 'N') {
-		if (yych == ':') goto yy35;
+		if (yych == ':') goto yy42;
 		goto yy31;
 	} else {
-		if (yych <= 'O') goto yy217;
+		if (yych <= 'O') goto yy221;
 		if (yych != 'o') goto yy31;
 	}
-yy217:
+yy221:
 	yych = *++p;
-	if (yych == 'U') goto yy218;
+	if (yych == 'U') goto yy222;
 	if (yych != 'u') goto yy31;
-yy218:
+yy222:
 	yych = *++p;
-	if (yych == 'R') goto yy219;
+	if (yych == 'R') goto yy223;
 	if (yych != 'r') goto yy31;
-yy219:
+yy223:
 	yych = *++p;
-	if (yych == 'C') goto yy220;
+	if (yych == 'C') goto yy224;
 	if (yych != 'c') goto yy31;
-yy220:
+yy224:
 	yych = *++p;
-	if (yych == 'E') goto yy34;
-	if (yych == 'e') goto yy34;
+	if (yych == 'E') goto yy41;
+	if (yych == 'e') goto yy41;
 	goto yy31;
-yy221:
+yy225:
 	yych = *++p;
-	if (yych == 'N') goto yy222;
+	if (yych == 'N') goto yy226;
 	if (yych != 'n') goto yy31;
-yy222:
+yy226:
 	yych = *++p;
-	if (yych == 'C') goto yy34;
-	if (yych == 'c') goto yy34;
+	if (yych == 'C') goto yy41;
+	if (yych == 'c') goto yy41;
 	goto yy31;
-yy223:
+yy227:
 	yych = *++p;
-	if (yych == 'P') goto yy34;
-	if (yych == 'p') goto yy34;
+	if (yych == 'P') goto yy41;
+	if (yych == 'p') goto yy41;
 	goto yy31;
-yy224:
+yy228:
 	yych = *++p;
-	if (yych == 'P') goto yy34;
-	if (yych == 'p') goto yy34;
+	if (yych == 'P') goto yy41;
+	if (yych == 'p') goto yy41;
 	goto yy31;
-yy225:
+yy229:
 	yych = *++p;
-	if (yych == 'Y') goto yy245;
-	if (yych == 'y') goto yy245;
+	if (yych == 'Y') goto yy249;
+	if (yych == 'y') goto yy249;
 	goto yy31;
-yy226:
+yy230:
 	yych = *++p;
 	if (yych <= 'O') {
-		if (yych == 'E') goto yy242;
+		if (yych == 'E') goto yy246;
 		if (yych <= 'N') goto yy31;
-		goto yy243;
+		goto yy247;
 	} else {
 		if (yych <= 'e') {
 			if (yych <= 'd') goto yy31;
-			goto yy242;
+			goto yy246;
 		} else {
-			if (yych == 'o') goto yy243;
+			if (yych == 'o') goto yy247;
 			goto yy31;
 		}
 	}
-yy227:
+yy231:
 	yych = *++p;
-	if (yych == 'A') goto yy237;
-	if (yych == 'a') goto yy237;
+	if (yych == 'A') goto yy241;
+	if (yych == 'a') goto yy241;
 	goto yy31;
-yy228:
+yy232:
 	yych = *++p;
 	if (yych <= 'P') {
-		if (yych == 'L') goto yy230;
+		if (yych == 'L') goto yy234;
 		if (yych <= 'O') goto yy31;
-		goto yy231;
+		goto yy235;
 	} else {
 		if (yych <= 'l') {
 			if (yych <= 'k') goto yy31;
-			goto yy230;
+			goto yy234;
 		} else {
-			if (yych == 'p') goto yy231;
+			if (yych == 'p') goto yy235;
 			goto yy31;
 		}
 	}
-yy229:
-	yych = *++p;
-	if (yych == 'P') goto yy34;
-	if (yych == 'p') goto yy34;
-	goto yy31;
-yy230:
-	yych = *++p;
-	if (yych == 'M') goto yy34;
-	if (yych == 'm') goto yy34;
-	goto yy31;
-yy231:
-	yych = *++p;
-	if (yych == 'A') goto yy232;
-	if (yych != 'a') goto yy31;
-yy232:
-	yych = *++p;
-	if (yych == 'R') goto yy233;
-	if (yych != 'r') goto yy31;
 yy233:
 	yych = *++p;
-	if (yych == 'A') goto yy234;
-	if (yych != 'a') goto yy31;
+	if (yych == 'P') goto yy41;
+	if (yych == 'p') goto yy41;
+	goto yy31;
 yy234:
 	yych = *++p;
-	if (yych == 'Z') goto yy235;
-	if (yych != 'z') goto yy31;
+	if (yych == 'M') goto yy41;
+	if (yych == 'm') goto yy41;
+	goto yy31;
 yy235:
 	yych = *++p;
-	if (yych == 'Z') goto yy236;
-	if (yych != 'z') goto yy31;
+	if (yych == 'A') goto yy236;
+	if (yych != 'a') goto yy31;
 yy236:
 	yych = *++p;
-	if (yych == 'I') goto yy34;
-	if (yych == 'i') goto yy34;
-	goto yy31;
+	if (yych == 'R') goto yy237;
+	if (yych != 'r') goto yy31;
 yy237:
 	yych = *++p;
-	if (yych == 'T') goto yy238;
-	if (yych != 't') goto yy31;
+	if (yych == 'A') goto yy238;
+	if (yych != 'a') goto yy31;
 yy238:
 	yych = *++p;
-	if (yych == 'F') goto yy239;
-	if (yych != 'f') goto yy31;
+	if (yych == 'Z') goto yy239;
+	if (yych != 'z') goto yy31;
 yy239:
 	yych = *++p;
-	if (yych == 'O') goto yy240;
-	if (yych != 'o') goto yy31;
+	if (yych == 'Z') goto yy240;
+	if (yych != 'z') goto yy31;
 yy240:
 	yych = *++p;
-	if (yych == 'R') goto yy241;
-	if (yych != 'r') goto yy31;
+	if (yych == 'I') goto yy41;
+	if (yych == 'i') goto yy41;
+	goto yy31;
 yy241:
 	yych = *++p;
-	if (yych == 'M') goto yy34;
-	if (yych == 'm') goto yy34;
-	goto yy31;
+	if (yych == 'T') goto yy242;
+	if (yych != 't') goto yy31;
 yy242:
 	yych = *++p;
-	if (yych == 'S') goto yy34;
-	if (yych == 's') goto yy34;
-	goto yy31;
+	if (yych == 'F') goto yy243;
+	if (yych != 'f') goto yy31;
 yy243:
 	yych = *++p;
-	if (yych == 'X') goto yy244;
-	if (yych != 'x') goto yy31;
+	if (yych == 'O') goto yy244;
+	if (yych != 'o') goto yy31;
 yy244:
 	yych = *++p;
-	if (yych == 'Y') goto yy34;
-	if (yych == 'y') goto yy34;
-	goto yy31;
+	if (yych == 'R') goto yy245;
+	if (yych != 'r') goto yy31;
 yy245:
 	yych = *++p;
-	if (yych == 'C') goto yy34;
-	if (yych == 'c') goto yy34;
+	if (yych == 'M') goto yy41;
+	if (yych == 'm') goto yy41;
 	goto yy31;
 yy246:
 	yych = *++p;
-	if (yych == 'D') goto yy34;
-	if (yych == 'd') goto yy34;
+	if (yych == 'S') goto yy41;
+	if (yych == 's') goto yy41;
 	goto yy31;
 yy247:
 	yych = *++p;
-	if (yych == 'A') goto yy248;
-	if (yych != 'a') goto yy31;
+	if (yych == 'X') goto yy248;
+	if (yych != 'x') goto yy31;
 yy248:
 	yych = *++p;
-	if (yych == 'Q') goto yy249;
-	if (yych != 'q') goto yy31;
+	if (yych == 'Y') goto yy41;
+	if (yych == 'y') goto yy41;
+	goto yy31;
 yy249:
 	yych = *++p;
-	if (yych == 'U') goto yy250;
-	if (yych != 'u') goto yy31;
+	if (yych == 'C') goto yy41;
+	if (yych == 'c') goto yy41;
+	goto yy31;
 yy250:
 	yych = *++p;
-	if (yych == 'E') goto yy251;
-	if (yych != 'e') goto yy31;
+	if (yych == 'D') goto yy41;
+	if (yych == 'd') goto yy41;
+	goto yy31;
 yy251:
 	yych = *++p;
-	if (yych == 'L') goto yy252;
-	if (yych != 'l') goto yy31;
+	if (yych == 'A') goto yy252;
+	if (yych != 'a') goto yy31;
 yy252:
 	yych = *++p;
-	if (yych == 'O') goto yy253;
-	if (yych != 'o') goto yy31;
+	if (yych == 'Q') goto yy253;
+	if (yych != 'q') goto yy31;
 yy253:
 	yych = *++p;
-	if (yych == 'C') goto yy254;
-	if (yych != 'c') goto yy31;
+	if (yych == 'U') goto yy254;
+	if (yych != 'u') goto yy31;
 yy254:
 	yych = *++p;
-	if (yych == 'K') goto yy255;
-	if (yych != 'k') goto yy31;
+	if (yych == 'E') goto yy255;
+	if (yych != 'e') goto yy31;
 yy255:
 	yych = *++p;
-	if (yych == 'T') goto yy256;
-	if (yych != 't') goto yy31;
+	if (yych == 'L') goto yy256;
+	if (yych != 'l') goto yy31;
 yy256:
 	yych = *++p;
 	if (yych == 'O') goto yy257;
 	if (yych != 'o') goto yy31;
 yy257:
 	yych = *++p;
-	if (yych == 'K') goto yy258;
-	if (yych != 'k') goto yy31;
+	if (yych == 'C') goto yy258;
+	if (yych != 'c') goto yy31;
 yy258:
 	yych = *++p;
-	if (yych == 'E') goto yy259;
-	if (yych != 'e') goto yy31;
+	if (yych == 'K') goto yy259;
+	if (yych != 'k') goto yy31;
 yy259:
 	yych = *++p;
-	if (yych == 'N') goto yy34;
-	if (yych == 'n') goto yy34;
-	goto yy31;
+	if (yych == 'T') goto yy260;
+	if (yych != 't') goto yy31;
 yy260:
 	yych = *++p;
-	if (yych == 'T') goto yy267;
-	if (yych == 't') goto yy267;
-	goto yy31;
+	if (yych == 'O') goto yy261;
+	if (yych != 'o') goto yy31;
 yy261:
 	yych = *++p;
-	if (yych == 'T') goto yy266;
-	if (yych == 't') goto yy266;
-	goto yy31;
+	if (yych == 'K') goto yy262;
+	if (yych != 'k') goto yy31;
 yy262:
 	yych = *++p;
+	if (yych == 'E') goto yy263;
+	if (yych != 'e') goto yy31;
+yy263:
+	yych = *++p;
+	if (yych == 'N') goto yy41;
+	if (yych == 'n') goto yy41;
+	goto yy31;
+yy264:
+	yych = *++p;
+	if (yych == 'T') goto yy271;
+	if (yych == 't') goto yy271;
+	goto yy31;
+yy265:
+	yych = *++p;
+	if (yych == 'T') goto yy270;
+	if (yych == 't') goto yy270;
+	goto yy31;
+yy266:
+	yych = *++p;
 	if (yych <= 'G') {
-		if (yych == ':') goto yy35;
+		if (yych == ':') goto yy42;
 		goto yy31;
 	} else {
-		if (yych <= 'H') goto yy34;
-		if (yych == 'h') goto yy34;
+		if (yych <= 'H') goto yy41;
+		if (yych == 'h') goto yy41;
 		goto yy31;
 	}
-yy263:
+yy267:
 	yych = *++p;
-	if (yych == 'S') goto yy34;
-	if (yych == 's') goto yy34;
+	if (yych == 'S') goto yy41;
+	if (yych == 's') goto yy41;
 	goto yy31;
-yy264:
+yy268:
 	yych = *++p;
-	if (yych == 'W') goto yy265;
+	if (yych == 'W') goto yy269;
 	if (yych != 'w') goto yy31;
-yy265:
+yy269:
 	yych = *++p;
-	if (yych == 'S') goto yy34;
-	if (yych == 's') goto yy34;
+	if (yych == 'S') goto yy41;
+	if (yych == 's') goto yy41;
 	goto yy31;
-yy266:
+yy270:
 	yych = *++p;
-	if (yych == 'P') goto yy34;
-	if (yych == 'p') goto yy34;
+	if (yych == 'P') goto yy41;
+	if (yych == 'p') goto yy41;
 	goto yy31;
-yy267:
+yy271:
 	yych = *++p;
-	if (yych == 'E') goto yy268;
+	if (yych == 'E') goto yy272;
 	if (yych != 'e') goto yy31;
-yy268:
+yy272:
 	yych = *++p;
-	if (yych == 'S') goto yy34;
-	if (yych == 's') goto yy34;
+	if (yych == 'S') goto yy41;
+	if (yych == 's') goto yy41;
 	goto yy31;
-yy269:
+yy273:
 	yych = *++p;
-	if (yych == 'N') goto yy34;
-	if (yych == 'n') goto yy34;
+	if (yych == 'N') goto yy41;
+	if (yych == 'n') goto yy41;
 	goto yy31;
-yy270:
+yy274:
 	yych = *++p;
 	if (yych <= 'P') {
-		if (yych == 'M') goto yy301;
+		if (yych == 'M') goto yy305;
 		if (yych <= 'O') goto yy31;
-		goto yy300;
+		goto yy304;
 	} else {
 		if (yych <= 'm') {
 			if (yych <= 'l') goto yy31;
-			goto yy301;
+			goto yy305;
 		} else {
-			if (yych == 'p') goto yy300;
+			if (yych == 'p') goto yy304;
 			goto yy31;
 		}
 	}
-yy271:
+yy275:
 	yych = *++p;
 	if (yych <= 'Q') {
 		if (yych <= '-') {
 			if (yych <= ',') goto yy31;
-			goto yy293;
+			goto yy297;
 		} else {
-			if (yych == 'N') goto yy294;
+			if (yych == 'N') goto yy298;
 			goto yy31;
 		}
 	} else {
 		if (yych <= 'n') {
-			if (yych <= 'R') goto yy292;
+			if (yych <= 'R') goto yy296;
 			if (yych <= 'm') goto yy31;
-			goto yy294;
+			goto yy298;
 		} else {
-			if (yych == 'r') goto yy292;
+			if (yych == 'r') goto yy296;
 			goto yy31;
 		}
 	}
-yy272:
+yy276:
 	yych = *++p;
-	if (yych == 'S') goto yy34;
-	if (yych == 's') goto yy34;
+	if (yych == 'S') goto yy41;
+	if (yych == 's') goto yy41;
 	goto yy31;
-yy273:
+yy277:
 	yych = *++p;
-	if (yych == 'S') goto yy288;
-	if (yych == 's') goto yy288;
+	if (yych == 'S') goto yy292;
+	if (yych == 's') goto yy292;
 	goto yy31;
-yy274:
+yy278:
 	yych = *++p;
 	switch (yych) {
 	case 'G':
-	case 'g':	goto yy279;
+	case 'g':	goto yy283;
 	case 'I':
-	case 'i':	goto yy278;
+	case 'i':	goto yy282;
 	case 'P':
-	case 'p':	goto yy280;
+	case 'p':	goto yy284;
 	case 'R':
-	case 'r':	goto yy281;
+	case 'r':	goto yy285;
 	default:	goto yy31;
 	}
-yy275:
+yy279:
 	yych = *++p;
-	if (yych == 'Q') goto yy277;
-	if (yych == 'q') goto yy277;
+	if (yych == 'Q') goto yy281;
+	if (yych == 'q') goto yy281;
 	goto yy31;
-yy276:
+yy280:
 	yych = *++p;
-	if (yych == 'D') goto yy34;
-	if (yych == 'd') goto yy34;
+	if (yych == 'D') goto yy41;
+	if (yych == 'd') goto yy41;
 	goto yy31;
-yy277:
+yy281:
 	yych = *++p;
-	if (yych == 'P') goto yy34;
-	if (yych == 'p') goto yy34;
+	if (yych == 'P') goto yy41;
+	if (yych == 'p') goto yy41;
 	goto yy31;
-yy278:
+yy282:
 	yych = *++p;
-	if (yych == 'L') goto yy286;
-	if (yych == 'l') goto yy286;
+	if (yych == 'L') goto yy290;
+	if (yych == 'l') goto yy290;
 	goto yy31;
-yy279:
+yy283:
 	yych = *++p;
-	if (yych == 'N') goto yy284;
-	if (yych == 'n') goto yy284;
+	if (yych == 'N') goto yy288;
+	if (yych == 'n') goto yy288;
 	goto yy31;
-yy280:
+yy284:
 	yych = *++p;
-	if (yych == 'S') goto yy34;
-	if (yych == 's') goto yy34;
+	if (yych == 'S') goto yy41;
+	if (yych == 's') goto yy41;
 	goto yy31;
-yy281:
+yy285:
 	yych = *++p;
-	if (yych == 'K') goto yy282;
+	if (yych == 'K') goto yy286;
 	if (yych != 'k') goto yy31;
-yy282:
+yy286:
 	yych = *++p;
-	if (yych == 'E') goto yy283;
+	if (yych == 'E') goto yy287;
 	if (yych != 'e') goto yy31;
-yy283:
+yy287:
 	yych = *++p;
-	if (yych == 'T') goto yy34;
-	if (yych == 't') goto yy34;
+	if (yych == 'T') goto yy41;
+	if (yych == 't') goto yy41;
 	goto yy31;
-yy284:
+yy288:
 	yych = *++p;
-	if (yych == 'E') goto yy285;
+	if (yych == 'E') goto yy289;
 	if (yych != 'e') goto yy31;
-yy285:
+yy289:
 	yych = *++p;
-	if (yych == 'T') goto yy34;
-	if (yych == 't') goto yy34;
+	if (yych == 'T') goto yy41;
+	if (yych == 't') goto yy41;
 	goto yy31;
-yy286:
+yy290:
 	yych = *++p;
-	if (yych == 'T') goto yy287;
+	if (yych == 'T') goto yy291;
 	if (yych != 't') goto yy31;
-yy287:
+yy291:
 	yych = *++p;
-	if (yych == 'O') goto yy34;
-	if (yych == 'o') goto yy34;
+	if (yych == 'O') goto yy41;
+	if (yych == 'o') goto yy41;
 	goto yy31;
-yy288:
+yy292:
 	yych = *++p;
-	if (yych == 'S') goto yy289;
+	if (yych == 'S') goto yy293;
 	if (yych != 's') goto yy31;
-yy289:
+yy293:
 	yych = *++p;
-	if (yych == 'A') goto yy290;
+	if (yych == 'A') goto yy294;
 	if (yych != 'a') goto yy31;
-yy290:
+yy294:
 	yych = *++p;
-	if (yych == 'G') goto yy291;
+	if (yych == 'G') goto yy295;
 	if (yych != 'g') goto yy31;
-yy291:
+yy295:
 	yych = *++p;
-	if (yych == 'E') goto yy34;
-	if (yych == 'e') goto yy34;
+	if (yych == 'E') goto yy41;
+	if (yych == 'e') goto yy41;
 	goto yy31;
-yy292:
+yy296:
 	yych = *++p;
-	if (yych == 'P') goto yy299;
-	if (yych == 'p') goto yy299;
+	if (yych == 'P') goto yy303;
+	if (yych == 'p') goto yy303;
 	goto yy31;
-yy293:
+yy297:
 	yych = *++p;
-	if (yych == 'H') goto yy296;
-	if (yych == 'h') goto yy296;
+	if (yych == 'H') goto yy300;
+	if (yych == 'h') goto yy300;
 	goto yy31;
-yy294:
+yy298:
 	yych = *++p;
-	if (yych == 'I') goto yy295;
+	if (yych == 'I') goto yy299;
 	if (yych != 'i') goto yy31;
-yy295:
+yy299:
 	yych = *++p;
-	if (yych == 'M') goto yy34;
-	if (yych == 'm') goto yy34;
+	if (yych == 'M') goto yy41;
+	if (yych == 'm') goto yy41;
 	goto yy31;
-yy296:
+yy300:
 	yych = *++p;
-	if (yych == 'E') goto yy297;
+	if (yych == 'E') goto yy301;
 	if (yych != 'e') goto yy31;
-yy297:
+yy301:
 	yych = *++p;
-	if (yych == 'L') goto yy298;
+	if (yych == 'L') goto yy302;
 	if (yych != 'l') goto yy31;
-yy298:
+yy302:
 	yych = *++p;
-	if (yych == 'P') goto yy34;
-	if (yych == 'p') goto yy34;
+	if (yych == 'P') goto yy41;
+	if (yych == 'p') goto yy41;
 	goto yy31;
-yy299:
+yy303:
 	yych = *++p;
 	if (yych <= 'R') {
-		if (yych == ':') goto yy35;
+		if (yych == ':') goto yy42;
 		goto yy31;
 	} else {
-		if (yych <= 'S') goto yy34;
-		if (yych == 's') goto yy34;
+		if (yych <= 'S') goto yy41;
+		if (yych == 's') goto yy41;
 		goto yy31;
 	}
-yy300:
+yy304:
 	yych = *++p;
-	if (yych == 'D') goto yy304;
-	if (yych == 'd') goto yy304;
+	if (yych == 'D') goto yy308;
+	if (yych == 'd') goto yy308;
 	goto yy31;
-yy301:
+yy305:
 	yych = *++p;
-	if (yych == 'B') goto yy302;
+	if (yych == 'B') goto yy306;
 	if (yych != 'b') goto yy31;
-yy302:
+yy306:
 	yych = *++p;
-	if (yych == 'L') goto yy303;
+	if (yych == 'L') goto yy307;
 	if (yych != 'l') goto yy31;
-yy303:
+yy307:
 	yych = *++p;
-	if (yych == 'E') goto yy34;
-	if (yych == 'e') goto yy34;
+	if (yych == 'E') goto yy41;
+	if (yych == 'e') goto yy41;
 	goto yy31;
-yy304:
+yy308:
 	yych = *++p;
-	if (yych == 'A') goto yy305;
+	if (yych == 'A') goto yy309;
 	if (yych != 'a') goto yy31;
-yy305:
+yy309:
 	yych = *++p;
-	if (yych == 'T') goto yy306;
+	if (yych == 'T') goto yy310;
 	if (yych != 't') goto yy31;
-yy306:
+yy310:
 	yych = *++p;
-	if (yych == 'E') goto yy34;
-	if (yych == 'e') goto yy34;
+	if (yych == 'E') goto yy41;
+	if (yych == 'e') goto yy41;
 	goto yy31;
-yy307:
+yy311:
 	yych = *++p;
-	if (yych == 'A') goto yy312;
-	if (yych == 'a') goto yy312;
+	if (yych == 'A') goto yy316;
+	if (yych == 'a') goto yy316;
 	goto yy31;
-yy308:
+yy312:
 	yych = *++p;
-	if (yych == 'S') goto yy309;
+	if (yych == 'S') goto yy313;
 	if (yych != 's') goto yy31;
-yy309:
+yy313:
 	yych = *++p;
-	if (yych == 'T') goto yy310;
+	if (yych == 'T') goto yy314;
 	if (yych != 't') goto yy31;
-yy310:
+yy314:
 	yych = *++p;
-	if (yych == 'F') goto yy311;
+	if (yych == 'F') goto yy315;
 	if (yych != 'f') goto yy31;
-yy311:
+yy315:
 	yych = *++p;
-	if (yych == 'M') goto yy34;
-	if (yych == 'm') goto yy34;
+	if (yych == 'M') goto yy41;
+	if (yych == 'm') goto yy41;
 	goto yy31;
-yy312:
+yy316:
 	yych = *++p;
-	if (yych == 'P') goto yy313;
+	if (yych == 'P') goto yy317;
 	if (yych != 'p') goto yy31;
-yy313:
+yy317:
 	yych = *++p;
 	if (yych <= 'R') {
-		if (yych == ':') goto yy35;
+		if (yych == ':') goto yy42;
 		goto yy31;
 	} else {
-		if (yych <= 'S') goto yy34;
-		if (yych == 's') goto yy34;
+		if (yych <= 'S') goto yy41;
+		if (yych == 's') goto yy41;
 		goto yy31;
 	}
-yy314:
+yy318:
 	yych = *++p;
-	if (yych == 'M') goto yy337;
-	if (yych == 'm') goto yy337;
+	if (yych == 'M') goto yy341;
+	if (yych == 'm') goto yy341;
 	goto yy31;
-yy315:
+yy319:
 	yych = *++p;
 	if (yych <= 'I') {
-		if (yych == 'C') goto yy326;
+		if (yych == 'C') goto yy330;
 		if (yych <= 'H') goto yy31;
-		goto yy325;
+		goto yy329;
 	} else {
 		if (yych <= 'c') {
 			if (yych <= 'b') goto yy31;
-			goto yy326;
+			goto yy330;
 		} else {
-			if (yych == 'i') goto yy325;
+			if (yych == 'i') goto yy329;
 			goto yy31;
 		}
 	}
-yy316:
+yy320:
 	yych = *++p;
 	if (yych <= 'P') {
-		if (yych == 'N') goto yy34;
+		if (yych == 'N') goto yy41;
 		if (yych <= 'O') goto yy31;
-		goto yy34;
+		goto yy41;
 	} else {
 		if (yych <= 'n') {
 			if (yych <= 'm') goto yy31;
-			goto yy34;
+			goto yy41;
 		} else {
-			if (yych == 'p') goto yy34;
+			if (yych == 'p') goto yy41;
 			goto yy31;
 		}
 	}
-yy317:
+yy321:
 	yych = *++p;
 	if (yych <= 'O') {
-		if (yych == 'A') goto yy323;
+		if (yych == 'A') goto yy327;
 		if (yych <= 'N') goto yy31;
-		goto yy324;
+		goto yy328;
 	} else {
 		if (yych <= 'a') {
 			if (yych <= '`') goto yy31;
-			goto yy323;
+			goto yy327;
 		} else {
-			if (yych == 'o') goto yy324;
+			if (yych == 'o') goto yy328;
 			goto yy31;
 		}
 	}
-yy318:
+yy322:
 	yych = *++p;
-	if (yych == 'F') goto yy322;
-	if (yych == 'f') goto yy322;
+	if (yych == 'F') goto yy326;
+	if (yych == 'f') goto yy326;
 	goto yy31;
-yy319:
+yy323:
 	yych = *++p;
 	if (yych <= '@') {
-		if (yych == ':') goto yy35;
+		if (yych == ':') goto yy42;
 		goto yy31;
 	} else {
-		if (yych <= 'A') goto yy321;
-		if (yych == 'a') goto yy321;
+		if (yych <= 'A') goto yy325;
+		if (yych == 'a') goto yy325;
 		goto yy31;
 	}
-yy320:
+yy324:
 	yych = *++p;
-	if (yych == 'X') goto yy34;
-	if (yych == 'x') goto yy34;
+	if (yych == 'X') goto yy41;
+	if (yych == 'x') goto yy41;
 	goto yy31;
-yy321:
+yy325:
 	yych = *++p;
-	if (yych == 'P') goto yy34;
-	if (yych == 'p') goto yy34;
+	if (yych == 'P') goto yy41;
+	if (yych == 'p') goto yy41;
 	goto yy31;
-yy322:
+yy326:
 	yych = *++p;
-	if (yych == 'O') goto yy34;
-	if (yych == 'o') goto yy34;
+	if (yych == 'O') goto yy41;
+	if (yych == 'o') goto yy41;
 	goto yy31;
-yy323:
+yy327:
 	yych = *++p;
-	if (yych == 'P') goto yy34;
-	if (yych == 'p') goto yy34;
+	if (yych == 'P') goto yy41;
+	if (yych == 'p') goto yy41;
 	goto yy31;
-yy324:
+yy328:
 	yych = *++p;
-	if (yych == 'N') goto yy34;
-	if (yych == 'n') goto yy34;
+	if (yych == 'N') goto yy41;
+	if (yych == 'n') goto yy41;
 	goto yy31;
-yy325:
+yy329:
 	yych = *++p;
-	if (yych == 'S') goto yy327;
-	if (yych == 's') goto yy327;
+	if (yych == 'S') goto yy331;
+	if (yych == 's') goto yy331;
 	goto yy31;
-yy326:
+yy330:
 	yych = *++p;
 	if (yych <= ':') {
-		if (yych == '6') goto yy34;
+		if (yych == '6') goto yy41;
 		if (yych <= '9') goto yy31;
-		goto yy35;
+		goto yy42;
 	} else {
 		if (yych <= 'S') {
 			if (yych <= 'R') goto yy31;
-			goto yy34;
+			goto yy41;
 		} else {
-			if (yych == 's') goto yy34;
+			if (yych == 's') goto yy41;
 			goto yy31;
 		}
 	}
-yy327:
+yy331:
 	yych = *++p;
-	if (yych == '.') goto yy328;
-	if (yych == ':') goto yy35;
+	if (yych == '.') goto yy332;
+	if (yych == ':') goto yy42;
 	goto yy31;
-yy328:
+yy332:
 	yych = *++p;
 	if (yych <= 'X') {
 		if (yych <= 'K') {
-			if (yych == 'B') goto yy331;
+			if (yych == 'B') goto yy335;
 			goto yy31;
 		} else {
-			if (yych <= 'L') goto yy329;
+			if (yych <= 'L') goto yy333;
 			if (yych <= 'W') goto yy31;
-			goto yy330;
+			goto yy334;
 		}
 	} else {
 		if (yych <= 'k') {
-			if (yych == 'b') goto yy331;
+			if (yych == 'b') goto yy335;
 			goto yy31;
 		} else {
-			if (yych <= 'l') goto yy329;
-			if (yych == 'x') goto yy330;
+			if (yych <= 'l') goto yy333;
+			if (yych == 'x') goto yy334;
 			goto yy31;
 		}
 	}
-yy329:
+yy333:
 	yych = *++p;
-	if (yych == 'W') goto yy336;
-	if (yych == 'w') goto yy336;
+	if (yych == 'W') goto yy340;
+	if (yych == 'w') goto yy340;
 	goto yy31;
-yy330:
+yy334:
 	yych = *++p;
-	if (yych == 'P') goto yy334;
-	if (yych == 'p') goto yy334;
+	if (yych == 'P') goto yy338;
+	if (yych == 'p') goto yy338;
 	goto yy31;
-yy331:
+yy335:
 	yych = *++p;
-	if (yych == 'E') goto yy332;
+	if (yych == 'E') goto yy336;
 	if (yych != 'e') goto yy31;
-yy332:
+yy336:
 	yych = *++p;
-	if (yych == 'E') goto yy333;
+	if (yych == 'E') goto yy337;
 	if (yych != 'e') goto yy31;
-yy333:
+yy337:
 	yych = *++p;
-	if (yych == 'P') goto yy34;
-	if (yych == 'p') goto yy34;
+	if (yych == 'P') goto yy41;
+	if (yych == 'p') goto yy41;
 	goto yy31;
-yy334:
+yy338:
 	yych = *++p;
-	if (yych == 'C') goto yy335;
+	if (yych == 'C') goto yy339;
 	if (yych != 'c') goto yy31;
-yy335:
+yy339:
 	yych = *++p;
 	if (yych <= 'R') {
-		if (yych == ':') goto yy35;
+		if (yych == ':') goto yy42;
 		goto yy31;
 	} else {
-		if (yych <= 'S') goto yy34;
-		if (yych == 's') goto yy34;
+		if (yych <= 'S') goto yy41;
+		if (yych == 's') goto yy41;
 		goto yy31;
 	}
-yy336:
+yy340:
 	yych = *++p;
-	if (yych == 'Z') goto yy34;
-	if (yych == 'z') goto yy34;
+	if (yych == 'Z') goto yy41;
+	if (yych == 'z') goto yy41;
 	goto yy31;
-yy337:
+yy341:
 	yych = *++p;
-	if (yych == 'S') goto yy34;
-	if (yych == 's') goto yy34;
+	if (yych == 'S') goto yy41;
+	if (yych == 's') goto yy41;
 	goto yy31;
-yy338:
+yy342:
 	yych = *++p;
-	if (yych == 'P') goto yy34;
-	if (yych == 'p') goto yy34;
+	if (yych == 'P') goto yy41;
+	if (yych == 'p') goto yy41;
 	goto yy31;
-yy339:
+yy343:
 	yych = *++p;
-	if (yych == 'T') goto yy342;
-	if (yych == 't') goto yy342;
+	if (yych == 'T') goto yy346;
+	if (yych == 't') goto yy346;
 	goto yy31;
-yy340:
+yy344:
 	yych = *++p;
 	if (yych != '2') goto yy31;
 	yych = *++p;
-	if (yych == '3') goto yy34;
+	if (yych == '3') goto yy41;
 	goto yy31;
-yy342:
+yy346:
 	yych = *++p;
-	if (yych == 'P') goto yy343;
+	if (yych == 'P') goto yy347;
 	if (yych != 'p') goto yy31;
-yy343:
+yy347:
 	yych = *++p;
 	if (yych <= 'R') {
-		if (yych == ':') goto yy35;
+		if (yych == ':') goto yy42;
 		goto yy31;
 	} else {
-		if (yych <= 'S') goto yy34;
-		if (yych == 's') goto yy34;
+		if (yych <= 'S') goto yy41;
+		if (yych == 's') goto yy41;
 		goto yy31;
 	}
-yy344:
+yy348:
 	yych = *++p;
-	if (yych == 'A') goto yy360;
-	if (yych == 'a') goto yy360;
+	if (yych == 'A') goto yy364;
+	if (yych == 'a') goto yy364;
 	goto yy31;
-yy345:
+yy349:
 	yych = *++p;
 	if (yych <= 'Z') {
-		if (yych == 'T') goto yy34;
+		if (yych == 'T') goto yy41;
 		if (yych <= 'Y') goto yy31;
-		goto yy351;
+		goto yy355;
 	} else {
 		if (yych <= 't') {
 			if (yych <= 's') goto yy31;
-			goto yy34;
+			goto yy41;
 		} else {
-			if (yych == 'z') goto yy351;
+			if (yych == 'z') goto yy355;
 			goto yy31;
 		}
 	}
-yy346:
+yy350:
 	yych = *++p;
 	if (yych <= 'O') {
-		if (yych == ':') goto yy35;
+		if (yych == ':') goto yy42;
 		goto yy31;
 	} else {
-		if (yych <= 'P') goto yy348;
-		if (yych == 'p') goto yy348;
+		if (yych <= 'P') goto yy352;
+		if (yych == 'p') goto yy352;
 		goto yy31;
 	}
-yy347:
+yy351:
 	yych = *++p;
-	if (yych == 'O') goto yy34;
-	if (yych == 'o') goto yy34;
+	if (yych == 'O') goto yy41;
+	if (yych == 'o') goto yy41;
 	goto yy31;
-yy348:
+yy352:
 	yych = *++p;
-	if (yych == 'H') goto yy349;
+	if (yych == 'H') goto yy353;
 	if (yych != 'h') goto yy31;
-yy349:
+yy353:
 	yych = *++p;
-	if (yych == 'E') goto yy350;
+	if (yych == 'E') goto yy354;
 	if (yych != 'e') goto yy31;
-yy350:
+yy354:
 	yych = *++p;
-	if (yych == 'R') goto yy34;
-	if (yych == 'r') goto yy34;
+	if (yych == 'R') goto yy41;
+	if (yych == 'r') goto yy41;
 	goto yy31;
-yy351:
+yy355:
 	yych = *++p;
-	if (yych == 'M') goto yy352;
+	if (yych == 'M') goto yy356;
 	if (yych != 'm') goto yy31;
-yy352:
+yy356:
 	yych = *++p;
-	if (yych == 'O') goto yy353;
+	if (yych == 'O') goto yy357;
 	if (yych != 'o') goto yy31;
-yy353:
+yy357:
 	yych = *++p;
-	if (yych == 'P') goto yy354;
+	if (yych == 'P') goto yy358;
 	if (yych != 'p') goto yy31;
-yy354:
+yy358:
 	yych = *++p;
-	if (yych == 'R') goto yy355;
+	if (yych == 'R') goto yy359;
 	if (yych != 'r') goto yy31;
-yy355:
+yy359:
 	yych = *++p;
-	if (yych == 'O') goto yy356;
+	if (yych == 'O') goto yy360;
 	if (yych != 'o') goto yy31;
-yy356:
+yy360:
 	yych = *++p;
-	if (yych == 'J') goto yy357;
+	if (yych == 'J') goto yy361;
 	if (yych != 'j') goto yy31;
-yy357:
+yy361:
 	yych = *++p;
-	if (yych == 'E') goto yy358;
+	if (yych == 'E') goto yy362;
 	if (yych != 'e') goto yy31;
-yy358:
+yy362:
 	yych = *++p;
-	if (yych == 'C') goto yy359;
+	if (yych == 'C') goto yy363;
 	if (yych != 'c') goto yy31;
-yy359:
+yy363:
 	yych = *++p;
-	if (yych == 'T') goto yy34;
-	if (yych == 't') goto yy34;
+	if (yych == 'T') goto yy41;
+	if (yych == 't') goto yy41;
 	goto yy31;
-yy360:
+yy364:
 	yych = *++p;
-	if (yych == 'L') goto yy361;
+	if (yych == 'L') goto yy365;
 	if (yych != 'l') goto yy31;
-yy361:
+yy365:
 	yych = *++p;
-	if (yych == 'K') goto yy34;
-	if (yych == 'k') goto yy34;
+	if (yych == 'K') goto yy41;
+	if (yych == 'k') goto yy41;
 	goto yy31;
-yy362:
+yy366:
 	yych = *++p;
 	if (yych <= 'S') {
 		if (yych <= 'M') {
-			if (yych == 'L') goto yy372;
+			if (yych == 'L') goto yy376;
 			goto yy31;
 		} else {
-			if (yych <= 'N') goto yy373;
+			if (yych <= 'N') goto yy377;
 			if (yych <= 'R') goto yy31;
-			goto yy374;
+			goto yy378;
 		}
 	} else {
 		if (yych <= 'm') {
-			if (yych == 'l') goto yy372;
+			if (yych == 'l') goto yy376;
 			goto yy31;
 		} else {
-			if (yych <= 'n') goto yy373;
-			if (yych == 's') goto yy374;
+			if (yych <= 'n') goto yy377;
+			if (yych == 's') goto yy378;
 			goto yy31;
 		}
 	}
-yy363:
-	yych = *++p;
-	if (yych == 'E') goto yy371;
-	if (yych == 'e') goto yy371;
-	goto yy31;
-yy364:
-	yych = *++p;
-	if (yych == 'C') goto yy366;
-	if (yych == 'c') goto yy366;
-	goto yy31;
-yy365:
-	yych = *++p;
-	if (yych == 'P') goto yy34;
-	if (yych == 'p') goto yy34;
-	goto yy31;
-yy366:
-	yych = *++p;
-	if (yych == 'E') goto yy367;
-	if (yych != 'e') goto yy31;
 yy367:
 	yych = *++p;
-	if (yych == 'T') goto yy368;
-	if (yych != 't') goto yy31;
+	if (yych == 'E') goto yy375;
+	if (yych == 'e') goto yy375;
+	goto yy31;
 yy368:
 	yych = *++p;
-	if (yych == 'I') goto yy369;
-	if (yych != 'i') goto yy31;
+	if (yych == 'C') goto yy370;
+	if (yych == 'c') goto yy370;
+	goto yy31;
 yy369:
 	yych = *++p;
-	if (yych == 'M') goto yy370;
-	if (yych != 'm') goto yy31;
+	if (yych == 'P') goto yy41;
+	if (yych == 'p') goto yy41;
+	goto yy31;
 yy370:
 	yych = *++p;
-	if (yych == 'E') goto yy34;
-	if (yych == 'e') goto yy34;
-	goto yy31;
+	if (yych == 'E') goto yy371;
+	if (yych != 'e') goto yy31;
 yy371:
 	yych = *++p;
-	if (yych == 'D') goto yy34;
-	if (yych == 'd') goto yy34;
-	goto yy31;
+	if (yych == 'T') goto yy372;
+	if (yych != 't') goto yy31;
 yy372:
 	yych = *++p;
-	if (yych == 'E') goto yy34;
-	if (yych == 'e') goto yy34;
-	goto yy31;
+	if (yych == 'I') goto yy373;
+	if (yych != 'i') goto yy31;
 yy373:
 	yych = *++p;
-	if (yych == 'G') goto yy375;
-	if (yych == 'g') goto yy375;
-	goto yy31;
+	if (yych == 'M') goto yy374;
+	if (yych != 'm') goto yy31;
 yy374:
 	yych = *++p;
-	if (yych == 'H') goto yy34;
-	if (yych == 'h') goto yy34;
+	if (yych == 'E') goto yy41;
+	if (yych == 'e') goto yy41;
 	goto yy31;
 yy375:
 	yych = *++p;
-	if (yych == 'E') goto yy376;
-	if (yych != 'e') goto yy31;
+	if (yych == 'D') goto yy41;
+	if (yych == 'd') goto yy41;
+	goto yy31;
 yy376:
 	yych = *++p;
-	if (yych == 'R') goto yy34;
-	if (yych == 'r') goto yy34;
+	if (yych == 'E') goto yy41;
+	if (yych == 'e') goto yy41;
 	goto yy31;
 yy377:
 	yych = *++p;
-	if (yych == 'T') goto yy395;
-	if (yych == 't') goto yy395;
+	if (yych == 'G') goto yy379;
+	if (yych == 'g') goto yy379;
 	goto yy31;
 yy378:
 	yych = *++p;
-	if (yych == 'T') goto yy34;
-	if (yych == 't') goto yy34;
+	if (yych == 'H') goto yy41;
+	if (yych == 'h') goto yy41;
 	goto yy31;
 yy379:
 	yych = *++p;
-	if (yych == 'M') goto yy34;
-	if (yych == 'm') goto yy34;
-	goto yy31;
+	if (yych == 'E') goto yy380;
+	if (yych != 'e') goto yy31;
 yy380:
 	yych = *++p;
+	if (yych == 'R') goto yy41;
+	if (yych == 'r') goto yy41;
+	goto yy31;
+yy381:
+	yych = *++p;
+	if (yych == 'T') goto yy399;
+	if (yych == 't') goto yy399;
+	goto yy31;
+yy382:
+	yych = *++p;
+	if (yych == 'T') goto yy41;
+	if (yych == 't') goto yy41;
+	goto yy31;
+yy383:
+	yych = *++p;
+	if (yych == 'M') goto yy41;
+	if (yych == 'm') goto yy41;
+	goto yy31;
+yy384:
+	yych = *++p;
 	if (yych <= 'S') {
-		if (yych == 'P') goto yy34;
+		if (yych == 'P') goto yy41;
 		if (yych <= 'R') goto yy31;
-		goto yy34;
+		goto yy41;
 	} else {
 		if (yych <= 'p') {
 			if (yych <= 'o') goto yy31;
-			goto yy34;
+			goto yy41;
 		} else {
-			if (yych == 's') goto yy34;
+			if (yych == 's') goto yy41;
 			goto yy31;
 		}
 	}
-yy381:
+yy385:
 	yych = *++p;
-	if (yych == 'I') goto yy389;
-	if (yych == 'i') goto yy389;
+	if (yych == 'I') goto yy393;
+	if (yych == 'i') goto yy393;
 	goto yy31;
-yy382:
+yy386:
 	yych = *++p;
-	if (yych == 'A') goto yy388;
-	if (yych == 'a') goto yy388;
+	if (yych == 'A') goto yy392;
+	if (yych == 'a') goto yy392;
 	goto yy31;
-yy383:
+yy387:
 	yych = *++p;
-	if (yych == 'O') goto yy386;
-	if (yych == 'o') goto yy386;
+	if (yych == 'O') goto yy390;
+	if (yych == 'o') goto yy390;
 	goto yy31;
-yy384:
+yy388:
 	yych = *++p;
-	if (yych == 'A') goto yy385;
+	if (yych == 'A') goto yy389;
 	if (yych != 'a') goto yy31;
-yy385:
+yy389:
 	yych = *++p;
 	if (yych <= 'R') {
-		if (yych == ':') goto yy35;
+		if (yych == ':') goto yy42;
 		goto yy31;
 	} else {
-		if (yych <= 'S') goto yy34;
-		if (yych == 's') goto yy34;
+		if (yych <= 'S') goto yy41;
+		if (yych == 's') goto yy41;
 		goto yy31;
 	}
-yy386:
+yy390:
 	yych = *++p;
-	if (yych == 'U') goto yy387;
+	if (yych == 'U') goto yy391;
 	if (yych != 'u') goto yy31;
-yy387:
+yy391:
 	yych = *++p;
-	if (yych == 'T') goto yy34;
-	if (yych == 't') goto yy34;
+	if (yych == 'T') goto yy41;
+	if (yych == 't') goto yy41;
 	goto yy31;
-yy388:
+yy392:
 	yych = *++p;
-	if (yych == 'P') goto yy34;
-	if (yych == 'p') goto yy34;
+	if (yych == 'P') goto yy41;
+	if (yych == 'p') goto yy41;
 	goto yy31;
-yy389:
+yy393:
 	yych = *++p;
-	if (yych == 'U') goto yy390;
+	if (yych == 'U') goto yy394;
 	if (yych != 'u') goto yy31;
-yy390:
+yy394:
 	yych = *++p;
-	if (yych == 'M') goto yy391;
+	if (yych == 'M') goto yy395;
 	if (yych != 'm') goto yy31;
-yy391:
+yy395:
 	yych = *++p;
-	if (yych == 'X') goto yy392;
+	if (yych == 'X') goto yy396;
 	if (yych != 'x') goto yy31;
-yy392:
+yy396:
 	yych = *++p;
-	if (yych == 'T') goto yy393;
+	if (yych == 'T') goto yy397;
 	if (yych != 't') goto yy31;
-yy393:
+yy397:
 	yych = *++p;
-	if (yych == 'R') goto yy394;
+	if (yych == 'R') goto yy398;
 	if (yych != 'r') goto yy31;
-yy394:
+yy398:
 	yych = *++p;
-	if (yych == 'A') goto yy34;
-	if (yych == 'a') goto yy34;
+	if (yych == 'A') goto yy41;
+	if (yych == 'a') goto yy41;
 	goto yy31;
-yy395:
+yy399:
 	yych = *++p;
-	if (yych == 'A') goto yy396;
+	if (yych == 'A') goto yy400;
 	if (yych != 'a') goto yy31;
-yy396:
+yy400:
 	yych = *++p;
-	if (yych == 'C') goto yy397;
+	if (yych == 'C') goto yy401;
 	if (yych != 'c') goto yy31;
-yy397:
+yy401:
 	yych = *++p;
-	if (yych == 'H') goto yy398;
+	if (yych == 'H') goto yy402;
 	if (yych != 'h') goto yy31;
-yy398:
+yy402:
 	yych = *++p;
-	if (yych == 'M') goto yy399;
+	if (yych == 'M') goto yy403;
 	if (yych != 'm') goto yy31;
-yy399:
+yy403:
 	yych = *++p;
-	if (yych == 'E') goto yy400;
+	if (yych == 'E') goto yy404;
 	if (yych != 'e') goto yy31;
-yy400:
+yy404:
 	yych = *++p;
-	if (yych == 'N') goto yy401;
+	if (yych == 'N') goto yy405;
 	if (yych != 'n') goto yy31;
-yy401:
+yy405:
 	yych = *++p;
-	if (yych == 'T') goto yy34;
-	if (yych == 't') goto yy34;
+	if (yych == 'T') goto yy41;
+	if (yych == 't') goto yy41;
 	goto yy31;
-yy402:
+yy406:
 	yych = *++p;
-	if (yych == 'S') goto yy34;
-	if (yych == 's') goto yy34;
+	if (yych == 'S') goto yy41;
+	if (yych == 's') goto yy41;
 	goto yy31;
-yy403:
+yy407:
 	yych = *++p;
 	if (yych <= 'V') {
-		if (yych == 'R') goto yy34;
+		if (yych == 'R') goto yy41;
 		if (yych <= 'U') goto yy31;
 	} else {
 		if (yych <= 'r') {
 			if (yych <= 'q') goto yy31;
-			goto yy34;
+			goto yy41;
 		} else {
 			if (yych != 'v') goto yy31;
 		}
 	}
 	yych = *++p;
-	if (yych == 'A') goto yy405;
+	if (yych == 'A') goto yy409;
 	if (yych != 'a') goto yy31;
-yy405:
+yy409:
 	yych = *++p;
-	if (yych == 'S') goto yy406;
+	if (yych == 'S') goto yy410;
 	if (yych != 's') goto yy31;
-yy406:
+yy410:
 	yych = *++p;
-	if (yych == 'C') goto yy407;
+	if (yych == 'C') goto yy411;
 	if (yych != 'c') goto yy31;
-yy407:
+yy411:
 	yych = *++p;
-	if (yych == 'R') goto yy408;
+	if (yych == 'R') goto yy412;
 	if (yych != 'r') goto yy31;
-yy408:
+yy412:
 	yych = *++p;
-	if (yych == 'I') goto yy409;
+	if (yych == 'I') goto yy413;
 	if (yych != 'i') goto yy31;
-yy409:
+yy413:
 	yych = *++p;
-	if (yych == 'P') goto yy410;
+	if (yych == 'P') goto yy414;
 	if (yych != 'p') goto yy31;
-yy410:
+yy414:
 	yych = *++p;
-	if (yych == 'T') goto yy34;
-	if (yych == 't') goto yy34;
+	if (yych == 'T') goto yy41;
+	if (yych == 't') goto yy41;
 	goto yy31;
-yy411:
+yy415:
 	yych = *++p;
-	if (yych == 'B') goto yy34;
-	if (yych == 'b') goto yy34;
+	if (yych == 'B') goto yy41;
+	if (yych == 'b') goto yy41;
 	goto yy31;
-yy412:
+yy416:
 	yych = *++p;
-	if (yych == 'N') goto yy34;
-	if (yych == 'n') goto yy34;
+	if (yych == 'N') goto yy41;
+	if (yych == 'n') goto yy41;
 	goto yy31;
-yy413:
+yy417:
 	yych = *++p;
-	if (yych == 'N') goto yy420;
-	if (yych == 'n') goto yy420;
+	if (yych == 'N') goto yy424;
+	if (yych == 'n') goto yy424;
 	goto yy31;
-yy414:
+yy418:
 	yych = *++p;
-	if (yych == 'S') goto yy34;
-	if (yych == 's') goto yy34;
+	if (yych == 'S') goto yy41;
+	if (yych == 's') goto yy41;
 	goto yy31;
-yy415:
+yy419:
 	yych = *++p;
-	if (yych == 'C') goto yy419;
-	if (yych == 'c') goto yy419;
+	if (yych == 'C') goto yy423;
+	if (yych == 'c') goto yy423;
 	goto yy31;
-yy416:
+yy420:
 	yych = *++p;
 	if (yych <= 'V') {
-		if (yych == 'T') goto yy418;
+		if (yych == 'T') goto yy422;
 		if (yych <= 'U') goto yy31;
-		goto yy34;
+		goto yy41;
 	} else {
 		if (yych <= 't') {
 			if (yych <= 's') goto yy31;
-			goto yy418;
+			goto yy422;
 		} else {
-			if (yych == 'v') goto yy34;
+			if (yych == 'v') goto yy41;
 			goto yy31;
 		}
 	}
-yy417:
+yy421:
 	yych = *++p;
-	if (yych == 'I') goto yy34;
-	if (yych == 'i') goto yy34;
+	if (yych == 'I') goto yy41;
+	if (yych == 'i') goto yy41;
 	goto yy31;
-yy418:
+yy422:
 	yych = *++p;
-	if (yych == 'A') goto yy34;
-	if (yych == 'a') goto yy34;
+	if (yych == 'A') goto yy41;
+	if (yych == 'a') goto yy41;
 	goto yy31;
-yy419:
+yy423:
 	yych = *++p;
-	if (yych == 'T') goto yy34;
-	if (yych == 't') goto yy34;
+	if (yych == 'T') goto yy41;
+	if (yych == 't') goto yy41;
 	goto yy31;
-yy420:
+yy424:
 	yych = *++p;
-	if (yych == 'A') goto yy421;
+	if (yych == 'A') goto yy425;
 	if (yych != 'a') goto yy31;
-yy421:
+yy425:
 	yych = *++p;
 	if (yych != '-') goto yy31;
 	yych = *++p;
-	if (yych == 'P') goto yy423;
+	if (yych == 'P') goto yy427;
 	if (yych != 'p') goto yy31;
-yy423:
+yy427:
 	yych = *++p;
-	if (yych == 'L') goto yy424;
+	if (yych == 'L') goto yy428;
 	if (yych != 'l') goto yy31;
-yy424:
+yy428:
 	yych = *++p;
-	if (yych == 'A') goto yy425;
+	if (yych == 'A') goto yy429;
 	if (yych != 'a') goto yy31;
-yy425:
+yy429:
 	yych = *++p;
-	if (yych == 'Y') goto yy426;
+	if (yych == 'Y') goto yy430;
 	if (yych != 'y') goto yy31;
-yy426:
+yy430:
 	yych = *++p;
 	if (yych <= 'S') {
-		if (yych == 'C') goto yy427;
+		if (yych == 'C') goto yy431;
 		if (yych <= 'R') goto yy31;
-		goto yy428;
+		goto yy432;
 	} else {
 		if (yych <= 'c') {
 			if (yych <= 'b') goto yy31;
 		} else {
-			if (yych == 's') goto yy428;
+			if (yych == 's') goto yy432;
 			goto yy31;
 		}
 	}
-yy427:
+yy431:
 	yych = *++p;
-	if (yych == 'O') goto yy433;
-	if (yych == 'o') goto yy433;
+	if (yych == 'O') goto yy437;
+	if (yych == 'o') goto yy437;
 	goto yy31;
-yy428:
+yy432:
 	yych = *++p;
-	if (yych == 'I') goto yy429;
+	if (yych == 'I') goto yy433;
 	if (yych != 'i') goto yy31;
-yy429:
+yy433:
 	yych = *++p;
-	if (yych == 'N') goto yy430;
+	if (yych == 'N') goto yy434;
 	if (yych != 'n') goto yy31;
-yy430:
+yy434:
 	yych = *++p;
-	if (yych == 'G') goto yy431;
+	if (yych == 'G') goto yy435;
 	if (yych != 'g') goto yy31;
-yy431:
+yy435:
 	yych = *++p;
-	if (yych == 'L') goto yy432;
+	if (yych == 'L') goto yy436;
 	if (yych != 'l') goto yy31;
-yy432:
+yy436:
 	yych = *++p;
-	if (yych == 'E') goto yy34;
-	if (yych == 'e') goto yy34;
+	if (yych == 'E') goto yy41;
+	if (yych == 'e') goto yy41;
 	goto yy31;
-yy433:
+yy437:
 	yych = *++p;
-	if (yych == 'N') goto yy434;
+	if (yych == 'N') goto yy438;
 	if (yych != 'n') goto yy31;
-yy434:
+yy438:
 	yych = *++p;
-	if (yych == 'T') goto yy435;
+	if (yych == 'T') goto yy439;
 	if (yych != 't') goto yy31;
-yy435:
+yy439:
 	yych = *++p;
-	if (yych == 'A') goto yy436;
+	if (yych == 'A') goto yy440;
 	if (yych != 'a') goto yy31;
-yy436:
+yy440:
 	yych = *++p;
-	if (yych == 'I') goto yy437;
+	if (yych == 'I') goto yy441;
 	if (yych != 'i') goto yy31;
-yy437:
+yy441:
 	yych = *++p;
-	if (yych == 'N') goto yy438;
+	if (yych == 'N') goto yy442;
 	if (yych != 'n') goto yy31;
-yy438:
+yy442:
 	yych = *++p;
-	if (yych == 'E') goto yy439;
+	if (yych == 'E') goto yy443;
 	if (yych != 'e') goto yy31;
-yy439:
+yy443:
 	yych = *++p;
-	if (yych == 'R') goto yy34;
-	if (yych == 'r') goto yy34;
+	if (yych == 'R') goto yy41;
+	if (yych == 'r') goto yy41;
 	goto yy31;
-yy440:
+yy444:
 	yych = *++p;
-	if (yych == 'S') goto yy34;
-	if (yych == 's') goto yy34;
+	if (yych == 'S') goto yy41;
+	if (yych == 's') goto yy41;
 	goto yy31;
-yy441:
+yy445:
 	yych = *++p;
 	if (yych <= 'N') {
 		if (yych <= 'A') {
 			if (yych <= '@') goto yy31;
-			goto yy463;
+			goto yy467;
 		} else {
 			if (yych <= 'L') goto yy31;
-			if (yych <= 'M') goto yy464;
-			goto yy465;
+			if (yych <= 'M') goto yy468;
+			goto yy469;
 		}
 	} else {
 		if (yych <= 'l') {
-			if (yych == 'a') goto yy463;
+			if (yych == 'a') goto yy467;
 			goto yy31;
 		} else {
-			if (yych <= 'm') goto yy464;
-			if (yych <= 'n') goto yy465;
+			if (yych <= 'm') goto yy468;
+			if (yych <= 'n') goto yy469;
 			goto yy31;
 		}
 	}
-yy442:
+yy446:
 	yych = *++p;
-	if (yych == 'R') goto yy450;
-	if (yych == 'r') goto yy450;
+	if (yych == 'R') goto yy454;
+	if (yych == 'r') goto yy454;
 	goto yy31;
-yy443:
+yy447:
 	yych = *++p;
 	if (yych <= 'P') {
-		if (yych == 'L') goto yy447;
+		if (yych == 'L') goto yy451;
 		if (yych <= 'O') goto yy31;
-		goto yy34;
+		goto yy41;
 	} else {
 		if (yych <= 'l') {
 			if (yych <= 'k') goto yy31;
-			goto yy447;
+			goto yy451;
 		} else {
-			if (yych == 'p') goto yy34;
+			if (yych == 'p') goto yy41;
 			goto yy31;
 		}
 	}
-yy444:
+yy448:
 	yych = *++p;
-	if (yych == 'I') goto yy446;
-	if (yych == 'i') goto yy446;
+	if (yych == 'I') goto yy450;
+	if (yych == 'i') goto yy450;
 	goto yy31;
-yy445:
+yy449:
 	yych = *++p;
-	if (yych == 'D') goto yy34;
-	if (yych == 'd') goto yy34;
+	if (yych == 'D') goto yy41;
+	if (yych == 'd') goto yy41;
 	goto yy31;
-yy446:
+yy450:
 	yych = *++p;
-	if (yych == 'D') goto yy34;
-	if (yych == 'd') goto yy34;
+	if (yych == 'D') goto yy41;
+	if (yych == 'd') goto yy41;
 	goto yy31;
-yy447:
+yy451:
 	yych = *++p;
-	if (yych == 'L') goto yy448;
+	if (yych == 'L') goto yy452;
 	if (yych != 'l') goto yy31;
-yy448:
+yy452:
 	yych = *++p;
-	if (yych == 'T') goto yy449;
+	if (yych == 'T') goto yy453;
 	if (yych != 't') goto yy31;
-yy449:
+yy453:
 	yych = *++p;
-	if (yych == 'O') goto yy34;
-	if (yych == 'o') goto yy34;
+	if (yych == 'O') goto yy41;
+	if (yych == 'o') goto yy41;
 	goto yy31;
-yy450:
+yy454:
 	yych = *++p;
-	if (yych == 'O') goto yy451;
+	if (yych == 'O') goto yy455;
 	if (yych != 'o') goto yy31;
-yy451:
+yy455:
 	yych = *++p;
-	if (yych == 'M') goto yy452;
+	if (yych == 'M') goto yy456;
 	if (yych != 'm') goto yy31;
-yy452:
+yy456:
 	yych = *++p;
-	if (yych == 'E') goto yy453;
+	if (yych == 'E') goto yy457;
 	if (yych != 'e') goto yy31;
-yy453:
+yy457:
 	yych = *++p;
-	if (yych == '-') goto yy454;
-	if (yych == ':') goto yy35;
+	if (yych == '-') goto yy458;
+	if (yych == ':') goto yy42;
 	goto yy31;
-yy454:
+yy458:
 	yych = *++p;
-	if (yych == 'E') goto yy455;
+	if (yych == 'E') goto yy459;
 	if (yych != 'e') goto yy31;
-yy455:
+yy459:
 	yych = *++p;
-	if (yych == 'X') goto yy456;
+	if (yych == 'X') goto yy460;
 	if (yych != 'x') goto yy31;
-yy456:
+yy460:
 	yych = *++p;
-	if (yych == 'T') goto yy457;
+	if (yych == 'T') goto yy461;
 	if (yych != 't') goto yy31;
-yy457:
+yy461:
 	yych = *++p;
-	if (yych == 'E') goto yy458;
+	if (yych == 'E') goto yy462;
 	if (yych != 'e') goto yy31;
-yy458:
+yy462:
 	yych = *++p;
-	if (yych == 'N') goto yy459;
+	if (yych == 'N') goto yy463;
 	if (yych != 'n') goto yy31;
-yy459:
+yy463:
 	yych = *++p;
-	if (yych == 'S') goto yy460;
+	if (yych == 'S') goto yy464;
 	if (yych != 's') goto yy31;
-yy460:
+yy464:
 	yych = *++p;
-	if (yych == 'I') goto yy461;
+	if (yych == 'I') goto yy465;
 	if (yych != 'i') goto yy31;
-yy461:
+yy465:
 	yych = *++p;
-	if (yych == 'O') goto yy462;
+	if (yych == 'O') goto yy466;
 	if (yych != 'o') goto yy31;
-yy462:
+yy466:
 	yych = *++p;
-	if (yych == 'N') goto yy34;
-	if (yych == 'n') goto yy34;
+	if (yych == 'N') goto yy41;
+	if (yych == 'n') goto yy41;
 	goto yy31;
-yy463:
+yy467:
 	yych = *++p;
-	if (yych == 'P') goto yy34;
-	if (yych == 'p') goto yy34;
+	if (yych == 'P') goto yy41;
+	if (yych == 'p') goto yy41;
 	goto yy31;
-yy464:
+yy468:
 	yych = *++p;
-	if (yy

<TRUNCATED>

[09/20] lucy-clownfish git commit: Upgrade libcmark to 0.21.0

Posted by nw...@apache.org.
http://git-wip-us.apache.org/repos/asf/lucy-clownfish/blob/89c7b809/compiler/modules/CommonMark/src/entities.inc
----------------------------------------------------------------------
diff --git a/compiler/modules/CommonMark/src/entities.inc b/compiler/modules/CommonMark/src/entities.inc
new file mode 100644
index 0000000..ec3d2a9
--- /dev/null
+++ b/compiler/modules/CommonMark/src/entities.inc
@@ -0,0 +1,2138 @@
+/* Autogenerated by tools/make_headers_inc.py */
+
+struct cmark_entity_node {
+	unsigned char *entity;
+        unsigned char bytes[8];
+};
+
+#define CMARK_ENTITY_MIN_LENGTH 2
+#define CMARK_ENTITY_MAX_LENGTH 31
+#define CMARK_NUM_ENTITIES 2125
+
+static const struct cmark_entity_node cmark_entities[] = {
+{(unsigned char*)"AElig", {195, 134, 0}},
+{(unsigned char*)"AMP", {38, 0}},
+{(unsigned char*)"Aacute", {195, 129, 0}},
+{(unsigned char*)"Abreve", {196, 130, 0}},
+{(unsigned char*)"Acirc", {195, 130, 0}},
+{(unsigned char*)"Acy", {208, 144, 0}},
+{(unsigned char*)"Afr", {240, 157, 148, 132, 0}},
+{(unsigned char*)"Agrave", {195, 128, 0}},
+{(unsigned char*)"Alpha", {206, 145, 0}},
+{(unsigned char*)"Amacr", {196, 128, 0}},
+{(unsigned char*)"And", {226, 169, 147, 0}},
+{(unsigned char*)"Aogon", {196, 132, 0}},
+{(unsigned char*)"Aopf", {240, 157, 148, 184, 0}},
+{(unsigned char*)"ApplyFunction", {226, 129, 161, 0}},
+{(unsigned char*)"Aring", {195, 133, 0}},
+{(unsigned char*)"Ascr", {240, 157, 146, 156, 0}},
+{(unsigned char*)"Assign", {226, 137, 148, 0}},
+{(unsigned char*)"Atilde", {195, 131, 0}},
+{(unsigned char*)"Auml", {195, 132, 0}},
+{(unsigned char*)"Backslash", {226, 136, 150, 0}},
+{(unsigned char*)"Barv", {226, 171, 167, 0}},
+{(unsigned char*)"Barwed", {226, 140, 134, 0}},
+{(unsigned char*)"Bcy", {208, 145, 0}},
+{(unsigned char*)"Because", {226, 136, 181, 0}},
+{(unsigned char*)"Bernoullis", {226, 132, 172, 0}},
+{(unsigned char*)"Beta", {206, 146, 0}},
+{(unsigned char*)"Bfr", {240, 157, 148, 133, 0}},
+{(unsigned char*)"Bopf", {240, 157, 148, 185, 0}},
+{(unsigned char*)"Breve", {203, 152, 0}},
+{(unsigned char*)"Bscr", {226, 132, 172, 0}},
+{(unsigned char*)"Bumpeq", {226, 137, 142, 0}},
+{(unsigned char*)"CHcy", {208, 167, 0}},
+{(unsigned char*)"COPY", {194, 169, 0}},
+{(unsigned char*)"Cacute", {196, 134, 0}},
+{(unsigned char*)"Cap", {226, 139, 146, 0}},
+{(unsigned char*)"CapitalDifferentialD", {226, 133, 133, 0}},
+{(unsigned char*)"Cayleys", {226, 132, 173, 0}},
+{(unsigned char*)"Ccaron", {196, 140, 0}},
+{(unsigned char*)"Ccedil", {195, 135, 0}},
+{(unsigned char*)"Ccirc", {196, 136, 0}},
+{(unsigned char*)"Cconint", {226, 136, 176, 0}},
+{(unsigned char*)"Cdot", {196, 138, 0}},
+{(unsigned char*)"Cedilla", {194, 184, 0}},
+{(unsigned char*)"CenterDot", {194, 183, 0}},
+{(unsigned char*)"Cfr", {226, 132, 173, 0}},
+{(unsigned char*)"Chi", {206, 167, 0}},
+{(unsigned char*)"CircleDot", {226, 138, 153, 0}},
+{(unsigned char*)"CircleMinus", {226, 138, 150, 0}},
+{(unsigned char*)"CirclePlus", {226, 138, 149, 0}},
+{(unsigned char*)"CircleTimes", {226, 138, 151, 0}},
+{(unsigned char*)"ClockwiseContourIntegral", {226, 136, 178, 0}},
+{(unsigned char*)"CloseCurlyDoubleQuote", {226, 128, 157, 0}},
+{(unsigned char*)"CloseCurlyQuote", {226, 128, 153, 0}},
+{(unsigned char*)"Colon", {226, 136, 183, 0}},
+{(unsigned char*)"Colone", {226, 169, 180, 0}},
+{(unsigned char*)"Congruent", {226, 137, 161, 0}},
+{(unsigned char*)"Conint", {226, 136, 175, 0}},
+{(unsigned char*)"ContourIntegral", {226, 136, 174, 0}},
+{(unsigned char*)"Copf", {226, 132, 130, 0}},
+{(unsigned char*)"Coproduct", {226, 136, 144, 0}},
+{(unsigned char*)"CounterClockwiseContourIntegral", {226, 136, 179, 0}},
+{(unsigned char*)"Cross", {226, 168, 175, 0}},
+{(unsigned char*)"Cscr", {240, 157, 146, 158, 0}},
+{(unsigned char*)"Cup", {226, 139, 147, 0}},
+{(unsigned char*)"CupCap", {226, 137, 141, 0}},
+{(unsigned char*)"DD", {226, 133, 133, 0}},
+{(unsigned char*)"DDotrahd", {226, 164, 145, 0}},
+{(unsigned char*)"DJcy", {208, 130, 0}},
+{(unsigned char*)"DScy", {208, 133, 0}},
+{(unsigned char*)"DZcy", {208, 143, 0}},
+{(unsigned char*)"Dagger", {226, 128, 161, 0}},
+{(unsigned char*)"Darr", {226, 134, 161, 0}},
+{(unsigned char*)"Dashv", {226, 171, 164, 0}},
+{(unsigned char*)"Dcaron", {196, 142, 0}},
+{(unsigned char*)"Dcy", {208, 148, 0}},
+{(unsigned char*)"Del", {226, 136, 135, 0}},
+{(unsigned char*)"Delta", {206, 148, 0}},
+{(unsigned char*)"Dfr", {240, 157, 148, 135, 0}},
+{(unsigned char*)"DiacriticalAcute", {194, 180, 0}},
+{(unsigned char*)"DiacriticalDot", {203, 153, 0}},
+{(unsigned char*)"DiacriticalDoubleAcute", {203, 157, 0}},
+{(unsigned char*)"DiacriticalGrave", {96, 0}},
+{(unsigned char*)"DiacriticalTilde", {203, 156, 0}},
+{(unsigned char*)"Diamond", {226, 139, 132, 0}},
+{(unsigned char*)"DifferentialD", {226, 133, 134, 0}},
+{(unsigned char*)"Dopf", {240, 157, 148, 187, 0}},
+{(unsigned char*)"Dot", {194, 168, 0}},
+{(unsigned char*)"DotDot", {226, 131, 156, 0}},
+{(unsigned char*)"DotEqual", {226, 137, 144, 0}},
+{(unsigned char*)"DoubleContourIntegral", {226, 136, 175, 0}},
+{(unsigned char*)"DoubleDot", {194, 168, 0}},
+{(unsigned char*)"DoubleDownArrow", {226, 135, 147, 0}},
+{(unsigned char*)"DoubleLeftArrow", {226, 135, 144, 0}},
+{(unsigned char*)"DoubleLeftRightArrow", {226, 135, 148, 0}},
+{(unsigned char*)"DoubleLeftTee", {226, 171, 164, 0}},
+{(unsigned char*)"DoubleLongLeftArrow", {226, 159, 184, 0}},
+{(unsigned char*)"DoubleLongLeftRightArrow", {226, 159, 186, 0}},
+{(unsigned char*)"DoubleLongRightArrow", {226, 159, 185, 0}},
+{(unsigned char*)"DoubleRightArrow", {226, 135, 146, 0}},
+{(unsigned char*)"DoubleRightTee", {226, 138, 168, 0}},
+{(unsigned char*)"DoubleUpArrow", {226, 135, 145, 0}},
+{(unsigned char*)"DoubleUpDownArrow", {226, 135, 149, 0}},
+{(unsigned char*)"DoubleVerticalBar", {226, 136, 165, 0}},
+{(unsigned char*)"DownArrow", {226, 134, 147, 0}},
+{(unsigned char*)"DownArrowBar", {226, 164, 147, 0}},
+{(unsigned char*)"DownArrowUpArrow", {226, 135, 181, 0}},
+{(unsigned char*)"DownBreve", {204, 145, 0}},
+{(unsigned char*)"DownLeftRightVector", {226, 165, 144, 0}},
+{(unsigned char*)"DownLeftTeeVector", {226, 165, 158, 0}},
+{(unsigned char*)"DownLeftVector", {226, 134, 189, 0}},
+{(unsigned char*)"DownLeftVectorBar", {226, 165, 150, 0}},
+{(unsigned char*)"DownRightTeeVector", {226, 165, 159, 0}},
+{(unsigned char*)"DownRightVector", {226, 135, 129, 0}},
+{(unsigned char*)"DownRightVectorBar", {226, 165, 151, 0}},
+{(unsigned char*)"DownTee", {226, 138, 164, 0}},
+{(unsigned char*)"DownTeeArrow", {226, 134, 167, 0}},
+{(unsigned char*)"Downarrow", {226, 135, 147, 0}},
+{(unsigned char*)"Dscr", {240, 157, 146, 159, 0}},
+{(unsigned char*)"Dstrok", {196, 144, 0}},
+{(unsigned char*)"ENG", {197, 138, 0}},
+{(unsigned char*)"ETH", {195, 144, 0}},
+{(unsigned char*)"Eacute", {195, 137, 0}},
+{(unsigned char*)"Ecaron", {196, 154, 0}},
+{(unsigned char*)"Ecirc", {195, 138, 0}},
+{(unsigned char*)"Ecy", {208, 173, 0}},
+{(unsigned char*)"Edot", {196, 150, 0}},
+{(unsigned char*)"Efr", {240, 157, 148, 136, 0}},
+{(unsigned char*)"Egrave", {195, 136, 0}},
+{(unsigned char*)"Element", {226, 136, 136, 0}},
+{(unsigned char*)"Emacr", {196, 146, 0}},
+{(unsigned char*)"EmptySmallSquare", {226, 151, 187, 0}},
+{(unsigned char*)"EmptyVerySmallSquare", {226, 150, 171, 0}},
+{(unsigned char*)"Eogon", {196, 152, 0}},
+{(unsigned char*)"Eopf", {240, 157, 148, 188, 0}},
+{(unsigned char*)"Epsilon", {206, 149, 0}},
+{(unsigned char*)"Equal", {226, 169, 181, 0}},
+{(unsigned char*)"EqualTilde", {226, 137, 130, 0}},
+{(unsigned char*)"Equilibrium", {226, 135, 140, 0}},
+{(unsigned char*)"Escr", {226, 132, 176, 0}},
+{(unsigned char*)"Esim", {226, 169, 179, 0}},
+{(unsigned char*)"Eta", {206, 151, 0}},
+{(unsigned char*)"Euml", {195, 139, 0}},
+{(unsigned char*)"Exists", {226, 136, 131, 0}},
+{(unsigned char*)"ExponentialE", {226, 133, 135, 0}},
+{(unsigned char*)"Fcy", {208, 164, 0}},
+{(unsigned char*)"Ffr", {240, 157, 148, 137, 0}},
+{(unsigned char*)"FilledSmallSquare", {226, 151, 188, 0}},
+{(unsigned char*)"FilledVerySmallSquare", {226, 150, 170, 0}},
+{(unsigned char*)"Fopf", {240, 157, 148, 189, 0}},
+{(unsigned char*)"ForAll", {226, 136, 128, 0}},
+{(unsigned char*)"Fouriertrf", {226, 132, 177, 0}},
+{(unsigned char*)"Fscr", {226, 132, 177, 0}},
+{(unsigned char*)"GJcy", {208, 131, 0}},
+{(unsigned char*)"GT", {62, 0}},
+{(unsigned char*)"Gamma", {206, 147, 0}},
+{(unsigned char*)"Gammad", {207, 156, 0}},
+{(unsigned char*)"Gbreve", {196, 158, 0}},
+{(unsigned char*)"Gcedil", {196, 162, 0}},
+{(unsigned char*)"Gcirc", {196, 156, 0}},
+{(unsigned char*)"Gcy", {208, 147, 0}},
+{(unsigned char*)"Gdot", {196, 160, 0}},
+{(unsigned char*)"Gfr", {240, 157, 148, 138, 0}},
+{(unsigned char*)"Gg", {226, 139, 153, 0}},
+{(unsigned char*)"Gopf", {240, 157, 148, 190, 0}},
+{(unsigned char*)"GreaterEqual", {226, 137, 165, 0}},
+{(unsigned char*)"GreaterEqualLess", {226, 139, 155, 0}},
+{(unsigned char*)"GreaterFullEqual", {226, 137, 167, 0}},
+{(unsigned char*)"GreaterGreater", {226, 170, 162, 0}},
+{(unsigned char*)"GreaterLess", {226, 137, 183, 0}},
+{(unsigned char*)"GreaterSlantEqual", {226, 169, 190, 0}},
+{(unsigned char*)"GreaterTilde", {226, 137, 179, 0}},
+{(unsigned char*)"Gscr", {240, 157, 146, 162, 0}},
+{(unsigned char*)"Gt", {226, 137, 171, 0}},
+{(unsigned char*)"HARDcy", {208, 170, 0}},
+{(unsigned char*)"Hacek", {203, 135, 0}},
+{(unsigned char*)"Hat", {94, 0}},
+{(unsigned char*)"Hcirc", {196, 164, 0}},
+{(unsigned char*)"Hfr", {226, 132, 140, 0}},
+{(unsigned char*)"HilbertSpace", {226, 132, 139, 0}},
+{(unsigned char*)"Hopf", {226, 132, 141, 0}},
+{(unsigned char*)"HorizontalLine", {226, 148, 128, 0}},
+{(unsigned char*)"Hscr", {226, 132, 139, 0}},
+{(unsigned char*)"Hstrok", {196, 166, 0}},
+{(unsigned char*)"HumpDownHump", {226, 137, 142, 0}},
+{(unsigned char*)"HumpEqual", {226, 137, 143, 0}},
+{(unsigned char*)"IEcy", {208, 149, 0}},
+{(unsigned char*)"IJlig", {196, 178, 0}},
+{(unsigned char*)"IOcy", {208, 129, 0}},
+{(unsigned char*)"Iacute", {195, 141, 0}},
+{(unsigned char*)"Icirc", {195, 142, 0}},
+{(unsigned char*)"Icy", {208, 152, 0}},
+{(unsigned char*)"Idot", {196, 176, 0}},
+{(unsigned char*)"Ifr", {226, 132, 145, 0}},
+{(unsigned char*)"Igrave", {195, 140, 0}},
+{(unsigned char*)"Im", {226, 132, 145, 0}},
+{(unsigned char*)"Imacr", {196, 170, 0}},
+{(unsigned char*)"ImaginaryI", {226, 133, 136, 0}},
+{(unsigned char*)"Implies", {226, 135, 146, 0}},
+{(unsigned char*)"Int", {226, 136, 172, 0}},
+{(unsigned char*)"Integral", {226, 136, 171, 0}},
+{(unsigned char*)"Intersection", {226, 139, 130, 0}},
+{(unsigned char*)"InvisibleComma", {226, 129, 163, 0}},
+{(unsigned char*)"InvisibleTimes", {226, 129, 162, 0}},
+{(unsigned char*)"Iogon", {196, 174, 0}},
+{(unsigned char*)"Iopf", {240, 157, 149, 128, 0}},
+{(unsigned char*)"Iota", {206, 153, 0}},
+{(unsigned char*)"Iscr", {226, 132, 144, 0}},
+{(unsigned char*)"Itilde", {196, 168, 0}},
+{(unsigned char*)"Iukcy", {208, 134, 0}},
+{(unsigned char*)"Iuml", {195, 143, 0}},
+{(unsigned char*)"Jcirc", {196, 180, 0}},
+{(unsigned char*)"Jcy", {208, 153, 0}},
+{(unsigned char*)"Jfr", {240, 157, 148, 141, 0}},
+{(unsigned char*)"Jopf", {240, 157, 149, 129, 0}},
+{(unsigned char*)"Jscr", {240, 157, 146, 165, 0}},
+{(unsigned char*)"Jsercy", {208, 136, 0}},
+{(unsigned char*)"Jukcy", {208, 132, 0}},
+{(unsigned char*)"KHcy", {208, 165, 0}},
+{(unsigned char*)"KJcy", {208, 140, 0}},
+{(unsigned char*)"Kappa", {206, 154, 0}},
+{(unsigned char*)"Kcedil", {196, 182, 0}},
+{(unsigned char*)"Kcy", {208, 154, 0}},
+{(unsigned char*)"Kfr", {240, 157, 148, 142, 0}},
+{(unsigned char*)"Kopf", {240, 157, 149, 130, 0}},
+{(unsigned char*)"Kscr", {240, 157, 146, 166, 0}},
+{(unsigned char*)"LJcy", {208, 137, 0}},
+{(unsigned char*)"LT", {60, 0}},
+{(unsigned char*)"Lacute", {196, 185, 0}},
+{(unsigned char*)"Lambda", {206, 155, 0}},
+{(unsigned char*)"Lang", {226, 159, 170, 0}},
+{(unsigned char*)"Laplacetrf", {226, 132, 146, 0}},
+{(unsigned char*)"Larr", {226, 134, 158, 0}},
+{(unsigned char*)"Lcaron", {196, 189, 0}},
+{(unsigned char*)"Lcedil", {196, 187, 0}},
+{(unsigned char*)"Lcy", {208, 155, 0}},
+{(unsigned char*)"LeftAngleBracket", {226, 159, 168, 0}},
+{(unsigned char*)"LeftArrow", {226, 134, 144, 0}},
+{(unsigned char*)"LeftArrowBar", {226, 135, 164, 0}},
+{(unsigned char*)"LeftArrowRightArrow", {226, 135, 134, 0}},
+{(unsigned char*)"LeftCeiling", {226, 140, 136, 0}},
+{(unsigned char*)"LeftDoubleBracket", {226, 159, 166, 0}},
+{(unsigned char*)"LeftDownTeeVector", {226, 165, 161, 0}},
+{(unsigned char*)"LeftDownVector", {226, 135, 131, 0}},
+{(unsigned char*)"LeftDownVectorBar", {226, 165, 153, 0}},
+{(unsigned char*)"LeftFloor", {226, 140, 138, 0}},
+{(unsigned char*)"LeftRightArrow", {226, 134, 148, 0}},
+{(unsigned char*)"LeftRightVector", {226, 165, 142, 0}},
+{(unsigned char*)"LeftTee", {226, 138, 163, 0}},
+{(unsigned char*)"LeftTeeArrow", {226, 134, 164, 0}},
+{(unsigned char*)"LeftTeeVector", {226, 165, 154, 0}},
+{(unsigned char*)"LeftTriangle", {226, 138, 178, 0}},
+{(unsigned char*)"LeftTriangleBar", {226, 167, 143, 0}},
+{(unsigned char*)"LeftTriangleEqual", {226, 138, 180, 0}},
+{(unsigned char*)"LeftUpDownVector", {226, 165, 145, 0}},
+{(unsigned char*)"LeftUpTeeVector", {226, 165, 160, 0}},
+{(unsigned char*)"LeftUpVector", {226, 134, 191, 0}},
+{(unsigned char*)"LeftUpVectorBar", {226, 165, 152, 0}},
+{(unsigned char*)"LeftVector", {226, 134, 188, 0}},
+{(unsigned char*)"LeftVectorBar", {226, 165, 146, 0}},
+{(unsigned char*)"Leftarrow", {226, 135, 144, 0}},
+{(unsigned char*)"Leftrightarrow", {226, 135, 148, 0}},
+{(unsigned char*)"LessEqualGreater", {226, 139, 154, 0}},
+{(unsigned char*)"LessFullEqual", {226, 137, 166, 0}},
+{(unsigned char*)"LessGreater", {226, 137, 182, 0}},
+{(unsigned char*)"LessLess", {226, 170, 161, 0}},
+{(unsigned char*)"LessSlantEqual", {226, 169, 189, 0}},
+{(unsigned char*)"LessTilde", {226, 137, 178, 0}},
+{(unsigned char*)"Lfr", {240, 157, 148, 143, 0}},
+{(unsigned char*)"Ll", {226, 139, 152, 0}},
+{(unsigned char*)"Lleftarrow", {226, 135, 154, 0}},
+{(unsigned char*)"Lmidot", {196, 191, 0}},
+{(unsigned char*)"LongLeftArrow", {226, 159, 181, 0}},
+{(unsigned char*)"LongLeftRightArrow", {226, 159, 183, 0}},
+{(unsigned char*)"LongRightArrow", {226, 159, 182, 0}},
+{(unsigned char*)"Longleftarrow", {226, 159, 184, 0}},
+{(unsigned char*)"Longleftrightarrow", {226, 159, 186, 0}},
+{(unsigned char*)"Longrightarrow", {226, 159, 185, 0}},
+{(unsigned char*)"Lopf", {240, 157, 149, 131, 0}},
+{(unsigned char*)"LowerLeftArrow", {226, 134, 153, 0}},
+{(unsigned char*)"LowerRightArrow", {226, 134, 152, 0}},
+{(unsigned char*)"Lscr", {226, 132, 146, 0}},
+{(unsigned char*)"Lsh", {226, 134, 176, 0}},
+{(unsigned char*)"Lstrok", {197, 129, 0}},
+{(unsigned char*)"Lt", {226, 137, 170, 0}},
+{(unsigned char*)"Map", {226, 164, 133, 0}},
+{(unsigned char*)"Mcy", {208, 156, 0}},
+{(unsigned char*)"MediumSpace", {226, 129, 159, 0}},
+{(unsigned char*)"Mellintrf", {226, 132, 179, 0}},
+{(unsigned char*)"Mfr", {240, 157, 148, 144, 0}},
+{(unsigned char*)"MinusPlus", {226, 136, 147, 0}},
+{(unsigned char*)"Mopf", {240, 157, 149, 132, 0}},
+{(unsigned char*)"Mscr", {226, 132, 179, 0}},
+{(unsigned char*)"Mu", {206, 156, 0}},
+{(unsigned char*)"NJcy", {208, 138, 0}},
+{(unsigned char*)"Nacute", {197, 131, 0}},
+{(unsigned char*)"Ncaron", {197, 135, 0}},
+{(unsigned char*)"Ncedil", {197, 133, 0}},
+{(unsigned char*)"Ncy", {208, 157, 0}},
+{(unsigned char*)"NegativeMediumSpace", {226, 128, 139, 0}},
+{(unsigned char*)"NegativeThickSpace", {226, 128, 139, 0}},
+{(unsigned char*)"NegativeThinSpace", {226, 128, 139, 0}},
+{(unsigned char*)"NegativeVeryThinSpace", {226, 128, 139, 0}},
+{(unsigned char*)"NestedGreaterGreater", {226, 137, 171, 0}},
+{(unsigned char*)"NestedLessLess", {226, 137, 170, 0}},
+{(unsigned char*)"NewLine", {10, 0}},
+{(unsigned char*)"Nfr", {240, 157, 148, 145, 0}},
+{(unsigned char*)"NoBreak", {226, 129, 160, 0}},
+{(unsigned char*)"NonBreakingSpace", {194, 160, 0}},
+{(unsigned char*)"Nopf", {226, 132, 149, 0}},
+{(unsigned char*)"Not", {226, 171, 172, 0}},
+{(unsigned char*)"NotCongruent", {226, 137, 162, 0}},
+{(unsigned char*)"NotCupCap", {226, 137, 173, 0}},
+{(unsigned char*)"NotDoubleVerticalBar", {226, 136, 166, 0}},
+{(unsigned char*)"NotElement", {226, 136, 137, 0}},
+{(unsigned char*)"NotEqual", {226, 137, 160, 0}},
+{(unsigned char*)"NotEqualTilde", {226, 137, 130, 204, 184, 0}},
+{(unsigned char*)"NotExists", {226, 136, 132, 0}},
+{(unsigned char*)"NotGreater", {226, 137, 175, 0}},
+{(unsigned char*)"NotGreaterEqual", {226, 137, 177, 0}},
+{(unsigned char*)"NotGreaterFullEqual", {226, 137, 167, 204, 184, 0}},
+{(unsigned char*)"NotGreaterGreater", {226, 137, 171, 204, 184, 0}},
+{(unsigned char*)"NotGreaterLess", {226, 137, 185, 0}},
+{(unsigned char*)"NotGreaterSlantEqual", {226, 169, 190, 204, 184, 0}},
+{(unsigned char*)"NotGreaterTilde", {226, 137, 181, 0}},
+{(unsigned char*)"NotHumpDownHump", {226, 137, 142, 204, 184, 0}},
+{(unsigned char*)"NotHumpEqual", {226, 137, 143, 204, 184, 0}},
+{(unsigned char*)"NotLeftTriangle", {226, 139, 170, 0}},
+{(unsigned char*)"NotLeftTriangleBar", {226, 167, 143, 204, 184, 0}},
+{(unsigned char*)"NotLeftTriangleEqual", {226, 139, 172, 0}},
+{(unsigned char*)"NotLess", {226, 137, 174, 0}},
+{(unsigned char*)"NotLessEqual", {226, 137, 176, 0}},
+{(unsigned char*)"NotLessGreater", {226, 137, 184, 0}},
+{(unsigned char*)"NotLessLess", {226, 137, 170, 204, 184, 0}},
+{(unsigned char*)"NotLessSlantEqual", {226, 169, 189, 204, 184, 0}},
+{(unsigned char*)"NotLessTilde", {226, 137, 180, 0}},
+{(unsigned char*)"NotNestedGreaterGreater", {226, 170, 162, 204, 184, 0}},
+{(unsigned char*)"NotNestedLessLess", {226, 170, 161, 204, 184, 0}},
+{(unsigned char*)"NotPrecedes", {226, 138, 128, 0}},
+{(unsigned char*)"NotPrecedesEqual", {226, 170, 175, 204, 184, 0}},
+{(unsigned char*)"NotPrecedesSlantEqual", {226, 139, 160, 0}},
+{(unsigned char*)"NotReverseElement", {226, 136, 140, 0}},
+{(unsigned char*)"NotRightTriangle", {226, 139, 171, 0}},
+{(unsigned char*)"NotRightTriangleBar", {226, 167, 144, 204, 184, 0}},
+{(unsigned char*)"NotRightTriangleEqual", {226, 139, 173, 0}},
+{(unsigned char*)"NotSquareSubset", {226, 138, 143, 204, 184, 0}},
+{(unsigned char*)"NotSquareSubsetEqual", {226, 139, 162, 0}},
+{(unsigned char*)"NotSquareSuperset", {226, 138, 144, 204, 184, 0}},
+{(unsigned char*)"NotSquareSupersetEqual", {226, 139, 163, 0}},
+{(unsigned char*)"NotSubset", {226, 138, 130, 226, 131, 146, 0}},
+{(unsigned char*)"NotSubsetEqual", {226, 138, 136, 0}},
+{(unsigned char*)"NotSucceeds", {226, 138, 129, 0}},
+{(unsigned char*)"NotSucceedsEqual", {226, 170, 176, 204, 184, 0}},
+{(unsigned char*)"NotSucceedsSlantEqual", {226, 139, 161, 0}},
+{(unsigned char*)"NotSucceedsTilde", {226, 137, 191, 204, 184, 0}},
+{(unsigned char*)"NotSuperset", {226, 138, 131, 226, 131, 146, 0}},
+{(unsigned char*)"NotSupersetEqual", {226, 138, 137, 0}},
+{(unsigned char*)"NotTilde", {226, 137, 129, 0}},
+{(unsigned char*)"NotTildeEqual", {226, 137, 132, 0}},
+{(unsigned char*)"NotTildeFullEqual", {226, 137, 135, 0}},
+{(unsigned char*)"NotTildeTilde", {226, 137, 137, 0}},
+{(unsigned char*)"NotVerticalBar", {226, 136, 164, 0}},
+{(unsigned char*)"Nscr", {240, 157, 146, 169, 0}},
+{(unsigned char*)"Ntilde", {195, 145, 0}},
+{(unsigned char*)"Nu", {206, 157, 0}},
+{(unsigned char*)"OElig", {197, 146, 0}},
+{(unsigned char*)"Oacute", {195, 147, 0}},
+{(unsigned char*)"Ocirc", {195, 148, 0}},
+{(unsigned char*)"Ocy", {208, 158, 0}},
+{(unsigned char*)"Odblac", {197, 144, 0}},
+{(unsigned char*)"Ofr", {240, 157, 148, 146, 0}},
+{(unsigned char*)"Ograve", {195, 146, 0}},
+{(unsigned char*)"Omacr", {197, 140, 0}},
+{(unsigned char*)"Omega", {206, 169, 0}},
+{(unsigned char*)"Omicron", {206, 159, 0}},
+{(unsigned char*)"Oopf", {240, 157, 149, 134, 0}},
+{(unsigned char*)"OpenCurlyDoubleQuote", {226, 128, 156, 0}},
+{(unsigned char*)"OpenCurlyQuote", {226, 128, 152, 0}},
+{(unsigned char*)"Or", {226, 169, 148, 0}},
+{(unsigned char*)"Oscr", {240, 157, 146, 170, 0}},
+{(unsigned char*)"Oslash", {195, 152, 0}},
+{(unsigned char*)"Otilde", {195, 149, 0}},
+{(unsigned char*)"Otimes", {226, 168, 183, 0}},
+{(unsigned char*)"Ouml", {195, 150, 0}},
+{(unsigned char*)"OverBar", {226, 128, 190, 0}},
+{(unsigned char*)"OverBrace", {226, 143, 158, 0}},
+{(unsigned char*)"OverBracket", {226, 142, 180, 0}},
+{(unsigned char*)"OverParenthesis", {226, 143, 156, 0}},
+{(unsigned char*)"PartialD", {226, 136, 130, 0}},
+{(unsigned char*)"Pcy", {208, 159, 0}},
+{(unsigned char*)"Pfr", {240, 157, 148, 147, 0}},
+{(unsigned char*)"Phi", {206, 166, 0}},
+{(unsigned char*)"Pi", {206, 160, 0}},
+{(unsigned char*)"PlusMinus", {194, 177, 0}},
+{(unsigned char*)"Poincareplane", {226, 132, 140, 0}},
+{(unsigned char*)"Popf", {226, 132, 153, 0}},
+{(unsigned char*)"Pr", {226, 170, 187, 0}},
+{(unsigned char*)"Precedes", {226, 137, 186, 0}},
+{(unsigned char*)"PrecedesEqual", {226, 170, 175, 0}},
+{(unsigned char*)"PrecedesSlantEqual", {226, 137, 188, 0}},
+{(unsigned char*)"PrecedesTilde", {226, 137, 190, 0}},
+{(unsigned char*)"Prime", {226, 128, 179, 0}},
+{(unsigned char*)"Product", {226, 136, 143, 0}},
+{(unsigned char*)"Proportion", {226, 136, 183, 0}},
+{(unsigned char*)"Proportional", {226, 136, 157, 0}},
+{(unsigned char*)"Pscr", {240, 157, 146, 171, 0}},
+{(unsigned char*)"Psi", {206, 168, 0}},
+{(unsigned char*)"QUOT", {34, 0}},
+{(unsigned char*)"Qfr", {240, 157, 148, 148, 0}},
+{(unsigned char*)"Qopf", {226, 132, 154, 0}},
+{(unsigned char*)"Qscr", {240, 157, 146, 172, 0}},
+{(unsigned char*)"RBarr", {226, 164, 144, 0}},
+{(unsigned char*)"REG", {194, 174, 0}},
+{(unsigned char*)"Racute", {197, 148, 0}},
+{(unsigned char*)"Rang", {226, 159, 171, 0}},
+{(unsigned char*)"Rarr", {226, 134, 160, 0}},
+{(unsigned char*)"Rarrtl", {226, 164, 150, 0}},
+{(unsigned char*)"Rcaron", {197, 152, 0}},
+{(unsigned char*)"Rcedil", {197, 150, 0}},
+{(unsigned char*)"Rcy", {208, 160, 0}},
+{(unsigned char*)"Re", {226, 132, 156, 0}},
+{(unsigned char*)"ReverseElement", {226, 136, 139, 0}},
+{(unsigned char*)"ReverseEquilibrium", {226, 135, 139, 0}},
+{(unsigned char*)"ReverseUpEquilibrium", {226, 165, 175, 0}},
+{(unsigned char*)"Rfr", {226, 132, 156, 0}},
+{(unsigned char*)"Rho", {206, 161, 0}},
+{(unsigned char*)"RightAngleBracket", {226, 159, 169, 0}},
+{(unsigned char*)"RightArrow", {226, 134, 146, 0}},
+{(unsigned char*)"RightArrowBar", {226, 135, 165, 0}},
+{(unsigned char*)"RightArrowLeftArrow", {226, 135, 132, 0}},
+{(unsigned char*)"RightCeiling", {226, 140, 137, 0}},
+{(unsigned char*)"RightDoubleBracket", {226, 159, 167, 0}},
+{(unsigned char*)"RightDownTeeVector", {226, 165, 157, 0}},
+{(unsigned char*)"RightDownVector", {226, 135, 130, 0}},
+{(unsigned char*)"RightDownVectorBar", {226, 165, 149, 0}},
+{(unsigned char*)"RightFloor", {226, 140, 139, 0}},
+{(unsigned char*)"RightTee", {226, 138, 162, 0}},
+{(unsigned char*)"RightTeeArrow", {226, 134, 166, 0}},
+{(unsigned char*)"RightTeeVector", {226, 165, 155, 0}},
+{(unsigned char*)"RightTriangle", {226, 138, 179, 0}},
+{(unsigned char*)"RightTriangleBar", {226, 167, 144, 0}},
+{(unsigned char*)"RightTriangleEqual", {226, 138, 181, 0}},
+{(unsigned char*)"RightUpDownVector", {226, 165, 143, 0}},
+{(unsigned char*)"RightUpTeeVector", {226, 165, 156, 0}},
+{(unsigned char*)"RightUpVector", {226, 134, 190, 0}},
+{(unsigned char*)"RightUpVectorBar", {226, 165, 148, 0}},
+{(unsigned char*)"RightVector", {226, 135, 128, 0}},
+{(unsigned char*)"RightVectorBar", {226, 165, 147, 0}},
+{(unsigned char*)"Rightarrow", {226, 135, 146, 0}},
+{(unsigned char*)"Ropf", {226, 132, 157, 0}},
+{(unsigned char*)"RoundImplies", {226, 165, 176, 0}},
+{(unsigned char*)"Rrightarrow", {226, 135, 155, 0}},
+{(unsigned char*)"Rscr", {226, 132, 155, 0}},
+{(unsigned char*)"Rsh", {226, 134, 177, 0}},
+{(unsigned char*)"RuleDelayed", {226, 167, 180, 0}},
+{(unsigned char*)"SHCHcy", {208, 169, 0}},
+{(unsigned char*)"SHcy", {208, 168, 0}},
+{(unsigned char*)"SOFTcy", {208, 172, 0}},
+{(unsigned char*)"Sacute", {197, 154, 0}},
+{(unsigned char*)"Sc", {226, 170, 188, 0}},
+{(unsigned char*)"Scaron", {197, 160, 0}},
+{(unsigned char*)"Scedil", {197, 158, 0}},
+{(unsigned char*)"Scirc", {197, 156, 0}},
+{(unsigned char*)"Scy", {208, 161, 0}},
+{(unsigned char*)"Sfr", {240, 157, 148, 150, 0}},
+{(unsigned char*)"ShortDownArrow", {226, 134, 147, 0}},
+{(unsigned char*)"ShortLeftArrow", {226, 134, 144, 0}},
+{(unsigned char*)"ShortRightArrow", {226, 134, 146, 0}},
+{(unsigned char*)"ShortUpArrow", {226, 134, 145, 0}},
+{(unsigned char*)"Sigma", {206, 163, 0}},
+{(unsigned char*)"SmallCircle", {226, 136, 152, 0}},
+{(unsigned char*)"Sopf", {240, 157, 149, 138, 0}},
+{(unsigned char*)"Sqrt", {226, 136, 154, 0}},
+{(unsigned char*)"Square", {226, 150, 161, 0}},
+{(unsigned char*)"SquareIntersection", {226, 138, 147, 0}},
+{(unsigned char*)"SquareSubset", {226, 138, 143, 0}},
+{(unsigned char*)"SquareSubsetEqual", {226, 138, 145, 0}},
+{(unsigned char*)"SquareSuperset", {226, 138, 144, 0}},
+{(unsigned char*)"SquareSupersetEqual", {226, 138, 146, 0}},
+{(unsigned char*)"SquareUnion", {226, 138, 148, 0}},
+{(unsigned char*)"Sscr", {240, 157, 146, 174, 0}},
+{(unsigned char*)"Star", {226, 139, 134, 0}},
+{(unsigned char*)"Sub", {226, 139, 144, 0}},
+{(unsigned char*)"Subset", {226, 139, 144, 0}},
+{(unsigned char*)"SubsetEqual", {226, 138, 134, 0}},
+{(unsigned char*)"Succeeds", {226, 137, 187, 0}},
+{(unsigned char*)"SucceedsEqual", {226, 170, 176, 0}},
+{(unsigned char*)"SucceedsSlantEqual", {226, 137, 189, 0}},
+{(unsigned char*)"SucceedsTilde", {226, 137, 191, 0}},
+{(unsigned char*)"SuchThat", {226, 136, 139, 0}},
+{(unsigned char*)"Sum", {226, 136, 145, 0}},
+{(unsigned char*)"Sup", {226, 139, 145, 0}},
+{(unsigned char*)"Superset", {226, 138, 131, 0}},
+{(unsigned char*)"SupersetEqual", {226, 138, 135, 0}},
+{(unsigned char*)"Supset", {226, 139, 145, 0}},
+{(unsigned char*)"THORN", {195, 158, 0}},
+{(unsigned char*)"TRADE", {226, 132, 162, 0}},
+{(unsigned char*)"TSHcy", {208, 139, 0}},
+{(unsigned char*)"TScy", {208, 166, 0}},
+{(unsigned char*)"Tab", {9, 0}},
+{(unsigned char*)"Tau", {206, 164, 0}},
+{(unsigned char*)"Tcaron", {197, 164, 0}},
+{(unsigned char*)"Tcedil", {197, 162, 0}},
+{(unsigned char*)"Tcy", {208, 162, 0}},
+{(unsigned char*)"Tfr", {240, 157, 148, 151, 0}},
+{(unsigned char*)"Therefore", {226, 136, 180, 0}},
+{(unsigned char*)"Theta", {206, 152, 0}},
+{(unsigned char*)"ThickSpace", {226, 129, 159, 226, 128, 138, 0}},
+{(unsigned char*)"ThinSpace", {226, 128, 137, 0}},
+{(unsigned char*)"Tilde", {226, 136, 188, 0}},
+{(unsigned char*)"TildeEqual", {226, 137, 131, 0}},
+{(unsigned char*)"TildeFullEqual", {226, 137, 133, 0}},
+{(unsigned char*)"TildeTilde", {226, 137, 136, 0}},
+{(unsigned char*)"Topf", {240, 157, 149, 139, 0}},
+{(unsigned char*)"TripleDot", {226, 131, 155, 0}},
+{(unsigned char*)"Tscr", {240, 157, 146, 175, 0}},
+{(unsigned char*)"Tstrok", {197, 166, 0}},
+{(unsigned char*)"Uacute", {195, 154, 0}},
+{(unsigned char*)"Uarr", {226, 134, 159, 0}},
+{(unsigned char*)"Uarrocir", {226, 165, 137, 0}},
+{(unsigned char*)"Ubrcy", {208, 142, 0}},
+{(unsigned char*)"Ubreve", {197, 172, 0}},
+{(unsigned char*)"Ucirc", {195, 155, 0}},
+{(unsigned char*)"Ucy", {208, 163, 0}},
+{(unsigned char*)"Udblac", {197, 176, 0}},
+{(unsigned char*)"Ufr", {240, 157, 148, 152, 0}},
+{(unsigned char*)"Ugrave", {195, 153, 0}},
+{(unsigned char*)"Umacr", {197, 170, 0}},
+{(unsigned char*)"UnderBar", {95, 0}},
+{(unsigned char*)"UnderBrace", {226, 143, 159, 0}},
+{(unsigned char*)"UnderBracket", {226, 142, 181, 0}},
+{(unsigned char*)"UnderParenthesis", {226, 143, 157, 0}},
+{(unsigned char*)"Union", {226, 139, 131, 0}},
+{(unsigned char*)"UnionPlus", {226, 138, 142, 0}},
+{(unsigned char*)"Uogon", {197, 178, 0}},
+{(unsigned char*)"Uopf", {240, 157, 149, 140, 0}},
+{(unsigned char*)"UpArrow", {226, 134, 145, 0}},
+{(unsigned char*)"UpArrowBar", {226, 164, 146, 0}},
+{(unsigned char*)"UpArrowDownArrow", {226, 135, 133, 0}},
+{(unsigned char*)"UpDownArrow", {226, 134, 149, 0}},
+{(unsigned char*)"UpEquilibrium", {226, 165, 174, 0}},
+{(unsigned char*)"UpTee", {226, 138, 165, 0}},
+{(unsigned char*)"UpTeeArrow", {226, 134, 165, 0}},
+{(unsigned char*)"Uparrow", {226, 135, 145, 0}},
+{(unsigned char*)"Updownarrow", {226, 135, 149, 0}},
+{(unsigned char*)"UpperLeftArrow", {226, 134, 150, 0}},
+{(unsigned char*)"UpperRightArrow", {226, 134, 151, 0}},
+{(unsigned char*)"Upsi", {207, 146, 0}},
+{(unsigned char*)"Upsilon", {206, 165, 0}},
+{(unsigned char*)"Uring", {197, 174, 0}},
+{(unsigned char*)"Uscr", {240, 157, 146, 176, 0}},
+{(unsigned char*)"Utilde", {197, 168, 0}},
+{(unsigned char*)"Uuml", {195, 156, 0}},
+{(unsigned char*)"VDash", {226, 138, 171, 0}},
+{(unsigned char*)"Vbar", {226, 171, 171, 0}},
+{(unsigned char*)"Vcy", {208, 146, 0}},
+{(unsigned char*)"Vdash", {226, 138, 169, 0}},
+{(unsigned char*)"Vdashl", {226, 171, 166, 0}},
+{(unsigned char*)"Vee", {226, 139, 129, 0}},
+{(unsigned char*)"Verbar", {226, 128, 150, 0}},
+{(unsigned char*)"Vert", {226, 128, 150, 0}},
+{(unsigned char*)"VerticalBar", {226, 136, 163, 0}},
+{(unsigned char*)"VerticalLine", {124, 0}},
+{(unsigned char*)"VerticalSeparator", {226, 157, 152, 0}},
+{(unsigned char*)"VerticalTilde", {226, 137, 128, 0}},
+{(unsigned char*)"VeryThinSpace", {226, 128, 138, 0}},
+{(unsigned char*)"Vfr", {240, 157, 148, 153, 0}},
+{(unsigned char*)"Vopf", {240, 157, 149, 141, 0}},
+{(unsigned char*)"Vscr", {240, 157, 146, 177, 0}},
+{(unsigned char*)"Vvdash", {226, 138, 170, 0}},
+{(unsigned char*)"Wcirc", {197, 180, 0}},
+{(unsigned char*)"Wedge", {226, 139, 128, 0}},
+{(unsigned char*)"Wfr", {240, 157, 148, 154, 0}},
+{(unsigned char*)"Wopf", {240, 157, 149, 142, 0}},
+{(unsigned char*)"Wscr", {240, 157, 146, 178, 0}},
+{(unsigned char*)"Xfr", {240, 157, 148, 155, 0}},
+{(unsigned char*)"Xi", {206, 158, 0}},
+{(unsigned char*)"Xopf", {240, 157, 149, 143, 0}},
+{(unsigned char*)"Xscr", {240, 157, 146, 179, 0}},
+{(unsigned char*)"YAcy", {208, 175, 0}},
+{(unsigned char*)"YIcy", {208, 135, 0}},
+{(unsigned char*)"YUcy", {208, 174, 0}},
+{(unsigned char*)"Yacute", {195, 157, 0}},
+{(unsigned char*)"Ycirc", {197, 182, 0}},
+{(unsigned char*)"Ycy", {208, 171, 0}},
+{(unsigned char*)"Yfr", {240, 157, 148, 156, 0}},
+{(unsigned char*)"Yopf", {240, 157, 149, 144, 0}},
+{(unsigned char*)"Yscr", {240, 157, 146, 180, 0}},
+{(unsigned char*)"Yuml", {197, 184, 0}},
+{(unsigned char*)"ZHcy", {208, 150, 0}},
+{(unsigned char*)"Zacute", {197, 185, 0}},
+{(unsigned char*)"Zcaron", {197, 189, 0}},
+{(unsigned char*)"Zcy", {208, 151, 0}},
+{(unsigned char*)"Zdot", {197, 187, 0}},
+{(unsigned char*)"ZeroWidthSpace", {226, 128, 139, 0}},
+{(unsigned char*)"Zeta", {206, 150, 0}},
+{(unsigned char*)"Zfr", {226, 132, 168, 0}},
+{(unsigned char*)"Zopf", {226, 132, 164, 0}},
+{(unsigned char*)"Zscr", {240, 157, 146, 181, 0}},
+{(unsigned char*)"aacute", {195, 161, 0}},
+{(unsigned char*)"abreve", {196, 131, 0}},
+{(unsigned char*)"ac", {226, 136, 190, 0}},
+{(unsigned char*)"acE", {226, 136, 190, 204, 179, 0}},
+{(unsigned char*)"acd", {226, 136, 191, 0}},
+{(unsigned char*)"acirc", {195, 162, 0}},
+{(unsigned char*)"acute", {194, 180, 0}},
+{(unsigned char*)"acy", {208, 176, 0}},
+{(unsigned char*)"aelig", {195, 166, 0}},
+{(unsigned char*)"af", {226, 129, 161, 0}},
+{(unsigned char*)"afr", {240, 157, 148, 158, 0}},
+{(unsigned char*)"agrave", {195, 160, 0}},
+{(unsigned char*)"alefsym", {226, 132, 181, 0}},
+{(unsigned char*)"aleph", {226, 132, 181, 0}},
+{(unsigned char*)"alpha", {206, 177, 0}},
+{(unsigned char*)"amacr", {196, 129, 0}},
+{(unsigned char*)"amalg", {226, 168, 191, 0}},
+{(unsigned char*)"amp", {38, 0}},
+{(unsigned char*)"and", {226, 136, 167, 0}},
+{(unsigned char*)"andand", {226, 169, 149, 0}},
+{(unsigned char*)"andd", {226, 169, 156, 0}},
+{(unsigned char*)"andslope", {226, 169, 152, 0}},
+{(unsigned char*)"andv", {226, 169, 154, 0}},
+{(unsigned char*)"ang", {226, 136, 160, 0}},
+{(unsigned char*)"ange", {226, 166, 164, 0}},
+{(unsigned char*)"angle", {226, 136, 160, 0}},
+{(unsigned char*)"angmsd", {226, 136, 161, 0}},
+{(unsigned char*)"angmsdaa", {226, 166, 168, 0}},
+{(unsigned char*)"angmsdab", {226, 166, 169, 0}},
+{(unsigned char*)"angmsdac", {226, 166, 170, 0}},
+{(unsigned char*)"angmsdad", {226, 166, 171, 0}},
+{(unsigned char*)"angmsdae", {226, 166, 172, 0}},
+{(unsigned char*)"angmsdaf", {226, 166, 173, 0}},
+{(unsigned char*)"angmsdag", {226, 166, 174, 0}},
+{(unsigned char*)"angmsdah", {226, 166, 175, 0}},
+{(unsigned char*)"angrt", {226, 136, 159, 0}},
+{(unsigned char*)"angrtvb", {226, 138, 190, 0}},
+{(unsigned char*)"angrtvbd", {226, 166, 157, 0}},
+{(unsigned char*)"angsph", {226, 136, 162, 0}},
+{(unsigned char*)"angst", {195, 133, 0}},
+{(unsigned char*)"angzarr", {226, 141, 188, 0}},
+{(unsigned char*)"aogon", {196, 133, 0}},
+{(unsigned char*)"aopf", {240, 157, 149, 146, 0}},
+{(unsigned char*)"ap", {226, 137, 136, 0}},
+{(unsigned char*)"apE", {226, 169, 176, 0}},
+{(unsigned char*)"apacir", {226, 169, 175, 0}},
+{(unsigned char*)"ape", {226, 137, 138, 0}},
+{(unsigned char*)"apid", {226, 137, 139, 0}},
+{(unsigned char*)"apos", {39, 0}},
+{(unsigned char*)"approx", {226, 137, 136, 0}},
+{(unsigned char*)"approxeq", {226, 137, 138, 0}},
+{(unsigned char*)"aring", {195, 165, 0}},
+{(unsigned char*)"ascr", {240, 157, 146, 182, 0}},
+{(unsigned char*)"ast", {42, 0}},
+{(unsigned char*)"asymp", {226, 137, 136, 0}},
+{(unsigned char*)"asympeq", {226, 137, 141, 0}},
+{(unsigned char*)"atilde", {195, 163, 0}},
+{(unsigned char*)"auml", {195, 164, 0}},
+{(unsigned char*)"awconint", {226, 136, 179, 0}},
+{(unsigned char*)"awint", {226, 168, 145, 0}},
+{(unsigned char*)"bNot", {226, 171, 173, 0}},
+{(unsigned char*)"backcong", {226, 137, 140, 0}},
+{(unsigned char*)"backepsilon", {207, 182, 0}},
+{(unsigned char*)"backprime", {226, 128, 181, 0}},
+{(unsigned char*)"backsim", {226, 136, 189, 0}},
+{(unsigned char*)"backsimeq", {226, 139, 141, 0}},
+{(unsigned char*)"barvee", {226, 138, 189, 0}},
+{(unsigned char*)"barwed", {226, 140, 133, 0}},
+{(unsigned char*)"barwedge", {226, 140, 133, 0}},
+{(unsigned char*)"bbrk", {226, 142, 181, 0}},
+{(unsigned char*)"bbrktbrk", {226, 142, 182, 0}},
+{(unsigned char*)"bcong", {226, 137, 140, 0}},
+{(unsigned char*)"bcy", {208, 177, 0}},
+{(unsigned char*)"bdquo", {226, 128, 158, 0}},
+{(unsigned char*)"becaus", {226, 136, 181, 0}},
+{(unsigned char*)"because", {226, 136, 181, 0}},
+{(unsigned char*)"bemptyv", {226, 166, 176, 0}},
+{(unsigned char*)"bepsi", {207, 182, 0}},
+{(unsigned char*)"bernou", {226, 132, 172, 0}},
+{(unsigned char*)"beta", {206, 178, 0}},
+{(unsigned char*)"beth", {226, 132, 182, 0}},
+{(unsigned char*)"between", {226, 137, 172, 0}},
+{(unsigned char*)"bfr", {240, 157, 148, 159, 0}},
+{(unsigned char*)"bigcap", {226, 139, 130, 0}},
+{(unsigned char*)"bigcirc", {226, 151, 175, 0}},
+{(unsigned char*)"bigcup", {226, 139, 131, 0}},
+{(unsigned char*)"bigodot", {226, 168, 128, 0}},
+{(unsigned char*)"bigoplus", {226, 168, 129, 0}},
+{(unsigned char*)"bigotimes", {226, 168, 130, 0}},
+{(unsigned char*)"bigsqcup", {226, 168, 134, 0}},
+{(unsigned char*)"bigstar", {226, 152, 133, 0}},
+{(unsigned char*)"bigtriangledown", {226, 150, 189, 0}},
+{(unsigned char*)"bigtriangleup", {226, 150, 179, 0}},
+{(unsigned char*)"biguplus", {226, 168, 132, 0}},
+{(unsigned char*)"bigvee", {226, 139, 129, 0}},
+{(unsigned char*)"bigwedge", {226, 139, 128, 0}},
+{(unsigned char*)"bkarow", {226, 164, 141, 0}},
+{(unsigned char*)"blacklozenge", {226, 167, 171, 0}},
+{(unsigned char*)"blacksquare", {226, 150, 170, 0}},
+{(unsigned char*)"blacktriangle", {226, 150, 180, 0}},
+{(unsigned char*)"blacktriangledown", {226, 150, 190, 0}},
+{(unsigned char*)"blacktriangleleft", {226, 151, 130, 0}},
+{(unsigned char*)"blacktriangleright", {226, 150, 184, 0}},
+{(unsigned char*)"blank", {226, 144, 163, 0}},
+{(unsigned char*)"blk12", {226, 150, 146, 0}},
+{(unsigned char*)"blk14", {226, 150, 145, 0}},
+{(unsigned char*)"blk34", {226, 150, 147, 0}},
+{(unsigned char*)"block", {226, 150, 136, 0}},
+{(unsigned char*)"bne", {61, 226, 131, 165, 0}},
+{(unsigned char*)"bnequiv", {226, 137, 161, 226, 131, 165, 0}},
+{(unsigned char*)"bnot", {226, 140, 144, 0}},
+{(unsigned char*)"bopf", {240, 157, 149, 147, 0}},
+{(unsigned char*)"bot", {226, 138, 165, 0}},
+{(unsigned char*)"bottom", {226, 138, 165, 0}},
+{(unsigned char*)"bowtie", {226, 139, 136, 0}},
+{(unsigned char*)"boxDL", {226, 149, 151, 0}},
+{(unsigned char*)"boxDR", {226, 149, 148, 0}},
+{(unsigned char*)"boxDl", {226, 149, 150, 0}},
+{(unsigned char*)"boxDr", {226, 149, 147, 0}},
+{(unsigned char*)"boxH", {226, 149, 144, 0}},
+{(unsigned char*)"boxHD", {226, 149, 166, 0}},
+{(unsigned char*)"boxHU", {226, 149, 169, 0}},
+{(unsigned char*)"boxHd", {226, 149, 164, 0}},
+{(unsigned char*)"boxHu", {226, 149, 167, 0}},
+{(unsigned char*)"boxUL", {226, 149, 157, 0}},
+{(unsigned char*)"boxUR", {226, 149, 154, 0}},
+{(unsigned char*)"boxUl", {226, 149, 156, 0}},
+{(unsigned char*)"boxUr", {226, 149, 153, 0}},
+{(unsigned char*)"boxV", {226, 149, 145, 0}},
+{(unsigned char*)"boxVH", {226, 149, 172, 0}},
+{(unsigned char*)"boxVL", {226, 149, 163, 0}},
+{(unsigned char*)"boxVR", {226, 149, 160, 0}},
+{(unsigned char*)"boxVh", {226, 149, 171, 0}},
+{(unsigned char*)"boxVl", {226, 149, 162, 0}},
+{(unsigned char*)"boxVr", {226, 149, 159, 0}},
+{(unsigned char*)"boxbox", {226, 167, 137, 0}},
+{(unsigned char*)"boxdL", {226, 149, 149, 0}},
+{(unsigned char*)"boxdR", {226, 149, 146, 0}},
+{(unsigned char*)"boxdl", {226, 148, 144, 0}},
+{(unsigned char*)"boxdr", {226, 148, 140, 0}},
+{(unsigned char*)"boxh", {226, 148, 128, 0}},
+{(unsigned char*)"boxhD", {226, 149, 165, 0}},
+{(unsigned char*)"boxhU", {226, 149, 168, 0}},
+{(unsigned char*)"boxhd", {226, 148, 172, 0}},
+{(unsigned char*)"boxhu", {226, 148, 180, 0}},
+{(unsigned char*)"boxminus", {226, 138, 159, 0}},
+{(unsigned char*)"boxplus", {226, 138, 158, 0}},
+{(unsigned char*)"boxtimes", {226, 138, 160, 0}},
+{(unsigned char*)"boxuL", {226, 149, 155, 0}},
+{(unsigned char*)"boxuR", {226, 149, 152, 0}},
+{(unsigned char*)"boxul", {226, 148, 152, 0}},
+{(unsigned char*)"boxur", {226, 148, 148, 0}},
+{(unsigned char*)"boxv", {226, 148, 130, 0}},
+{(unsigned char*)"boxvH", {226, 149, 170, 0}},
+{(unsigned char*)"boxvL", {226, 149, 161, 0}},
+{(unsigned char*)"boxvR", {226, 149, 158, 0}},
+{(unsigned char*)"boxvh", {226, 148, 188, 0}},
+{(unsigned char*)"boxvl", {226, 148, 164, 0}},
+{(unsigned char*)"boxvr", {226, 148, 156, 0}},
+{(unsigned char*)"bprime", {226, 128, 181, 0}},
+{(unsigned char*)"breve", {203, 152, 0}},
+{(unsigned char*)"brvbar", {194, 166, 0}},
+{(unsigned char*)"bscr", {240, 157, 146, 183, 0}},
+{(unsigned char*)"bsemi", {226, 129, 143, 0}},
+{(unsigned char*)"bsim", {226, 136, 189, 0}},
+{(unsigned char*)"bsime", {226, 139, 141, 0}},
+{(unsigned char*)"bsol", {92, 0}},
+{(unsigned char*)"bsolb", {226, 167, 133, 0}},
+{(unsigned char*)"bsolhsub", {226, 159, 136, 0}},
+{(unsigned char*)"bull", {226, 128, 162, 0}},
+{(unsigned char*)"bullet", {226, 128, 162, 0}},
+{(unsigned char*)"bump", {226, 137, 142, 0}},
+{(unsigned char*)"bumpE", {226, 170, 174, 0}},
+{(unsigned char*)"bumpe", {226, 137, 143, 0}},
+{(unsigned char*)"bumpeq", {226, 137, 143, 0}},
+{(unsigned char*)"cacute", {196, 135, 0}},
+{(unsigned char*)"cap", {226, 136, 169, 0}},
+{(unsigned char*)"capand", {226, 169, 132, 0}},
+{(unsigned char*)"capbrcup", {226, 169, 137, 0}},
+{(unsigned char*)"capcap", {226, 169, 139, 0}},
+{(unsigned char*)"capcup", {226, 169, 135, 0}},
+{(unsigned char*)"capdot", {226, 169, 128, 0}},
+{(unsigned char*)"caps", {226, 136, 169, 239, 184, 128, 0}},
+{(unsigned char*)"caret", {226, 129, 129, 0}},
+{(unsigned char*)"caron", {203, 135, 0}},
+{(unsigned char*)"ccaps", {226, 169, 141, 0}},
+{(unsigned char*)"ccaron", {196, 141, 0}},
+{(unsigned char*)"ccedil", {195, 167, 0}},
+{(unsigned char*)"ccirc", {196, 137, 0}},
+{(unsigned char*)"ccups", {226, 169, 140, 0}},
+{(unsigned char*)"ccupssm", {226, 169, 144, 0}},
+{(unsigned char*)"cdot", {196, 139, 0}},
+{(unsigned char*)"cedil", {194, 184, 0}},
+{(unsigned char*)"cemptyv", {226, 166, 178, 0}},
+{(unsigned char*)"cent", {194, 162, 0}},
+{(unsigned char*)"centerdot", {194, 183, 0}},
+{(unsigned char*)"cfr", {240, 157, 148, 160, 0}},
+{(unsigned char*)"chcy", {209, 135, 0}},
+{(unsigned char*)"check", {226, 156, 147, 0}},
+{(unsigned char*)"checkmark", {226, 156, 147, 0}},
+{(unsigned char*)"chi", {207, 135, 0}},
+{(unsigned char*)"cir", {226, 151, 139, 0}},
+{(unsigned char*)"cirE", {226, 167, 131, 0}},
+{(unsigned char*)"circ", {203, 134, 0}},
+{(unsigned char*)"circeq", {226, 137, 151, 0}},
+{(unsigned char*)"circlearrowleft", {226, 134, 186, 0}},
+{(unsigned char*)"circlearrowright", {226, 134, 187, 0}},
+{(unsigned char*)"circledR", {194, 174, 0}},
+{(unsigned char*)"circledS", {226, 147, 136, 0}},
+{(unsigned char*)"circledast", {226, 138, 155, 0}},
+{(unsigned char*)"circledcirc", {226, 138, 154, 0}},
+{(unsigned char*)"circleddash", {226, 138, 157, 0}},
+{(unsigned char*)"cire", {226, 137, 151, 0}},
+{(unsigned char*)"cirfnint", {226, 168, 144, 0}},
+{(unsigned char*)"cirmid", {226, 171, 175, 0}},
+{(unsigned char*)"cirscir", {226, 167, 130, 0}},
+{(unsigned char*)"clubs", {226, 153, 163, 0}},
+{(unsigned char*)"clubsuit", {226, 153, 163, 0}},
+{(unsigned char*)"colon", {58, 0}},
+{(unsigned char*)"colone", {226, 137, 148, 0}},
+{(unsigned char*)"coloneq", {226, 137, 148, 0}},
+{(unsigned char*)"comma", {44, 0}},
+{(unsigned char*)"commat", {64, 0}},
+{(unsigned char*)"comp", {226, 136, 129, 0}},
+{(unsigned char*)"compfn", {226, 136, 152, 0}},
+{(unsigned char*)"complement", {226, 136, 129, 0}},
+{(unsigned char*)"complexes", {226, 132, 130, 0}},
+{(unsigned char*)"cong", {226, 137, 133, 0}},
+{(unsigned char*)"congdot", {226, 169, 173, 0}},
+{(unsigned char*)"conint", {226, 136, 174, 0}},
+{(unsigned char*)"copf", {240, 157, 149, 148, 0}},
+{(unsigned char*)"coprod", {226, 136, 144, 0}},
+{(unsigned char*)"copy", {194, 169, 0}},
+{(unsigned char*)"copysr", {226, 132, 151, 0}},
+{(unsigned char*)"crarr", {226, 134, 181, 0}},
+{(unsigned char*)"cross", {226, 156, 151, 0}},
+{(unsigned char*)"cscr", {240, 157, 146, 184, 0}},
+{(unsigned char*)"csub", {226, 171, 143, 0}},
+{(unsigned char*)"csube", {226, 171, 145, 0}},
+{(unsigned char*)"csup", {226, 171, 144, 0}},
+{(unsigned char*)"csupe", {226, 171, 146, 0}},
+{(unsigned char*)"ctdot", {226, 139, 175, 0}},
+{(unsigned char*)"cudarrl", {226, 164, 184, 0}},
+{(unsigned char*)"cudarrr", {226, 164, 181, 0}},
+{(unsigned char*)"cuepr", {226, 139, 158, 0}},
+{(unsigned char*)"cuesc", {226, 139, 159, 0}},
+{(unsigned char*)"cularr", {226, 134, 182, 0}},
+{(unsigned char*)"cularrp", {226, 164, 189, 0}},
+{(unsigned char*)"cup", {226, 136, 170, 0}},
+{(unsigned char*)"cupbrcap", {226, 169, 136, 0}},
+{(unsigned char*)"cupcap", {226, 169, 134, 0}},
+{(unsigned char*)"cupcup", {226, 169, 138, 0}},
+{(unsigned char*)"cupdot", {226, 138, 141, 0}},
+{(unsigned char*)"cupor", {226, 169, 133, 0}},
+{(unsigned char*)"cups", {226, 136, 170, 239, 184, 128, 0}},
+{(unsigned char*)"curarr", {226, 134, 183, 0}},
+{(unsigned char*)"curarrm", {226, 164, 188, 0}},
+{(unsigned char*)"curlyeqprec", {226, 139, 158, 0}},
+{(unsigned char*)"curlyeqsucc", {226, 139, 159, 0}},
+{(unsigned char*)"curlyvee", {226, 139, 142, 0}},
+{(unsigned char*)"curlywedge", {226, 139, 143, 0}},
+{(unsigned char*)"curren", {194, 164, 0}},
+{(unsigned char*)"curvearrowleft", {226, 134, 182, 0}},
+{(unsigned char*)"curvearrowright", {226, 134, 183, 0}},
+{(unsigned char*)"cuvee", {226, 139, 142, 0}},
+{(unsigned char*)"cuwed", {226, 139, 143, 0}},
+{(unsigned char*)"cwconint", {226, 136, 178, 0}},
+{(unsigned char*)"cwint", {226, 136, 177, 0}},
+{(unsigned char*)"cylcty", {226, 140, 173, 0}},
+{(unsigned char*)"dArr", {226, 135, 147, 0}},
+{(unsigned char*)"dHar", {226, 165, 165, 0}},
+{(unsigned char*)"dagger", {226, 128, 160, 0}},
+{(unsigned char*)"daleth", {226, 132, 184, 0}},
+{(unsigned char*)"darr", {226, 134, 147, 0}},
+{(unsigned char*)"dash", {226, 128, 144, 0}},
+{(unsigned char*)"dashv", {226, 138, 163, 0}},
+{(unsigned char*)"dbkarow", {226, 164, 143, 0}},
+{(unsigned char*)"dblac", {203, 157, 0}},
+{(unsigned char*)"dcaron", {196, 143, 0}},
+{(unsigned char*)"dcy", {208, 180, 0}},
+{(unsigned char*)"dd", {226, 133, 134, 0}},
+{(unsigned char*)"ddagger", {226, 128, 161, 0}},
+{(unsigned char*)"ddarr", {226, 135, 138, 0}},
+{(unsigned char*)"ddotseq", {226, 169, 183, 0}},
+{(unsigned char*)"deg", {194, 176, 0}},
+{(unsigned char*)"delta", {206, 180, 0}},
+{(unsigned char*)"demptyv", {226, 166, 177, 0}},
+{(unsigned char*)"dfisht", {226, 165, 191, 0}},
+{(unsigned char*)"dfr", {240, 157, 148, 161, 0}},
+{(unsigned char*)"dharl", {226, 135, 131, 0}},
+{(unsigned char*)"dharr", {226, 135, 130, 0}},
+{(unsigned char*)"diam", {226, 139, 132, 0}},
+{(unsigned char*)"diamond", {226, 139, 132, 0}},
+{(unsigned char*)"diamondsuit", {226, 153, 166, 0}},
+{(unsigned char*)"diams", {226, 153, 166, 0}},
+{(unsigned char*)"die", {194, 168, 0}},
+{(unsigned char*)"digamma", {207, 157, 0}},
+{(unsigned char*)"disin", {226, 139, 178, 0}},
+{(unsigned char*)"div", {195, 183, 0}},
+{(unsigned char*)"divide", {195, 183, 0}},
+{(unsigned char*)"divideontimes", {226, 139, 135, 0}},
+{(unsigned char*)"divonx", {226, 139, 135, 0}},
+{(unsigned char*)"djcy", {209, 146, 0}},
+{(unsigned char*)"dlcorn", {226, 140, 158, 0}},
+{(unsigned char*)"dlcrop", {226, 140, 141, 0}},
+{(unsigned char*)"dollar", {36, 0}},
+{(unsigned char*)"dopf", {240, 157, 149, 149, 0}},
+{(unsigned char*)"dot", {203, 153, 0}},
+{(unsigned char*)"doteq", {226, 137, 144, 0}},
+{(unsigned char*)"doteqdot", {226, 137, 145, 0}},
+{(unsigned char*)"dotminus", {226, 136, 184, 0}},
+{(unsigned char*)"dotplus", {226, 136, 148, 0}},
+{(unsigned char*)"dotsquare", {226, 138, 161, 0}},
+{(unsigned char*)"doublebarwedge", {226, 140, 134, 0}},
+{(unsigned char*)"downarrow", {226, 134, 147, 0}},
+{(unsigned char*)"downdownarrows", {226, 135, 138, 0}},
+{(unsigned char*)"downharpoonleft", {226, 135, 131, 0}},
+{(unsigned char*)"downharpoonright", {226, 135, 130, 0}},
+{(unsigned char*)"drbkarow", {226, 164, 144, 0}},
+{(unsigned char*)"drcorn", {226, 140, 159, 0}},
+{(unsigned char*)"drcrop", {226, 140, 140, 0}},
+{(unsigned char*)"dscr", {240, 157, 146, 185, 0}},
+{(unsigned char*)"dscy", {209, 149, 0}},
+{(unsigned char*)"dsol", {226, 167, 182, 0}},
+{(unsigned char*)"dstrok", {196, 145, 0}},
+{(unsigned char*)"dtdot", {226, 139, 177, 0}},
+{(unsigned char*)"dtri", {226, 150, 191, 0}},
+{(unsigned char*)"dtrif", {226, 150, 190, 0}},
+{(unsigned char*)"duarr", {226, 135, 181, 0}},
+{(unsigned char*)"duhar", {226, 165, 175, 0}},
+{(unsigned char*)"dwangle", {226, 166, 166, 0}},
+{(unsigned char*)"dzcy", {209, 159, 0}},
+{(unsigned char*)"dzigrarr", {226, 159, 191, 0}},
+{(unsigned char*)"eDDot", {226, 169, 183, 0}},
+{(unsigned char*)"eDot", {226, 137, 145, 0}},
+{(unsigned char*)"eacute", {195, 169, 0}},
+{(unsigned char*)"easter", {226, 169, 174, 0}},
+{(unsigned char*)"ecaron", {196, 155, 0}},
+{(unsigned char*)"ecir", {226, 137, 150, 0}},
+{(unsigned char*)"ecirc", {195, 170, 0}},
+{(unsigned char*)"ecolon", {226, 137, 149, 0}},
+{(unsigned char*)"ecy", {209, 141, 0}},
+{(unsigned char*)"edot", {196, 151, 0}},
+{(unsigned char*)"ee", {226, 133, 135, 0}},
+{(unsigned char*)"efDot", {226, 137, 146, 0}},
+{(unsigned char*)"efr", {240, 157, 148, 162, 0}},
+{(unsigned char*)"eg", {226, 170, 154, 0}},
+{(unsigned char*)"egrave", {195, 168, 0}},
+{(unsigned char*)"egs", {226, 170, 150, 0}},
+{(unsigned char*)"egsdot", {226, 170, 152, 0}},
+{(unsigned char*)"el", {226, 170, 153, 0}},
+{(unsigned char*)"elinters", {226, 143, 167, 0}},
+{(unsigned char*)"ell", {226, 132, 147, 0}},
+{(unsigned char*)"els", {226, 170, 149, 0}},
+{(unsigned char*)"elsdot", {226, 170, 151, 0}},
+{(unsigned char*)"emacr", {196, 147, 0}},
+{(unsigned char*)"empty", {226, 136, 133, 0}},
+{(unsigned char*)"emptyset", {226, 136, 133, 0}},
+{(unsigned char*)"emptyv", {226, 136, 133, 0}},
+{(unsigned char*)"emsp", {226, 128, 131, 0}},
+{(unsigned char*)"emsp13", {226, 128, 132, 0}},
+{(unsigned char*)"emsp14", {226, 128, 133, 0}},
+{(unsigned char*)"eng", {197, 139, 0}},
+{(unsigned char*)"ensp", {226, 128, 130, 0}},
+{(unsigned char*)"eogon", {196, 153, 0}},
+{(unsigned char*)"eopf", {240, 157, 149, 150, 0}},
+{(unsigned char*)"epar", {226, 139, 149, 0}},
+{(unsigned char*)"eparsl", {226, 167, 163, 0}},
+{(unsigned char*)"eplus", {226, 169, 177, 0}},
+{(unsigned char*)"epsi", {206, 181, 0}},
+{(unsigned char*)"epsilon", {206, 181, 0}},
+{(unsigned char*)"epsiv", {207, 181, 0}},
+{(unsigned char*)"eqcirc", {226, 137, 150, 0}},
+{(unsigned char*)"eqcolon", {226, 137, 149, 0}},
+{(unsigned char*)"eqsim", {226, 137, 130, 0}},
+{(unsigned char*)"eqslantgtr", {226, 170, 150, 0}},
+{(unsigned char*)"eqslantless", {226, 170, 149, 0}},
+{(unsigned char*)"equals", {61, 0}},
+{(unsigned char*)"equest", {226, 137, 159, 0}},
+{(unsigned char*)"equiv", {226, 137, 161, 0}},
+{(unsigned char*)"equivDD", {226, 169, 184, 0}},
+{(unsigned char*)"eqvparsl", {226, 167, 165, 0}},
+{(unsigned char*)"erDot", {226, 137, 147, 0}},
+{(unsigned char*)"erarr", {226, 165, 177, 0}},
+{(unsigned char*)"escr", {226, 132, 175, 0}},
+{(unsigned char*)"esdot", {226, 137, 144, 0}},
+{(unsigned char*)"esim", {226, 137, 130, 0}},
+{(unsigned char*)"eta", {206, 183, 0}},
+{(unsigned char*)"eth", {195, 176, 0}},
+{(unsigned char*)"euml", {195, 171, 0}},
+{(unsigned char*)"euro", {226, 130, 172, 0}},
+{(unsigned char*)"excl", {33, 0}},
+{(unsigned char*)"exist", {226, 136, 131, 0}},
+{(unsigned char*)"expectation", {226, 132, 176, 0}},
+{(unsigned char*)"exponentiale", {226, 133, 135, 0}},
+{(unsigned char*)"fallingdotseq", {226, 137, 146, 0}},
+{(unsigned char*)"fcy", {209, 132, 0}},
+{(unsigned char*)"female", {226, 153, 128, 0}},
+{(unsigned char*)"ffilig", {239, 172, 131, 0}},
+{(unsigned char*)"fflig", {239, 172, 128, 0}},
+{(unsigned char*)"ffllig", {239, 172, 132, 0}},
+{(unsigned char*)"ffr", {240, 157, 148, 163, 0}},
+{(unsigned char*)"filig", {239, 172, 129, 0}},
+{(unsigned char*)"fjlig", {102, 106, 0}},
+{(unsigned char*)"flat", {226, 153, 173, 0}},
+{(unsigned char*)"fllig", {239, 172, 130, 0}},
+{(unsigned char*)"fltns", {226, 150, 177, 0}},
+{(unsigned char*)"fnof", {198, 146, 0}},
+{(unsigned char*)"fopf", {240, 157, 149, 151, 0}},
+{(unsigned char*)"forall", {226, 136, 128, 0}},
+{(unsigned char*)"fork", {226, 139, 148, 0}},
+{(unsigned char*)"forkv", {226, 171, 153, 0}},
+{(unsigned char*)"fpartint", {226, 168, 141, 0}},
+{(unsigned char*)"frac12", {194, 189, 0}},
+{(unsigned char*)"frac13", {226, 133, 147, 0}},
+{(unsigned char*)"frac14", {194, 188, 0}},
+{(unsigned char*)"frac15", {226, 133, 149, 0}},
+{(unsigned char*)"frac16", {226, 133, 153, 0}},
+{(unsigned char*)"frac18", {226, 133, 155, 0}},
+{(unsigned char*)"frac23", {226, 133, 148, 0}},
+{(unsigned char*)"frac25", {226, 133, 150, 0}},
+{(unsigned char*)"frac34", {194, 190, 0}},
+{(unsigned char*)"frac35", {226, 133, 151, 0}},
+{(unsigned char*)"frac38", {226, 133, 156, 0}},
+{(unsigned char*)"frac45", {226, 133, 152, 0}},
+{(unsigned char*)"frac56", {226, 133, 154, 0}},
+{(unsigned char*)"frac58", {226, 133, 157, 0}},
+{(unsigned char*)"frac78", {226, 133, 158, 0}},
+{(unsigned char*)"frasl", {226, 129, 132, 0}},
+{(unsigned char*)"frown", {226, 140, 162, 0}},
+{(unsigned char*)"fscr", {240, 157, 146, 187, 0}},
+{(unsigned char*)"gE", {226, 137, 167, 0}},
+{(unsigned char*)"gEl", {226, 170, 140, 0}},
+{(unsigned char*)"gacute", {199, 181, 0}},
+{(unsigned char*)"gamma", {206, 179, 0}},
+{(unsigned char*)"gammad", {207, 157, 0}},
+{(unsigned char*)"gap", {226, 170, 134, 0}},
+{(unsigned char*)"gbreve", {196, 159, 0}},
+{(unsigned char*)"gcirc", {196, 157, 0}},
+{(unsigned char*)"gcy", {208, 179, 0}},
+{(unsigned char*)"gdot", {196, 161, 0}},
+{(unsigned char*)"ge", {226, 137, 165, 0}},
+{(unsigned char*)"gel", {226, 139, 155, 0}},
+{(unsigned char*)"geq", {226, 137, 165, 0}},
+{(unsigned char*)"geqq", {226, 137, 167, 0}},
+{(unsigned char*)"geqslant", {226, 169, 190, 0}},
+{(unsigned char*)"ges", {226, 169, 190, 0}},
+{(unsigned char*)"gescc", {226, 170, 169, 0}},
+{(unsigned char*)"gesdot", {226, 170, 128, 0}},
+{(unsigned char*)"gesdoto", {226, 170, 130, 0}},
+{(unsigned char*)"gesdotol", {226, 170, 132, 0}},
+{(unsigned char*)"gesl", {226, 139, 155, 239, 184, 128, 0}},
+{(unsigned char*)"gesles", {226, 170, 148, 0}},
+{(unsigned char*)"gfr", {240, 157, 148, 164, 0}},
+{(unsigned char*)"gg", {226, 137, 171, 0}},
+{(unsigned char*)"ggg", {226, 139, 153, 0}},
+{(unsigned char*)"gimel", {226, 132, 183, 0}},
+{(unsigned char*)"gjcy", {209, 147, 0}},
+{(unsigned char*)"gl", {226, 137, 183, 0}},
+{(unsigned char*)"glE", {226, 170, 146, 0}},
+{(unsigned char*)"gla", {226, 170, 165, 0}},
+{(unsigned char*)"glj", {226, 170, 164, 0}},
+{(unsigned char*)"gnE", {226, 137, 169, 0}},
+{(unsigned char*)"gnap", {226, 170, 138, 0}},
+{(unsigned char*)"gnapprox", {226, 170, 138, 0}},
+{(unsigned char*)"gne", {226, 170, 136, 0}},
+{(unsigned char*)"gneq", {226, 170, 136, 0}},
+{(unsigned char*)"gneqq", {226, 137, 169, 0}},
+{(unsigned char*)"gnsim", {226, 139, 167, 0}},
+{(unsigned char*)"gopf", {240, 157, 149, 152, 0}},
+{(unsigned char*)"grave", {96, 0}},
+{(unsigned char*)"gscr", {226, 132, 138, 0}},
+{(unsigned char*)"gsim", {226, 137, 179, 0}},
+{(unsigned char*)"gsime", {226, 170, 142, 0}},
+{(unsigned char*)"gsiml", {226, 170, 144, 0}},
+{(unsigned char*)"gt", {62, 0}},
+{(unsigned char*)"gtcc", {226, 170, 167, 0}},
+{(unsigned char*)"gtcir", {226, 169, 186, 0}},
+{(unsigned char*)"gtdot", {226, 139, 151, 0}},
+{(unsigned char*)"gtlPar", {226, 166, 149, 0}},
+{(unsigned char*)"gtquest", {226, 169, 188, 0}},
+{(unsigned char*)"gtrapprox", {226, 170, 134, 0}},
+{(unsigned char*)"gtrarr", {226, 165, 184, 0}},
+{(unsigned char*)"gtrdot", {226, 139, 151, 0}},
+{(unsigned char*)"gtreqless", {226, 139, 155, 0}},
+{(unsigned char*)"gtreqqless", {226, 170, 140, 0}},
+{(unsigned char*)"gtrless", {226, 137, 183, 0}},
+{(unsigned char*)"gtrsim", {226, 137, 179, 0}},
+{(unsigned char*)"gvertneqq", {226, 137, 169, 239, 184, 128, 0}},
+{(unsigned char*)"gvnE", {226, 137, 169, 239, 184, 128, 0}},
+{(unsigned char*)"hArr", {226, 135, 148, 0}},
+{(unsigned char*)"hairsp", {226, 128, 138, 0}},
+{(unsigned char*)"half", {194, 189, 0}},
+{(unsigned char*)"hamilt", {226, 132, 139, 0}},
+{(unsigned char*)"hardcy", {209, 138, 0}},
+{(unsigned char*)"harr", {226, 134, 148, 0}},
+{(unsigned char*)"harrcir", {226, 165, 136, 0}},
+{(unsigned char*)"harrw", {226, 134, 173, 0}},
+{(unsigned char*)"hbar", {226, 132, 143, 0}},
+{(unsigned char*)"hcirc", {196, 165, 0}},
+{(unsigned char*)"hearts", {226, 153, 165, 0}},
+{(unsigned char*)"heartsuit", {226, 153, 165, 0}},
+{(unsigned char*)"hellip", {226, 128, 166, 0}},
+{(unsigned char*)"hercon", {226, 138, 185, 0}},
+{(unsigned char*)"hfr", {240, 157, 148, 165, 0}},
+{(unsigned char*)"hksearow", {226, 164, 165, 0}},
+{(unsigned char*)"hkswarow", {226, 164, 166, 0}},
+{(unsigned char*)"hoarr", {226, 135, 191, 0}},
+{(unsigned char*)"homtht", {226, 136, 187, 0}},
+{(unsigned char*)"hookleftarrow", {226, 134, 169, 0}},
+{(unsigned char*)"hookrightarrow", {226, 134, 170, 0}},
+{(unsigned char*)"hopf", {240, 157, 149, 153, 0}},
+{(unsigned char*)"horbar", {226, 128, 149, 0}},
+{(unsigned char*)"hscr", {240, 157, 146, 189, 0}},
+{(unsigned char*)"hslash", {226, 132, 143, 0}},
+{(unsigned char*)"hstrok", {196, 167, 0}},
+{(unsigned char*)"hybull", {226, 129, 131, 0}},
+{(unsigned char*)"hyphen", {226, 128, 144, 0}},
+{(unsigned char*)"iacute", {195, 173, 0}},
+{(unsigned char*)"ic", {226, 129, 163, 0}},
+{(unsigned char*)"icirc", {195, 174, 0}},
+{(unsigned char*)"icy", {208, 184, 0}},
+{(unsigned char*)"iecy", {208, 181, 0}},
+{(unsigned char*)"iexcl", {194, 161, 0}},
+{(unsigned char*)"iff", {226, 135, 148, 0}},
+{(unsigned char*)"ifr", {240, 157, 148, 166, 0}},
+{(unsigned char*)"igrave", {195, 172, 0}},
+{(unsigned char*)"ii", {226, 133, 136, 0}},
+{(unsigned char*)"iiiint", {226, 168, 140, 0}},
+{(unsigned char*)"iiint", {226, 136, 173, 0}},
+{(unsigned char*)"iinfin", {226, 167, 156, 0}},
+{(unsigned char*)"iiota", {226, 132, 169, 0}},
+{(unsigned char*)"ijlig", {196, 179, 0}},
+{(unsigned char*)"imacr", {196, 171, 0}},
+{(unsigned char*)"image", {226, 132, 145, 0}},
+{(unsigned char*)"imagline", {226, 132, 144, 0}},
+{(unsigned char*)"imagpart", {226, 132, 145, 0}},
+{(unsigned char*)"imath", {196, 177, 0}},
+{(unsigned char*)"imof", {226, 138, 183, 0}},
+{(unsigned char*)"imped", {198, 181, 0}},
+{(unsigned char*)"in", {226, 136, 136, 0}},
+{(unsigned char*)"incare", {226, 132, 133, 0}},
+{(unsigned char*)"infin", {226, 136, 158, 0}},
+{(unsigned char*)"infintie", {226, 167, 157, 0}},
+{(unsigned char*)"inodot", {196, 177, 0}},
+{(unsigned char*)"int", {226, 136, 171, 0}},
+{(unsigned char*)"intcal", {226, 138, 186, 0}},
+{(unsigned char*)"integers", {226, 132, 164, 0}},
+{(unsigned char*)"intercal", {226, 138, 186, 0}},
+{(unsigned char*)"intlarhk", {226, 168, 151, 0}},
+{(unsigned char*)"intprod", {226, 168, 188, 0}},
+{(unsigned char*)"iocy", {209, 145, 0}},
+{(unsigned char*)"iogon", {196, 175, 0}},
+{(unsigned char*)"iopf", {240, 157, 149, 154, 0}},
+{(unsigned char*)"iota", {206, 185, 0}},
+{(unsigned char*)"iprod", {226, 168, 188, 0}},
+{(unsigned char*)"iquest", {194, 191, 0}},
+{(unsigned char*)"iscr", {240, 157, 146, 190, 0}},
+{(unsigned char*)"isin", {226, 136, 136, 0}},
+{(unsigned char*)"isinE", {226, 139, 185, 0}},
+{(unsigned char*)"isindot", {226, 139, 181, 0}},
+{(unsigned char*)"isins", {226, 139, 180, 0}},
+{(unsigned char*)"isinsv", {226, 139, 179, 0}},
+{(unsigned char*)"isinv", {226, 136, 136, 0}},
+{(unsigned char*)"it", {226, 129, 162, 0}},
+{(unsigned char*)"itilde", {196, 169, 0}},
+{(unsigned char*)"iukcy", {209, 150, 0}},
+{(unsigned char*)"iuml", {195, 175, 0}},
+{(unsigned char*)"jcirc", {196, 181, 0}},
+{(unsigned char*)"jcy", {208, 185, 0}},
+{(unsigned char*)"jfr", {240, 157, 148, 167, 0}},
+{(unsigned char*)"jmath", {200, 183, 0}},
+{(unsigned char*)"jopf", {240, 157, 149, 155, 0}},
+{(unsigned char*)"jscr", {240, 157, 146, 191, 0}},
+{(unsigned char*)"jsercy", {209, 152, 0}},
+{(unsigned char*)"jukcy", {209, 148, 0}},
+{(unsigned char*)"kappa", {206, 186, 0}},
+{(unsigned char*)"kappav", {207, 176, 0}},
+{(unsigned char*)"kcedil", {196, 183, 0}},
+{(unsigned char*)"kcy", {208, 186, 0}},
+{(unsigned char*)"kfr", {240, 157, 148, 168, 0}},
+{(unsigned char*)"kgreen", {196, 184, 0}},
+{(unsigned char*)"khcy", {209, 133, 0}},
+{(unsigned char*)"kjcy", {209, 156, 0}},
+{(unsigned char*)"kopf", {240, 157, 149, 156, 0}},
+{(unsigned char*)"kscr", {240, 157, 147, 128, 0}},
+{(unsigned char*)"lAarr", {226, 135, 154, 0}},
+{(unsigned char*)"lArr", {226, 135, 144, 0}},
+{(unsigned char*)"lAtail", {226, 164, 155, 0}},
+{(unsigned char*)"lBarr", {226, 164, 142, 0}},
+{(unsigned char*)"lE", {226, 137, 166, 0}},
+{(unsigned char*)"lEg", {226, 170, 139, 0}},
+{(unsigned char*)"lHar", {226, 165, 162, 0}},
+{(unsigned char*)"lacute", {196, 186, 0}},
+{(unsigned char*)"laemptyv", {226, 166, 180, 0}},
+{(unsigned char*)"lagran", {226, 132, 146, 0}},
+{(unsigned char*)"lambda", {206, 187, 0}},
+{(unsigned char*)"lang", {226, 159, 168, 0}},
+{(unsigned char*)"langd", {226, 166, 145, 0}},
+{(unsigned char*)"langle", {226, 159, 168, 0}},
+{(unsigned char*)"lap", {226, 170, 133, 0}},
+{(unsigned char*)"laquo", {194, 171, 0}},
+{(unsigned char*)"larr", {226, 134, 144, 0}},
+{(unsigned char*)"larrb", {226, 135, 164, 0}},
+{(unsigned char*)"larrbfs", {226, 164, 159, 0}},
+{(unsigned char*)"larrfs", {226, 164, 157, 0}},
+{(unsigned char*)"larrhk", {226, 134, 169, 0}},
+{(unsigned char*)"larrlp", {226, 134, 171, 0}},
+{(unsigned char*)"larrpl", {226, 164, 185, 0}},
+{(unsigned char*)"larrsim", {226, 165, 179, 0}},
+{(unsigned char*)"larrtl", {226, 134, 162, 0}},
+{(unsigned char*)"lat", {226, 170, 171, 0}},
+{(unsigned char*)"latail", {226, 164, 153, 0}},
+{(unsigned char*)"late", {226, 170, 173, 0}},
+{(unsigned char*)"lates", {226, 170, 173, 239, 184, 128, 0}},
+{(unsigned char*)"lbarr", {226, 164, 140, 0}},
+{(unsigned char*)"lbbrk", {226, 157, 178, 0}},
+{(unsigned char*)"lbrace", {123, 0}},
+{(unsigned char*)"lbrack", {91, 0}},
+{(unsigned char*)"lbrke", {226, 166, 139, 0}},
+{(unsigned char*)"lbrksld", {226, 166, 143, 0}},
+{(unsigned char*)"lbrkslu", {226, 166, 141, 0}},
+{(unsigned char*)"lcaron", {196, 190, 0}},
+{(unsigned char*)"lcedil", {196, 188, 0}},
+{(unsigned char*)"lceil", {226, 140, 136, 0}},
+{(unsigned char*)"lcub", {123, 0}},
+{(unsigned char*)"lcy", {208, 187, 0}},
+{(unsigned char*)"ldca", {226, 164, 182, 0}},
+{(unsigned char*)"ldquo", {226, 128, 156, 0}},
+{(unsigned char*)"ldquor", {226, 128, 158, 0}},
+{(unsigned char*)"ldrdhar", {226, 165, 167, 0}},
+{(unsigned char*)"ldrushar", {226, 165, 139, 0}},
+{(unsigned char*)"ldsh", {226, 134, 178, 0}},
+{(unsigned char*)"le", {226, 137, 164, 0}},
+{(unsigned char*)"leftarrow", {226, 134, 144, 0}},
+{(unsigned char*)"leftarrowtail", {226, 134, 162, 0}},
+{(unsigned char*)"leftharpoondown", {226, 134, 189, 0}},
+{(unsigned char*)"leftharpoonup", {226, 134, 188, 0}},
+{(unsigned char*)"leftleftarrows", {226, 135, 135, 0}},
+{(unsigned char*)"leftrightarrow", {226, 134, 148, 0}},
+{(unsigned char*)"leftrightarrows", {226, 135, 134, 0}},
+{(unsigned char*)"leftrightharpoons", {226, 135, 139, 0}},
+{(unsigned char*)"leftrightsquigarrow", {226, 134, 173, 0}},
+{(unsigned char*)"leftthreetimes", {226, 139, 139, 0}},
+{(unsigned char*)"leg", {226, 139, 154, 0}},
+{(unsigned char*)"leq", {226, 137, 164, 0}},
+{(unsigned char*)"leqq", {226, 137, 166, 0}},
+{(unsigned char*)"leqslant", {226, 169, 189, 0}},
+{(unsigned char*)"les", {226, 169, 189, 0}},
+{(unsigned char*)"lescc", {226, 170, 168, 0}},
+{(unsigned char*)"lesdot", {226, 169, 191, 0}},
+{(unsigned char*)"lesdoto", {226, 170, 129, 0}},
+{(unsigned char*)"lesdotor", {226, 170, 131, 0}},
+{(unsigned char*)"lesg", {226, 139, 154, 239, 184, 128, 0}},
+{(unsigned char*)"lesges", {226, 170, 147, 0}},
+{(unsigned char*)"lessapprox", {226, 170, 133, 0}},
+{(unsigned char*)"lessdot", {226, 139, 150, 0}},
+{(unsigned char*)"lesseqgtr", {226, 139, 154, 0}},
+{(unsigned char*)"lesseqqgtr", {226, 170, 139, 0}},
+{(unsigned char*)"lessgtr", {226, 137, 182, 0}},
+{(unsigned char*)"lesssim", {226, 137, 178, 0}},
+{(unsigned char*)"lfisht", {226, 165, 188, 0}},
+{(unsigned char*)"lfloor", {226, 140, 138, 0}},
+{(unsigned char*)"lfr", {240, 157, 148, 169, 0}},
+{(unsigned char*)"lg", {226, 137, 182, 0}},
+{(unsigned char*)"lgE", {226, 170, 145, 0}},
+{(unsigned char*)"lhard", {226, 134, 189, 0}},
+{(unsigned char*)"lharu", {226, 134, 188, 0}},
+{(unsigned char*)"lharul", {226, 165, 170, 0}},
+{(unsigned char*)"lhblk", {226, 150, 132, 0}},
+{(unsigned char*)"ljcy", {209, 153, 0}},
+{(unsigned char*)"ll", {226, 137, 170, 0}},
+{(unsigned char*)"llarr", {226, 135, 135, 0}},
+{(unsigned char*)"llcorner", {226, 140, 158, 0}},
+{(unsigned char*)"llhard", {226, 165, 171, 0}},
+{(unsigned char*)"lltri", {226, 151, 186, 0}},
+{(unsigned char*)"lmidot", {197, 128, 0}},
+{(unsigned char*)"lmoust", {226, 142, 176, 0}},
+{(unsigned char*)"lmoustache", {226, 142, 176, 0}},
+{(unsigned char*)"lnE", {226, 137, 168, 0}},
+{(unsigned char*)"lnap", {226, 170, 137, 0}},
+{(unsigned char*)"lnapprox", {226, 170, 137, 0}},
+{(unsigned char*)"lne", {226, 170, 135, 0}},
+{(unsigned char*)"lneq", {226, 170, 135, 0}},
+{(unsigned char*)"lneqq", {226, 137, 168, 0}},
+{(unsigned char*)"lnsim", {226, 139, 166, 0}},
+{(unsigned char*)"loang", {226, 159, 172, 0}},
+{(unsigned char*)"loarr", {226, 135, 189, 0}},
+{(unsigned char*)"lobrk", {226, 159, 166, 0}},
+{(unsigned char*)"longleftarrow", {226, 159, 181, 0}},
+{(unsigned char*)"longleftrightarrow", {226, 159, 183, 0}},
+{(unsigned char*)"longmapsto", {226, 159, 188, 0}},
+{(unsigned char*)"longrightarrow", {226, 159, 182, 0}},
+{(unsigned char*)"looparrowleft", {226, 134, 171, 0}},
+{(unsigned char*)"looparrowright", {226, 134, 172, 0}},
+{(unsigned char*)"lopar", {226, 166, 133, 0}},
+{(unsigned char*)"lopf", {240, 157, 149, 157, 0}},
+{(unsigned char*)"loplus", {226, 168, 173, 0}},
+{(unsigned char*)"lotimes", {226, 168, 180, 0}},
+{(unsigned char*)"lowast", {226, 136, 151, 0}},
+{(unsigned char*)"lowbar", {95, 0}},
+{(unsigned char*)"loz", {226, 151, 138, 0}},
+{(unsigned char*)"lozenge", {226, 151, 138, 0}},
+{(unsigned char*)"lozf", {226, 167, 171, 0}},
+{(unsigned char*)"lpar", {40, 0}},
+{(unsigned char*)"lparlt", {226, 166, 147, 0}},
+{(unsigned char*)"lrarr", {226, 135, 134, 0}},
+{(unsigned char*)"lrcorner", {226, 140, 159, 0}},
+{(unsigned char*)"lrhar", {226, 135, 139, 0}},
+{(unsigned char*)"lrhard", {226, 165, 173, 0}},
+{(unsigned char*)"lrm", {226, 128, 142, 0}},
+{(unsigned char*)"lrtri", {226, 138, 191, 0}},
+{(unsigned char*)"lsaquo", {226, 128, 185, 0}},
+{(unsigned char*)"lscr", {240, 157, 147, 129, 0}},
+{(unsigned char*)"lsh", {226, 134, 176, 0}},
+{(unsigned char*)"lsim", {226, 137, 178, 0}},
+{(unsigned char*)"lsime", {226, 170, 141, 0}},
+{(unsigned char*)"lsimg", {226, 170, 143, 0}},
+{(unsigned char*)"lsqb", {91, 0}},
+{(unsigned char*)"lsquo", {226, 128, 152, 0}},
+{(unsigned char*)"lsquor", {226, 128, 154, 0}},
+{(unsigned char*)"lstrok", {197, 130, 0}},
+{(unsigned char*)"lt", {60, 0}},
+{(unsigned char*)"ltcc", {226, 170, 166, 0}},
+{(unsigned char*)"ltcir", {226, 169, 185, 0}},
+{(unsigned char*)"ltdot", {226, 139, 150, 0}},
+{(unsigned char*)"lthree", {226, 139, 139, 0}},
+{(unsigned char*)"ltimes", {226, 139, 137, 0}},
+{(unsigned char*)"ltlarr", {226, 165, 182, 0}},
+{(unsigned char*)"ltquest", {226, 169, 187, 0}},
+{(unsigned char*)"ltrPar", {226, 166, 150, 0}},
+{(unsigned char*)"ltri", {226, 151, 131, 0}},
+{(unsigned char*)"ltrie", {226, 138, 180, 0}},
+{(unsigned char*)"ltrif", {226, 151, 130, 0}},
+{(unsigned char*)"lurdshar", {226, 165, 138, 0}},
+{(unsigned char*)"luruhar", {226, 165, 166, 0}},
+{(unsigned char*)"lvertneqq", {226, 137, 168, 239, 184, 128, 0}},
+{(unsigned char*)"lvnE", {226, 137, 168, 239, 184, 128, 0}},
+{(unsigned char*)"mDDot", {226, 136, 186, 0}},
+{(unsigned char*)"macr", {194, 175, 0}},
+{(unsigned char*)"male", {226, 153, 130, 0}},
+{(unsigned char*)"malt", {226, 156, 160, 0}},
+{(unsigned char*)"maltese", {226, 156, 160, 0}},
+{(unsigned char*)"map", {226, 134, 166, 0}},
+{(unsigned char*)"mapsto", {226, 134, 166, 0}},
+{(unsigned char*)"mapstodown", {226, 134, 167, 0}},
+{(unsigned char*)"mapstoleft", {226, 134, 164, 0}},
+{(unsigned char*)"mapstoup", {226, 134, 165, 0}},
+{(unsigned char*)"marker", {226, 150, 174, 0}},
+{(unsigned char*)"mcomma", {226, 168, 169, 0}},
+{(unsigned char*)"mcy", {208, 188, 0}},
+{(unsigned char*)"mdash", {226, 128, 148, 0}},
+{(unsigned char*)"measuredangle", {226, 136, 161, 0}},
+{(unsigned char*)"mfr", {240, 157, 148, 170, 0}},
+{(unsigned char*)"mho", {226, 132, 167, 0}},
+{(unsigned char*)"micro", {194, 181, 0}},
+{(unsigned char*)"mid", {226, 136, 163, 0}},
+{(unsigned char*)"midast", {42, 0}},
+{(unsigned char*)"midcir", {226, 171, 176, 0}},
+{(unsigned char*)"middot", {194, 183, 0}},
+{(unsigned char*)"minus", {226, 136, 146, 0}},
+{(unsigned char*)"minusb", {226, 138, 159, 0}},
+{(unsigned char*)"minusd", {226, 136, 184, 0}},
+{(unsigned char*)"minusdu", {226, 168, 170, 0}},
+{(unsigned char*)"mlcp", {226, 171, 155, 0}},
+{(unsigned char*)"mldr", {226, 128, 166, 0}},
+{(unsigned char*)"mnplus", {226, 136, 147, 0}},
+{(unsigned char*)"models", {226, 138, 167, 0}},
+{(unsigned char*)"mopf", {240, 157, 149, 158, 0}},
+{(unsigned char*)"mp", {226, 136, 147, 0}},
+{(unsigned char*)"mscr", {240, 157, 147, 130, 0}},
+{(unsigned char*)"mstpos", {226, 136, 190, 0}},
+{(unsigned char*)"mu", {206, 188, 0}},
+{(unsigned char*)"multimap", {226, 138, 184, 0}},
+{(unsigned char*)"mumap", {226, 138, 184, 0}},
+{(unsigned char*)"nGg", {226, 139, 153, 204, 184, 0}},
+{(unsigned char*)"nGt", {226, 137, 171, 226, 131, 146, 0}},
+{(unsigned char*)"nGtv", {226, 137, 171, 204, 184, 0}},
+{(unsigned char*)"nLeftarrow", {226, 135, 141, 0}},
+{(unsigned char*)"nLeftrightarrow", {226, 135, 142, 0}},
+{(unsigned char*)"nLl", {226, 139, 152, 204, 184, 0}},
+{(unsigned char*)"nLt", {226, 137, 170, 226, 131, 146, 0}},
+{(unsigned char*)"nLtv", {226, 137, 170, 204, 184, 0}},
+{(unsigned char*)"nRightarrow", {226, 135, 143, 0}},
+{(unsigned char*)"nVDash", {226, 138, 175, 0}},
+{(unsigned char*)"nVdash", {226, 138, 174, 0}},
+{(unsigned char*)"nabla", {226, 136, 135, 0}},
+{(unsigned char*)"nacute", {197, 132, 0}},
+{(unsigned char*)"nang", {226, 136, 160, 226, 131, 146, 0}},
+{(unsigned char*)"nap", {226, 137, 137, 0}},
+{(unsigned char*)"napE", {226, 169, 176, 204, 184, 0}},
+{(unsigned char*)"napid", {226, 137, 139, 204, 184, 0}},
+{(unsigned char*)"napos", {197, 137, 0}},
+{(unsigned char*)"napprox", {226, 137, 137, 0}},
+{(unsigned char*)"natur", {226, 153, 174, 0}},
+{(unsigned char*)"natural", {226, 153, 174, 0}},
+{(unsigned char*)"naturals", {226, 132, 149, 0}},
+{(unsigned char*)"nbsp", {194, 160, 0}},
+{(unsigned char*)"nbump", {226, 137, 142, 204, 184, 0}},
+{(unsigned char*)"nbumpe", {226, 137, 143, 204, 184, 0}},
+{(unsigned char*)"ncap", {226, 169, 131, 0}},
+{(unsigned char*)"ncaron", {197, 136, 0}},
+{(unsigned char*)"ncedil", {197, 134, 0}},
+{(unsigned char*)"ncong", {226, 137, 135, 0}},
+{(unsigned char*)"ncongdot", {226, 169, 173, 204, 184, 0}},
+{(unsigned char*)"ncup", {226, 169, 130, 0}},
+{(unsigned char*)"ncy", {208, 189, 0}},
+{(unsigned char*)"ndash", {226, 128, 147, 0}},
+{(unsigned char*)"ne", {226, 137, 160, 0}},
+{(unsigned char*)"neArr", {226, 135, 151, 0}},
+{(unsigned char*)"nearhk", {226, 164, 164, 0}},
+{(unsigned char*)"nearr", {226, 134, 151, 0}},
+{(unsigned char*)"nearrow", {226, 134, 151, 0}},
+{(unsigned char*)"nedot", {226, 137, 144, 204, 184, 0}},
+{(unsigned char*)"nequiv", {226, 137, 162, 0}},
+{(unsigned char*)"nesear", {226, 164, 168, 0}},
+{(unsigned char*)"nesim", {226, 137, 130, 204, 184, 0}},
+{(unsigned char*)"nexist", {226, 136, 132, 0}},
+{(unsigned char*)"nexists", {226, 136, 132, 0}},
+{(unsigned char*)"nfr", {240, 157, 148, 171, 0}},
+{(unsigned char*)"ngE", {226, 137, 167, 204, 184, 0}},
+{(unsigned char*)"nge", {226, 137, 177, 0}},
+{(unsigned char*)"ngeq", {226, 137, 177, 0}},
+{(unsigned char*)"ngeqq", {226, 137, 167, 204, 184, 0}},
+{(unsigned char*)"ngeqslant", {226, 169, 190, 204, 184, 0}},
+{(unsigned char*)"nges", {226, 169, 190, 204, 184, 0}},
+{(unsigned char*)"ngsim", {226, 137, 181, 0}},
+{(unsigned char*)"ngt", {226, 137, 175, 0}},
+{(unsigned char*)"ngtr", {226, 137, 175, 0}},
+{(unsigned char*)"nhArr", {226, 135, 142, 0}},
+{(unsigned char*)"nharr", {226, 134, 174, 0}},
+{(unsigned char*)"nhpar", {226, 171, 178, 0}},
+{(unsigned char*)"ni", {226, 136, 139, 0}},
+{(unsigned char*)"nis", {226, 139, 188, 0}},
+{(unsigned char*)"nisd", {226, 139, 186, 0}},
+{(unsigned char*)"niv", {226, 136, 139, 0}},
+{(unsigned char*)"njcy", {209, 154, 0}},
+{(unsigned char*)"nlArr", {226, 135, 141, 0}},
+{(unsigned char*)"nlE", {226, 137, 166, 204, 184, 0}},
+{(unsigned char*)"nlarr", {226, 134, 154, 0}},
+{(unsigned char*)"nldr", {226, 128, 165, 0}},
+{(unsigned char*)"nle", {226, 137, 176, 0}},
+{(unsigned char*)"nleftarrow", {226, 134, 154, 0}},
+{(unsigned char*)"nleftrightarrow", {226, 134, 174, 0}},
+{(unsigned char*)"nleq", {226, 137, 176, 0}},
+{(unsigned char*)"nleqq", {226, 137, 166, 204, 184, 0}},
+{(unsigned char*)"nleqslant", {226, 169, 189, 204, 184, 0}},
+{(unsigned char*)"nles", {226, 169, 189, 204, 184, 0}},
+{(unsigned char*)"nless", {226, 137, 174, 0}},
+{(unsigned char*)"nlsim", {226, 137, 180, 0}},
+{(unsigned char*)"nlt", {226, 137, 174, 0}},
+{(unsigned char*)"nltri", {226, 139, 170, 0}},
+{(unsigned char*)"nltrie", {226, 139, 172, 0}},
+{(unsigned char*)"nmid", {226, 136, 164, 0}},
+{(unsigned char*)"nopf", {240, 157, 149, 159, 0}},
+{(unsigned char*)"not", {194, 172, 0}},
+{(unsigned char*)"notin", {226, 136, 137, 0}},
+{(unsigned char*)"notinE", {226, 139, 185, 204, 184, 0}},
+{(unsigned char*)"notindot", {226, 139, 181, 204, 184, 0}},
+{(unsigned char*)"notinva", {226, 136, 137, 0}},
+{(unsigned char*)"notinvb", {226, 139, 183, 0}},
+{(unsigned char*)"notinvc", {226, 139, 182, 0}},
+{(unsigned char*)"notni", {226, 136, 140, 0}},
+{(unsigned char*)"notniva", {226, 136, 140, 0}},
+{(unsigned char*)"notnivb", {226, 139, 190, 0}},
+{(unsigned char*)"notnivc", {226, 139, 189, 0}},
+{(unsigned char*)"npar", {226, 136, 166, 0}},
+{(unsigned char*)"nparallel", {226, 136, 166, 0}},
+{(unsigned char*)"nparsl", {226, 171, 189, 226, 131, 165, 0}},
+{(unsigned char*)"npart", {226, 136, 130, 204, 184, 0}},
+{(unsigned char*)"npolint", {226, 168, 148, 0}},
+{(unsigned char*)"npr", {226, 138, 128, 0}},
+{(unsigned char*)"nprcue", {226, 139, 160, 0}},
+{(unsigned char*)"npre", {226, 170, 175, 204, 184, 0}},
+{(unsigned char*)"nprec", {226, 138, 128, 0}},
+{(unsigned char*)"npreceq", {226, 170, 175, 204, 184, 0}},
+{(unsigned char*)"nrArr", {226, 135, 143, 0}},
+{(unsigned char*)"nrarr", {226, 134, 155, 0}},
+{(unsigned char*)"nrarrc", {226, 164, 179, 204, 184, 0}},
+{(unsigned char*)"nrarrw", {226, 134, 157, 204, 184, 0}},
+{(unsigned char*)"nrightarrow", {226, 134, 155, 0}},
+{(unsigned char*)"nrtri", {226, 139, 171, 0}},
+{(unsigned char*)"nrtrie", {226, 139, 173, 0}},
+{(unsigned char*)"nsc", {226, 138, 129, 0}},
+{(unsigned char*)"nsccue", {226, 139, 161, 0}},
+{(unsigned char*)"nsce", {226, 170, 176, 204, 184, 0}},
+{(unsigned char*)"nscr", {240, 157, 147, 131, 0}},
+{(unsigned char*)"nshortmid", {226, 136, 164, 0}},
+{(unsigned char*)"nshortparallel", {226, 136, 166, 0}},
+{(unsigned char*)"nsim", {226, 137, 129, 0}},
+{(unsigned char*)"nsime", {226, 137, 132, 0}},
+{(unsigned char*)"nsimeq", {226, 137, 132, 0}},
+{(unsigned char*)"nsmid", {226, 136, 164, 0}},
+{(unsigned char*)"nspar", {226, 136, 166, 0}},
+{(unsigned char*)"nsqsube", {226, 139, 162, 0}},
+{(unsigned char*)"nsqsupe", {226, 139, 163, 0}},
+{(unsigned char*)"nsub", {226, 138, 132, 0}},
+{(unsigned char*)"nsubE", {226, 171, 133, 204, 184, 0}},
+{(unsigned char*)"nsube", {226, 138, 136, 0}},
+{(unsigned char*)"nsubset", {226, 138, 130, 226, 131, 146, 0}},
+{(unsigned char*)"nsubseteq", {226, 138, 136, 0}},
+{(unsigned char*)"nsubseteqq", {226, 171, 133, 204, 184, 0}},
+{(unsigned char*)"nsucc", {226, 138, 129, 0}},
+{(unsigned char*)"nsucceq", {226, 170, 176, 204, 184, 0}},
+{(unsigned char*)"nsup", {226, 138, 133, 0}},
+{(unsigned char*)"nsupE", {226, 171, 134, 204, 184, 0}},
+{(unsigned char*)"nsupe", {226, 138, 137, 0}},
+{(unsigned char*)"nsupset", {226, 138, 131, 226, 131, 146, 0}},
+{(unsigned char*)"nsupseteq", {226, 138, 137, 0}},
+{(unsigned char*)"nsupseteqq", {226, 171, 134, 204, 184, 0}},
+{(unsigned char*)"ntgl", {226, 137, 185, 0}},
+{(unsigned char*)"ntilde", {195, 177, 0}},
+{(unsigned char*)"ntlg", {226, 137, 184, 0}},
+{(unsigned char*)"ntriangleleft", {226, 139, 170, 0}},
+{(unsigned char*)"ntrianglelefteq", {226, 139, 172, 0}},
+{(unsigned char*)"ntriangleright", {226, 139, 171, 0}},
+{(unsigned char*)"ntrianglerighteq", {226, 139, 173, 0}},
+{(unsigned char*)"nu", {206, 189, 0}},
+{(unsigned char*)"num", {35, 0}},
+{(unsigned char*)"numero", {226, 132, 150, 0}},
+{(unsigned char*)"numsp", {226, 128, 135, 0}},
+{(unsigned char*)"nvDash", {226, 138, 173, 0}},
+{(unsigned char*)"nvHarr", {226, 164, 132, 0}},
+{(unsigned char*)"nvap", {226, 137, 141, 226, 131, 146, 0}},
+{(unsigned char*)"nvdash", {226, 138, 172, 0}},
+{(unsigned char*)"nvge", {226, 137, 165, 226, 131, 146, 0}},
+{(unsigned char*)"nvgt", {62, 226, 131, 146, 0}},
+{(unsigned char*)"nvinfin", {226, 167, 158, 0}},
+{(unsigned char*)"nvlArr", {226, 164, 130, 0}},
+{(unsigned char*)"nvle", {226, 137, 164, 226, 131, 146, 0}},
+{(unsigned char*)"nvlt", {60, 226, 131, 146, 0}},
+{(unsigned char*)"nvltrie", {226, 138, 180, 226, 131, 146, 0}},
+{(unsigned char*)"nvrArr", {226, 164, 131, 0}},
+{(unsigned char*)"nvrtrie", {226, 138, 181, 226, 131, 146, 0}},
+{(unsigned char*)"nvsim", {226, 136, 188, 226, 131, 146, 0}},
+{(unsigned char*)"nwArr", {226, 135, 150, 0}},
+{(unsigned char*)"nwarhk", {226, 164, 163, 0}},
+{(unsigned char*)"nwarr", {226, 134, 150, 0}},
+{(unsigned char*)"nwarrow", {226, 134, 150, 0}},
+{(unsigned char*)"nwnear", {226, 164, 167, 0}},
+{(unsigned char*)"oS", {226, 147, 136, 0}},
+{(unsigned char*)"oacute", {195, 179, 0}},
+{(unsigned char*)"oast", {226, 138, 155, 0}},
+{(unsigned char*)"ocir", {226, 138, 154, 0}},
+{(unsigned char*)"ocirc", {195, 180, 0}},
+{(unsigned char*)"ocy", {208, 190, 0}},
+{(unsigned char*)"odash", {226, 138, 157, 0}},
+{(unsigned char*)"odblac", {197, 145, 0}},
+{(unsigned char*)"odiv", {226, 168, 184, 0}},
+{(unsigned char*)"odot", {226, 138, 153, 0}},
+{(unsigned char*)"odsold", {226, 166, 188, 0}},
+{(unsigned char*)"oelig", {197, 147, 0}},
+{(unsigned char*)"ofcir", {226, 166, 191, 0}},
+{(unsigned char*)"ofr", {240, 157, 148, 172, 0}},
+{(unsigned char*)"ogon", {203, 155, 0}},
+{(unsigned char*)"ograve", {195, 178, 0}},
+{(unsigned char*)"ogt", {226, 167, 129, 0}},
+{(unsigned char*)"ohbar", {226, 166, 181, 0}},
+{(unsigned char*)"ohm", {206, 169, 0}},
+{(unsigned char*)"oint", {226, 136, 174, 0}},
+{(unsigned char*)"olarr", {226, 134, 186, 0}},
+{(unsigned char*)"olcir", {226, 166, 190, 0}},
+{(unsigned char*)"olcross", {226, 166, 187, 0}},
+{(unsigned char*)"oline", {226, 128, 190, 0}},
+{(unsigned char*)"olt", {226, 167, 128, 0}},
+{(unsigned char*)"omacr", {197, 141, 0}},
+{(unsigned char*)"omega", {207, 137, 0}},
+{(unsigned char*)"omicron", {206, 191, 0}},
+{(unsigned char*)"omid", {226, 166, 182, 0}},
+{(unsigned char*)"ominus", {226, 138, 150, 0}},
+{(unsigned char*)"oopf", {240, 157, 149, 160, 0}},
+{(unsigned char*)"opar", {226, 166, 183, 0}},
+{(unsigned char*)"operp", {226, 166, 185, 0}},
+{(unsigned char*)"oplus", {226, 138, 149, 0}},
+{(unsigned char*)"or", {226, 136, 168, 0}},
+{(unsigned char*)"orarr", {226, 134, 187, 0}},
+{(unsigned char*)"ord", {226, 169, 157, 0}},
+{(unsigned char*)"order", {226, 132, 180, 0}},
+{(unsigned char*)"orderof", {226, 132, 180, 0}},
+{(unsigned char*)"ordf", {194, 170, 0}},
+{(unsigned char*)"ordm", {194, 186, 0}},
+{(unsigned char*)"origof", {226, 138, 182, 0}},
+{(unsigned char*)"oror", {226, 169, 150, 0}},
+{(unsigned char*)"orslope", {226, 169, 151, 0}},
+{(unsigned char*)"orv", {226, 169, 155, 0}},
+{(unsigned char*)"oscr", {226, 132, 180, 0}},
+{(unsigned char*)"oslash", {195, 184, 0}},
+{(unsigned char*)"osol", {226, 138, 152, 0}},
+{(unsigned char*)"otilde", {195, 181, 0}},
+{(unsigned char*)"otimes", {226, 138, 151, 0}},
+{(unsigned char*)"otimesas", {226, 168, 182, 0}},
+{(unsigned char*)"ouml", {195, 182, 0}},
+{(unsigned char*)"ovbar", {226, 140, 189, 0}},
+{(unsigned char*)"par", {226, 136, 165, 0}},
+{(unsigned char*)"para", {194, 182, 0}},
+{(unsigned char*)"parallel", {226, 136, 165, 0}},
+{(unsigned char*)"parsim", {226, 171, 179, 0}},
+{(unsigned char*)"parsl", {226, 171, 189, 0}},
+{(unsigned char*)"part", {226, 136, 130, 0}},
+{(unsigned char*)"pcy", {208, 191, 0}},
+{(unsigned char*)"percnt", {37, 0}},
+{(unsigned char*)"period", {46, 0}},
+{(unsigned char*)"permil", {226, 128, 176, 0}},
+{(unsigned char*)"perp", {226, 138, 165, 0}},
+{(unsigned char*)"pertenk", {226, 128, 177, 0}},
+{(unsigned char*)"pfr", {240, 157, 148, 173, 0}},
+{(unsigned char*)"phi", {207, 134, 0}},
+{(unsigned char*)"phiv", {207, 149, 0}},
+{(unsigned char*)"phmmat", {226, 132, 179, 0}},
+{(unsigned char*)"phone", {226, 152, 142, 0}},
+{(unsigned char*)"pi", {207, 128, 0}},
+{(unsigned char*)"pitchfork", {226, 139, 148, 0}},
+{(unsigned char*)"piv", {207, 150, 0}},
+{(unsigned char*)"planck", {226, 132, 143, 0}},
+{(unsigned char*)"planckh", {226, 132, 142, 0}},
+{(unsigned char*)"plankv", {226, 132, 143, 0}},
+{(unsigned char*)"plus", {43, 0}},
+{(unsigned char*)"plusacir", {226, 168, 163, 0}},
+{(unsigned char*)"plusb", {226, 138, 158, 0}},
+{(unsigned char*)"pluscir", {226, 168, 162, 0}},
+{(unsigned char*)"plusdo", {226, 136, 148, 0}},
+{(unsigned char*)"plusdu", {226, 168, 165, 0}},
+{(unsigned char*)"pluse", {226, 169, 178, 0}},
+{(unsigned char*)"plusmn", {194, 177, 0}},
+{(unsigned char*)"plussim", {226, 168, 166, 0}},
+{(unsigned char*)"plustwo", {226, 168, 167, 0}},
+{(unsigned char*)"pm", {194, 177, 0}},
+{(unsigned char*)"pointint", {226, 168, 149, 0}},
+{(unsigned char*)"popf", {240, 157, 149, 161, 0}},
+{(unsigned char*)"pound", {194, 163, 0}},
+{(unsigned char*)"pr", {226, 137, 186, 0}},
+{(unsigned char*)"prE", {226, 170, 179, 0}},
+{(unsigned char*)"prap", {226, 170, 183, 0}},
+{(unsigned char*)"prcue", {226, 137, 188, 0}},
+{(unsigned char*)"pre", {226, 170, 175, 0}},
+{(unsigned char*)"prec", {226, 137, 186, 0}},
+{(unsigned char*)"precapprox", {226, 170, 183, 0}},
+{(unsigned char*)"preccurlyeq", {226, 137, 188, 0}},
+{(unsigned char*)"preceq", {226, 170, 175, 0}},
+{(unsigned char*)"precnapprox", {226, 170, 185, 0}},
+{(unsigned char*)"precneqq", {226, 170, 181, 0}},
+{(unsigned char*)"precnsim", {226, 139, 168, 0}},
+{(unsigned char*)"precsim", {226, 137, 190, 0}},
+{(unsigned char*)"prime", {226, 128, 178, 0}},
+{(unsigned char*)"primes", {226, 132, 153, 0}},
+{(unsigned char*)"prnE", {226, 170, 181, 0}},
+{(unsigned char*)"prnap", {226, 170, 185, 0}},
+{(unsigned char*)"prnsim", {226, 139, 168, 0}},
+{(unsigned char*)"prod", {226, 136, 143, 0}},
+{(unsigned char*)"profalar", {226, 140, 174, 0}},
+{(unsigned char*)"profline", {226, 140, 146, 0}},
+{(unsigned char*)"profsurf", {226, 140, 147, 0}},
+{(unsigned char*)"prop", {226, 136, 157, 0}},
+{(unsigned char*)"propto", {226, 136, 157, 0}},
+{(unsigned char*)"prsim", {226, 137, 190, 0}},
+{(unsigned char*)"prurel", {226, 138, 176, 0}},
+{(unsigned char*)"pscr", {240, 157, 147, 133, 0}},
+{(unsigned char*)"psi", {207, 136, 0}},
+{(unsigned char*)"puncsp", {226, 128, 136, 0}},
+{(unsigned char*)"qfr", {240, 157, 148, 174, 0}},
+{(unsigned char*)"qint", {226, 168, 140, 0}},
+{(unsigned char*)"qopf", {240, 157, 149, 162, 0}},
+{(unsigned char*)"qprime", {226, 129, 151, 0}},
+{(unsigned char*)"qscr", {240, 157, 147, 134, 0}},
+{(unsigned char*)"quaternions", {226, 132, 141, 0}},
+{(unsigned char*)"quatint", {226, 168, 150, 0}},
+{(unsigned char*)"quest", {63, 0}},
+{(unsigned char*)"questeq", {226, 137, 159, 0}},
+{(unsigned char*)"quot", {34, 0}},
+{(unsigned char*)"rAarr", {226, 135, 155, 0}},
+{(unsigned char*)"rArr", {226, 135, 146, 0}},
+{(unsigned char*)"rAtail", {226, 164, 156, 0}},
+{(unsigned char*)"rBarr", {226, 164, 143, 0}},
+{(unsigned char*)"rHar", {226, 165, 164, 0}},
+{(unsigned char*)"race", {226, 136, 189, 204, 177, 0}},
+{(unsigned char*)"racute", {197, 149, 0}},
+{(unsigned char*)"radic", {226, 136, 154, 0}},
+{(unsigned char*)"raemptyv", {226, 166, 179, 0}},
+{(unsigned char*)"rang", {226, 159, 169, 0}},
+{(unsigned char*)"rangd", {226, 166, 146, 0}},
+{(unsigned char*)"range", {226, 166, 165, 0}},
+{(unsigned char*)"rangle", {226, 159, 169, 0}},
+{(unsigned char*)"raquo", {194, 187, 0}},
+{(unsigned char*)"rarr", {226, 134, 146, 0}},
+{(unsigned char*)"rarrap", {226, 165, 181, 0}},
+{(unsigned char*)"rarrb", {226, 135, 165, 0}},
+{(unsigned char*)"rarrbfs", {226, 164, 160, 0}},
+{(unsigned char*)"rarrc", {226, 164, 179, 0}},
+{(unsigned char*)"rarrfs", {226, 164, 158, 0}},
+{(unsigned char*)"rarrhk", {226, 134, 170, 0}},
+{(unsigned char*)"rarrlp", {226, 134, 172, 0}},
+{(unsigned char*)"rarrpl", {226, 165, 133, 0}},
+{(unsigned char*)"rarrsim", {226, 165, 180, 0}},
+{(unsigned char*)"rarrtl", {226, 134, 163, 0}},
+{(unsigned char*)"rarrw", {226, 134, 157, 0}},
+{(unsigned char*)"ratail", {226, 164, 154, 0}},
+{(unsigned char*)"ratio", {226, 136, 182, 0}},
+{(unsigned char*)"rationals", {226, 132, 154, 0}},
+{(unsigned char*)"rbarr", {226, 164, 141, 0}},
+{(unsigned char*)"rbbrk", {226, 157, 179, 0}},
+{(unsigned char*)"rbrace", {125, 0}},
+{(unsigned char*)"rbrack", {93, 0}},
+{(unsigned char*)"rbrke", {226, 166, 140, 0}},
+{(unsigned char*)"rbrksld", {226, 166, 142, 0}},
+{(unsigned char*)"rbrkslu", {226, 166, 144, 0}},
+{(unsigned char*)"rcaron", {197, 153, 0}},
+{(unsigned char*)"rcedil", {197, 151, 0}},
+{(unsigned char*)"rceil", {226, 140, 137, 0}},
+{(unsigned char*)"rcub", {125, 0}},
+{(unsigned char*)"rcy", {209, 128, 0}},
+{(unsigned char*)"rdca", {226, 164, 183, 0}},
+{(unsigned char*)"rdldhar", {226, 165, 169, 0}},
+{(unsigned char*)"rdquo", {226, 128, 157, 0}},
+{(unsigned char*)"rdquor", {226, 128, 157, 0}},
+{(unsigned char*)"rdsh", {226, 134, 179, 0}},
+{(unsigned char*)"real", {226, 132, 156, 0}},
+{(unsigned char*)"realine", {226, 132, 155, 0}},
+{(unsigned char*)"realpart", {226, 132, 156, 0}},
+{(unsigned char*)"reals", {226, 132, 157, 0}},
+{(unsigned char*)"rect", {226, 150, 173, 0}},
+{(unsigned char*)"reg", {194, 174, 0}},
+{(unsigned char*)"rfisht", {226, 165, 189, 0}},
+{(unsigned char*)"rfloor", {226, 140, 139, 0}},
+{(unsigned char*)"rfr", {240, 157, 148, 175, 0}},
+{(unsigned char*)"rhard", {226, 135, 129, 0}},
+{(unsigned char*)"rharu", {226, 135, 128, 0}},
+{(unsigned char*)"rharul", {226, 165, 172, 0}},
+{(unsigned char*)"rho", {207, 129, 0}},
+{(unsigned char*)"rhov", {207, 177, 0}},
+{(unsigned char*)"rightarrow", {226, 134, 146, 0}},
+{(unsigned char*)"rightarrowtail", {226, 134, 163, 0}},
+{(unsigned char*)"rightharpoondown", {226, 135, 129, 0}},
+{(unsigned char*)"rightharpoonup", {226, 135, 128, 0}},
+{(unsigned char*)"rightleftarrows", {226, 135, 132, 0}},
+{(unsigned char*)"rightleftharpoons", {226, 135, 140, 0}},
+{(unsigned char*)"rightrightarrows", {226, 135, 137, 0}},
+{(unsigned char*)"rightsquigarrow", {226, 134, 157, 0}},
+{(unsigned char*)"rightthreetimes", {226, 139, 140, 0}},
+{(unsigned char*)"ring", {203, 154, 0}},
+{(unsigned char*)"risingdotseq", {226, 137, 147, 0}},
+{(unsigned char*)"rlarr", {226, 135, 132, 0}},
+{(unsigned char*)"rlhar", {226, 135, 140, 0}},
+{(unsigned char*)"rlm", {226, 128, 143, 0}},
+{(unsigned char*)"rmoust", {226, 142, 177, 0}},
+{(unsigned char*)"rmoustache", {226, 142, 177, 0}},
+{(unsigned char*)"rnmid", {226, 171, 174, 0}},
+{(unsigned char*)"roang", {226, 159, 173, 0}},
+{(unsigned char*)"roarr", {226, 135, 190, 0}},
+{(unsigned char*)"robrk", {226, 159, 167, 0}},
+{(unsigned char*)"ropar", {226, 166, 134, 0}},
+{(unsigned char*)"ropf", {240, 157, 149, 163, 0}},
+{(unsigned char*)"roplus", {226, 168, 174, 0}},
+{(unsigned char*)"rotimes", {226, 168, 181, 0}},
+{(unsigned char*)"rpar", {41, 0}},
+{(unsigned char*)"rpargt", {226, 166, 148, 0}},
+{(unsigned char*)"rppolint", {226, 168, 146, 0}},
+{(unsigned char*)"rrarr", {226, 135, 137, 0}},
+{(unsigned char*)"rsaquo", {226, 128, 186, 0}},
+{(unsigned char*)"rscr", {240, 157, 147, 135, 0}},
+{(unsigned char*)"rsh", {226, 134, 177, 0}},
+{(unsigned char*)"rsqb", {93, 0}},
+{(unsigned char*)"rsquo", {226, 128, 153, 0}},
+{(unsigned char*)"rsquor", {226, 128, 153, 0}},
+{(unsigned char*)"rthree", {226, 139, 140, 0}},
+{(unsigned char*)"rtimes", {226, 139, 138, 0}},
+{(unsigned char*)"rtri", {226, 150, 185, 0}},
+{(unsigned char*)"rtrie", {226, 138, 181, 0}},
+{(unsigned char*)"rtrif", {226, 150, 184, 0}},
+{(unsigned char*)"rtriltri", {226, 167, 142, 0}},
+{(unsigned char*)"ruluhar", {226, 165, 168, 0}},
+{(unsigned char*)"rx", {226, 132, 158, 0}},
+{(unsigned char*)"sacute", {197, 155, 0}},
+{(unsigned char*)"sbquo", {226, 128, 154, 0}},
+{(unsigned char*)"sc", {226, 137, 187, 0}},
+{(unsigned char*)"scE", {226, 170, 180, 0}},
+{(unsigned char*)"scap", {226, 170, 184, 0}},
+{(unsigned char*)"scaron", {197, 161, 0}},
+{(unsigned char*)"sccue", {226, 137, 189, 0}},
+{(unsigned char*)"sce", {226, 170, 176, 0}},
+{(unsigned char*)"scedil", {197, 159, 0}},
+{(unsigned char*)"scirc", {197, 157, 0}},
+{(unsigned char*)"scnE", {226, 170, 182, 0}},
+{(unsigned char*)"scnap", {226, 170, 186, 0}},
+{(unsigned char*)"scnsim", {226, 139, 169, 0}},
+{(unsigned char*)"scpolint", {226, 168, 147, 0}},
+{(unsigned char*)"scsim", {226, 137, 191, 0}},
+{(unsigned char*)"scy", {209, 129, 0}},
+{(unsigned char*)"sdot", {226, 139, 133, 0}},
+{(unsigned char*)"sdotb", {226, 138, 161, 0}},
+{(unsigned char*)"sdote", {226, 169, 166, 0}},
+{(unsigned char*)"seArr", {226, 135, 152, 0}},
+{(unsigned char*)"searhk", {226, 164, 165, 0}},
+{(unsigned char*)"searr", {226, 134, 152, 0}},
+{(unsigned char*)"searrow", {226, 134, 152, 0}},
+{(unsigned char*)"sect", {194, 167, 0}},
+{(unsigned char*)"semi", {59, 0}},
+{(unsigned char*)"seswar", {226, 164, 169, 0}},
+{(unsigned char*)"setminus", {226, 136, 150, 0}},
+{(unsigned char*)"setmn", {226, 136, 150, 0}},
+{(unsigned char*)"sext", {226, 156, 182, 0}},
+{(unsigned char*)"sfr", {240, 157, 148, 176, 0}},
+{(unsigned char*)"sfrown", {226, 140, 162, 0}},
+{(unsigned char*)"sharp", {226, 153, 175, 0}},
+{(unsigned char*)"shchcy", {2

<TRUNCATED>

[12/20] lucy-clownfish git commit: Generate HTML docs only for public classes

Posted by nw...@apache.org.
Generate HTML docs only for public classes


Project: http://git-wip-us.apache.org/repos/asf/lucy-clownfish/repo
Commit: http://git-wip-us.apache.org/repos/asf/lucy-clownfish/commit/3518fa06
Tree: http://git-wip-us.apache.org/repos/asf/lucy-clownfish/tree/3518fa06
Diff: http://git-wip-us.apache.org/repos/asf/lucy-clownfish/diff/3518fa06

Branch: refs/heads/master
Commit: 3518fa06d135ceafb37ccb70551456e8a031de83
Parents: 89c7b80
Author: Nick Wellnhofer <we...@aevum.de>
Authored: Sat Jul 25 19:02:29 2015 +0200
Committer: Nick Wellnhofer <we...@aevum.de>
Committed: Thu Aug 6 18:19:19 2015 +0200

----------------------------------------------------------------------
 compiler/src/CFCCHtml.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/lucy-clownfish/blob/3518fa06/compiler/src/CFCCHtml.c
----------------------------------------------------------------------
diff --git a/compiler/src/CFCCHtml.c b/compiler/src/CFCCHtml.c
index 34b4336..95fb27f 100644
--- a/compiler/src/CFCCHtml.c
+++ b/compiler/src/CFCCHtml.c
@@ -242,7 +242,7 @@ CFCCHtml_write_html_docs(CFCCHtml *self) {
 
     for (size_t i = 0; ordered[i] != NULL; i++) {
         CFCClass *klass = ordered[i];
-        if (CFCClass_included(klass) || CFCClass_public(klass)) {
+        if (CFCClass_included(klass) || !CFCClass_public(klass)) {
             continue;
         }
 


[18/20] lucy-clownfish git commit: Replace erroneous Clownfish URLs with error message

Posted by nw...@apache.org.
Replace erroneous Clownfish URLs with error message


Project: http://git-wip-us.apache.org/repos/asf/lucy-clownfish/repo
Commit: http://git-wip-us.apache.org/repos/asf/lucy-clownfish/commit/520a87ef
Tree: http://git-wip-us.apache.org/repos/asf/lucy-clownfish/tree/520a87ef
Diff: http://git-wip-us.apache.org/repos/asf/lucy-clownfish/diff/520a87ef

Branch: refs/heads/master
Commit: 520a87ef45be57d271b34f1d966664c8fb551db7
Parents: 37504e4
Author: Nick Wellnhofer <we...@aevum.de>
Authored: Sun Jul 26 19:39:10 2015 +0200
Committer: Nick Wellnhofer <we...@aevum.de>
Committed: Thu Aug 6 18:19:19 2015 +0200

----------------------------------------------------------------------
 compiler/src/CFCC.c       |  12 +++-
 compiler/src/CFCCHtml.c   |  16 ++++-
 compiler/src/CFCPerlPod.c |  14 +++--
 compiler/src/CFCUri.c     | 137 +++++++++++++++++++++++------------------
 compiler/src/CFCUri.h     |  18 ++++--
 5 files changed, 125 insertions(+), 72 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/lucy-clownfish/blob/520a87ef/compiler/src/CFCC.c
----------------------------------------------------------------------
diff --git a/compiler/src/CFCC.c b/compiler/src/CFCC.c
index 6fba122..6d5adc6 100644
--- a/compiler/src/CFCC.c
+++ b/compiler/src/CFCC.c
@@ -174,9 +174,15 @@ CFCC_write_hostdefs(CFCC *self) {
 char*
 CFCC_link_text(CFCUri *uri_obj) {
     char *link_text = NULL;
-    int   type      = CFCUri_get_type(uri_obj);
+    CFCUriType type = CFCUri_get_type(uri_obj);
 
     switch (type) {
+        case CFC_URI_ERROR: {
+            const char *error = CFCUri_get_error(uri_obj);
+            link_text = CFCUtil_sprintf("[%s]", error);
+            break;
+        }
+
         case CFC_URI_NULL:
             link_text = CFCUtil_strdup("NULL");
             break;
@@ -203,6 +209,10 @@ CFCC_link_text(CFCUri *uri_obj) {
             link_text = CFCUtil_strdup(name);
             break;
         }
+
+        default:
+            CFCUtil_die("Unsupported node type: %d", type);
+            break;
     }
 
     return link_text;

http://git-wip-us.apache.org/repos/asf/lucy-clownfish/blob/520a87ef/compiler/src/CFCCHtml.c
----------------------------------------------------------------------
diff --git a/compiler/src/CFCCHtml.c b/compiler/src/CFCCHtml.c
index 52740f5..c51da80 100644
--- a/compiler/src/CFCCHtml.c
+++ b/compiler/src/CFCCHtml.c
@@ -1018,7 +1018,16 @@ S_transform_link(cmark_node *link, CFCClass *doc_class, int dir_level) {
     CFCUri *uri_obj = CFCUri_new(uri_string, doc_class);
     char   *url     = S_cfc_uri_to_url(uri_obj, doc_class, dir_level);
 
-    if (url) {
+    if (CFCUri_get_type(uri_obj) == CFC_URI_ERROR) {
+        // Replace link with error.
+        char *link_text = CFCC_link_text(uri_obj);
+        cmark_node *text_node = cmark_node_new(CMARK_NODE_TEXT);
+        cmark_node_set_literal(text_node, link_text);
+        cmark_node_insert_after(link, text_node);
+        cmark_node_free(link);
+        FREEMEM(link_text);
+    }
+    else if (url) {
         cmark_node_set_url(link, url);
 
         if (!cmark_node_first_child(link)) {
@@ -1089,7 +1098,7 @@ S_type_to_html(CFCClass *klass, CFCType *type) {
 static char*
 S_cfc_uri_to_url(CFCUri *uri_obj, CFCClass *doc_class, int dir_level) {
     char *url = NULL;
-    int   type    = CFCUri_get_type(uri_obj);
+    CFCUriType type = CFCUri_get_type(uri_obj);
 
     switch (type) {
         case CFC_URI_CLASS: {
@@ -1113,6 +1122,9 @@ S_cfc_uri_to_url(CFCUri *uri_obj, CFCClass *doc_class, int dir_level) {
             url = S_document_to_url(doc, doc_class, dir_level);
             break;
         }
+
+        default:
+            break;
     }
 
     return url;

http://git-wip-us.apache.org/repos/asf/lucy-clownfish/blob/520a87ef/compiler/src/CFCPerlPod.c
----------------------------------------------------------------------
diff --git a/compiler/src/CFCPerlPod.c b/compiler/src/CFCPerlPod.c
index ffa0f04..8b728e0 100644
--- a/compiler/src/CFCPerlPod.c
+++ b/compiler/src/CFCPerlPod.c
@@ -570,12 +570,18 @@ S_convert_link(cmark_node *link, CFCClass *doc_class, int header_level) {
         return retval;
     }
 
-    char   *new_uri  = NULL;
-    char   *new_text = NULL;
-    CFCUri *uri_obj  = CFCUri_new(uri, doc_class);
-    int     type     = CFCUri_get_type(uri_obj);
+    char       *new_uri  = NULL;
+    char       *new_text = NULL;
+    CFCUri     *uri_obj  = CFCUri_new(uri, doc_class);
+    CFCUriType  type     = CFCUri_get_type(uri_obj);
 
     switch (type) {
+        case CFC_URI_ERROR: {
+            const char *error = CFCUri_get_error(uri_obj);
+            new_text = CFCUtil_sprintf("[%s]", error);
+            break;
+        }
+
         case CFC_URI_NULL:
             // Change all instances of NULL to 'undef'
             new_text = CFCUtil_strdup("undef");

http://git-wip-us.apache.org/repos/asf/lucy-clownfish/blob/520a87ef/compiler/src/CFCUri.c
----------------------------------------------------------------------
diff --git a/compiler/src/CFCUri.c b/compiler/src/CFCUri.c
index fc6e8e8..8c7c555 100644
--- a/compiler/src/CFCUri.c
+++ b/compiler/src/CFCUri.c
@@ -29,10 +29,11 @@ struct CFCUri {
     CFCBase      base;
     char        *string;
     CFCClass    *doc_class;
-    int          type;
+    CFCUriType   type;
     CFCClass    *klass;
     CFCDocument *document;
     char        *callable;
+    char        *error;
 };
 
 static const CFCMeta CFCURI_META = {
@@ -48,6 +49,9 @@ static void
 S_resolve(CFCUri *self, const char *prefix, const char *struct_sym,
           const char *callable);
 
+static void
+S_set_error(CFCUri *self, const char *error);
+
 static char*
 S_next_component(char **iter);
 
@@ -80,6 +84,7 @@ void
 CFCUri_destroy(CFCUri *self) {
     FREEMEM(self->string);
     FREEMEM(self->callable);
+    FREEMEM(self->error);
     CFCBase_decref((CFCBase*)self->doc_class);
     CFCBase_decref((CFCBase*)self->klass);
     CFCBase_decref((CFCBase*)self->document);
@@ -107,36 +112,34 @@ S_parse(CFCUri *self) {
         // Parcel
         parcel = component;
         component = S_next_component(&iter);
-    }
 
-    if (component) {
-        if (isupper(component[0])) {
-            // Class
-            struct_sym = component;
-        }
-        else if (component == buf && component[0] == '\0' && iter) {
-            // "cfish:.Method" style URL.
-            ;
-        }
-        else {
-            CFCUtil_die("Invalid component in Clownfish URI: %s",
-                        self->string);
+        if (!component) {
+            S_set_error(self, "Missing component in Clownfish URI");
+            goto done;
         }
+    }
 
-        component = S_next_component(&iter);
+    // struct_sym == NULL for "cfish:.Method" style URL.
+    // parcel implies struct_sym.
+    if (parcel || component[0] != '\0') {
+        struct_sym = component;
     }
 
+    component = S_next_component(&iter);
+
     if (component) {
         callable = component;
         component = S_next_component(&iter);
     }
 
     if (component) {
-        CFCUtil_die("Trailing components in Clownfish URI: %s", self->string);
+        S_set_error(self, "Trailing component in Clownfish URI");
+        goto done;
     }
 
     S_resolve(self, parcel, struct_sym, callable);
 
+done:
     FREEMEM(buf);
 }
 
@@ -145,67 +148,74 @@ S_resolve(CFCUri *self, const char *parcel, const char *struct_sym,
           const char *callable) {
 
     // Try to find a CFCClass.
-    if (struct_sym || callable) {
-        CFCClass *doc_class = self->doc_class;
-        CFCClass *klass     = NULL;
-
-        if (parcel) {
-            char *full_struct_sym = CFCUtil_sprintf("%s_%s", parcel, struct_sym);
-            klass = CFCClass_fetch_by_struct_sym(full_struct_sym);
-            FREEMEM(full_struct_sym);
-        }
-        else if (struct_sym && doc_class) {
-            const char *prefix = CFCClass_get_prefix(doc_class);
-            char *full_struct_sym = CFCUtil_sprintf("%s%s", prefix, struct_sym);
-            klass = CFCClass_fetch_by_struct_sym(full_struct_sym);
-            FREEMEM(full_struct_sym);
-        }
-        else {
-            klass = doc_class;
-        }
+    CFCClass *doc_class = self->doc_class;
+    CFCClass *klass     = NULL;
 
-        if (klass) {
-            self->type  = CFC_URI_CLASS;
-            self->klass = klass;
-            CFCBase_incref((CFCBase*)klass);
+    if (parcel) {
+        char *full_struct_sym = CFCUtil_sprintf("%s_%s", parcel, struct_sym);
+        klass = CFCClass_fetch_by_struct_sym(full_struct_sym);
+        FREEMEM(full_struct_sym);
+    }
+    else if (struct_sym && doc_class) {
+        const char *prefix = CFCClass_get_prefix(doc_class);
+        char *full_struct_sym = CFCUtil_sprintf("%s%s", prefix, struct_sym);
+        klass = CFCClass_fetch_by_struct_sym(full_struct_sym);
+        FREEMEM(full_struct_sym);
+    }
+    else if (callable) {
+        klass = doc_class;
+    }
 
-            if (callable) {
-                if (islower(callable[0])) {
-                    if (!CFCClass_function(klass, callable)) {
-                        CFCUtil_warn("Unknown function '%s' in Clownfish URI: %s",
-                                     callable, self->string);
-                    }
+    if (klass) {
+        self->type  = CFC_URI_CLASS;
+        self->klass = klass;
+        CFCBase_incref((CFCBase*)klass);
 
-                    self->type     = CFC_URI_FUNCTION;
-                    self->callable = CFCUtil_strdup(callable);
+        if (callable) {
+            if (islower(callable[0])) {
+                if (!CFCClass_function(klass, callable)) {
+                    CFCUtil_warn("Unknown function '%s' in Clownfish URI: %s",
+                                 callable, self->string);
                 }
-                else {
-                    if (!CFCClass_method(klass, callable)) {
-                        CFCUtil_warn("Unknown method '%s' in Clownfish URI: %s",
-                                     callable, self->string);
-                    }
-
-                    self->type     = CFC_URI_METHOD;
-                    self->callable = CFCUtil_strdup(callable);
+
+                self->type     = CFC_URI_FUNCTION;
+                self->callable = CFCUtil_strdup(callable);
+            }
+            else {
+                if (!CFCClass_method(klass, callable)) {
+                    CFCUtil_warn("Unknown method '%s' in Clownfish URI: %s",
+                                 callable, self->string);
                 }
+
+                self->type     = CFC_URI_METHOD;
+                self->callable = CFCUtil_strdup(callable);
             }
         }
+
+        return;
     }
 
     // Try to find a CFCDocument.
-    if (self->type == 0 && !parcel && struct_sym && !callable) {
+    if (!parcel && struct_sym && !callable) {
         CFCDocument *doc = CFCDocument_fetch(struct_sym);
 
         if (doc) {
             self->type     = CFC_URI_DOCUMENT;
             self->document = doc;
             CFCBase_incref((CFCBase*)doc);
+            return;
         }
     }
 
-    if (self->type == 0) {
-        CFCUtil_die("Couldn't resolve Clownfish URI: %s", self->string);
-    }
+    S_set_error(self, "Couldn't resolve Clownfish URI");
+}
+
+static void
+S_set_error(CFCUri *self, const char *error) {
+    self->type  = CFC_URI_ERROR;
+    self->error = CFCUtil_sprintf("%s: %s", error, self->string);
+
+    CFCUtil_warn(self->error);
 }
 
 static char*
@@ -231,7 +241,7 @@ CFCUri_get_string(CFCUri *self) {
     return self->string;
 }
 
-int
+CFCUriType
 CFCUri_get_type(CFCUri *self) {
     if (self->type == 0) { S_parse(self); }
     return self->type;
@@ -264,3 +274,12 @@ CFCUri_get_callable_name(CFCUri *self) {
     return self->callable;
 }
 
+const char*
+CFCUri_get_error(CFCUri *self) {
+    if (self->type == 0) { S_parse(self); }
+    if (self->error == NULL) {
+        CFCUtil_die("Not an error URI");
+    }
+    return self->error;
+}
+

http://git-wip-us.apache.org/repos/asf/lucy-clownfish/blob/520a87ef/compiler/src/CFCUri.h
----------------------------------------------------------------------
diff --git a/compiler/src/CFCUri.h b/compiler/src/CFCUri.h
index 9e22d4e..6c05653 100644
--- a/compiler/src/CFCUri.h
+++ b/compiler/src/CFCUri.h
@@ -21,11 +21,14 @@
 extern "C" {
 #endif
 
-#define CFC_URI_NULL        1
-#define CFC_URI_CLASS       2
-#define CFC_URI_FUNCTION    3
-#define CFC_URI_METHOD      4
-#define CFC_URI_DOCUMENT    5
+typedef enum {
+    CFC_URI_NULL     = 1,
+    CFC_URI_CLASS    = 2,
+    CFC_URI_FUNCTION = 3,
+    CFC_URI_METHOD   = 4,
+    CFC_URI_DOCUMENT = 5,
+    CFC_URI_ERROR    = 6
+} CFCUriType;
 
 typedef struct CFCUri CFCUri;
 struct CFCClass;
@@ -46,7 +49,7 @@ CFCUri_destroy(CFCUri *self);
 const char*
 CFCUri_get_string(CFCUri *self);
 
-int
+CFCUriType
 CFCUri_get_type(CFCUri *self);
 
 struct CFCClass*
@@ -58,6 +61,9 @@ CFCUri_get_document(CFCUri *self);
 const char*
 CFCUri_get_callable_name(CFCUri *self);
 
+const char*
+CFCUri_get_error(CFCUri *self);
+
 #ifdef __cplusplus
 }
 #endif


[11/20] lucy-clownfish git commit: Upgrade libcmark to 0.21.0

Posted by nw...@apache.org.
Upgrade libcmark to 0.21.0


Project: http://git-wip-us.apache.org/repos/asf/lucy-clownfish/repo
Commit: http://git-wip-us.apache.org/repos/asf/lucy-clownfish/commit/89c7b809
Tree: http://git-wip-us.apache.org/repos/asf/lucy-clownfish/tree/89c7b809
Diff: http://git-wip-us.apache.org/repos/asf/lucy-clownfish/diff/89c7b809

Branch: refs/heads/master
Commit: 89c7b8096972697e9c9d8153f5b58c9f5274e20a
Parents: aec7214
Author: Nick Wellnhofer <we...@aevum.de>
Authored: Sat Jul 25 18:48:05 2015 +0200
Committer: Nick Wellnhofer <we...@aevum.de>
Committed: Thu Aug 6 18:19:19 2015 +0200

----------------------------------------------------------------------
 compiler/modules/CommonMark/COPYING             |    73 +-
 compiler/modules/CommonMark/README.md           |   298 +-
 compiler/modules/CommonMark/src/blocks.c        |   556 +-
 compiler/modules/CommonMark/src/buffer.c        |   229 +-
 compiler/modules/CommonMark/src/buffer.h        |    94 +-
 compiler/modules/CommonMark/src/chunk.h         |    33 +-
 compiler/modules/CommonMark/src/cmark.c         |    16 +-
 compiler/modules/CommonMark/src/cmark.h         |    93 +-
 compiler/modules/CommonMark/src/cmark_version.h |     7 +
 compiler/modules/CommonMark/src/commonmark.c    |   462 +
 compiler/modules/CommonMark/src/config.h        |     4 +
 compiler/modules/CommonMark/src/config.h.in     |    23 -
 compiler/modules/CommonMark/src/debug.h         |    36 -
 compiler/modules/CommonMark/src/entities.inc    |  2138 ++
 compiler/modules/CommonMark/src/houdini.h       |    19 +-
 .../modules/CommonMark/src/houdini_href_e.c     |     4 +-
 .../modules/CommonMark/src/houdini_html_e.c     |     6 +-
 .../modules/CommonMark/src/houdini_html_u.c     |    92 +-
 compiler/modules/CommonMark/src/html.c          |    75 +-
 .../modules/CommonMark/src/html_unescape.gperf  |  2130 --
 compiler/modules/CommonMark/src/html_unescape.h | 13375 ---------
 compiler/modules/CommonMark/src/inlines.c       |   455 +-
 compiler/modules/CommonMark/src/inlines.h       |     8 +-
 compiler/modules/CommonMark/src/iterator.c      |    16 +-
 compiler/modules/CommonMark/src/latex.c         |   430 +
 compiler/modules/CommonMark/src/libcmark.pc.in  |    10 -
 compiler/modules/CommonMark/src/man.c           |   240 +-
 compiler/modules/CommonMark/src/node.c          |   175 +-
 compiler/modules/CommonMark/src/node.h          |    22 +-
 compiler/modules/CommonMark/src/parser.h        |     9 +-
 compiler/modules/CommonMark/src/references.c    |     4 +-
 compiler/modules/CommonMark/src/references.h    |     4 +-
 compiler/modules/CommonMark/src/render.c        |   186 +
 compiler/modules/CommonMark/src/render.h        |    66 +
 compiler/modules/CommonMark/src/scanners.c      | 25069 +++++++++++------
 compiler/modules/CommonMark/src/scanners.h      |    46 +-
 compiler/modules/CommonMark/src/scanners.re     |   185 +-
 compiler/modules/CommonMark/src/utf8.c          |   102 +-
 compiler/modules/CommonMark/src/utf8.h          |     6 +-
 compiler/modules/CommonMark/src/xml.c           |    24 +-
 compiler/src/CFCCHtml.c                         |     5 +-
 compiler/src/CFCCMan.c                          |     6 +-
 compiler/src/CFCPerlPod.c                       |     6 +-
 43 files changed, 21879 insertions(+), 24958 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/lucy-clownfish/blob/89c7b809/compiler/modules/CommonMark/COPYING
----------------------------------------------------------------------
diff --git a/compiler/modules/CommonMark/COPYING b/compiler/modules/CommonMark/COPYING
index 0bb3445..8099de3 100644
--- a/compiler/modules/CommonMark/COPYING
+++ b/compiler/modules/CommonMark/COPYING
@@ -13,10 +13,6 @@ modification, are permitted provided that the following conditions are met:
       disclaimer in the documentation and/or other materials provided
       with the distribution.
 
-    * Neither the name of John MacFarlane nor the names of other
-      contributors may be used to endorse or promote products derived
-      from this software without specific prior written permission.
-
 THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
 "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
 LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
@@ -108,10 +104,12 @@ DEALINGS IN THE SOFTWARE.
 
 -----
 
-normalize-reference.js is a slightly modified version of
-https://github.com/dmoscrop/fold-case:
+The normalization code in runtests.py was derived from the
+markdowntest project, Copyright 2013 Karl Dubost:
+
+The MIT License (MIT)
 
-Copyright Mathias Bynens <https://mathiasbynens.be/>
+Copyright (c) 2013 Karl Dubost
 
 Permission is hereby granted, free of charge, to any person obtaining
 a copy of this software and associated documentation files (the
@@ -134,27 +132,43 @@ WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
 
 -----
 
-The polyfill for String.fromCodePoint included in commonmark.js is
-Copyright Mathias Bynens <http://mathiasbynens.be/>
+The CommonMark spec (test/spec.txt) is
 
-Permission is hereby granted, free of charge, to any person obtaining
-a copy of this software and associated documentation files (the
-"Software"), to deal in the Software without restriction, including
-without limitation the rights to use, copy, modify, merge, publish,
-distribute, sublicense, and/or sell copies of the Software, and to
-permit persons to whom the Software is furnished to do so, subject to
-the following conditions:
+Copyright (C) 2014-15 John MacFarlane
 
-The above copyright notice and this permission notice shall be
-included in all copies or substantial portions of the Software.
+Released under the Creative Commons CC-BY-SA 4.0 license:
+<http://creativecommons.org/licenses/by-sa/4.0/>.
 
-THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
-NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
-LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
-OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
-WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
+-----
+
+The test software in test/ is
+
+Copyright (c) 2014, John MacFarlane
+
+All rights reserved.
+
+Redistribution and use in source and binary forms, with or without
+modification, are permitted provided that the following conditions are met:
+
+    * Redistributions of source code must retain the above copyright
+      notice, this list of conditions and the following disclaimer.
+
+    * Redistributions in binary form must reproduce the above
+      copyright notice, this list of conditions and the following
+      disclaimer in the documentation and/or other materials provided
+      with the distribution.
+
+THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
+"AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
+LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
+A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
+OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
+LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
+OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
 
 -----
 
@@ -169,5 +183,10 @@ Permission is hereby granted, free of charge, to any person obtaining a copy of
 
 The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.
 
-THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
-
+THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
+EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
+MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
+NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
+LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
+WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.

http://git-wip-us.apache.org/repos/asf/lucy-clownfish/blob/89c7b809/compiler/modules/CommonMark/README.md
----------------------------------------------------------------------
diff --git a/compiler/modules/CommonMark/README.md b/compiler/modules/CommonMark/README.md
index 4bbac88..4b73cb2 100644
--- a/compiler/modules/CommonMark/README.md
+++ b/compiler/modules/CommonMark/README.md
@@ -1,37 +1,66 @@
-CommonMark
-==========
+cmark
+=====
 
-CommonMark is a rationalized version of Markdown syntax,
-with a [spec][the spec] and BSD3-licensed reference
-implementations in C and JavaScript.
+[![Build Status]](https://travis-ci.org/jgm/cmark)
+[![Windows Build Status]](https://ci.appveyor.com/project/jgm/cmark)
 
-[Try it now!](http://spec.commonmark.org/dingus.html)
+`cmark` is the C reference implementation of [CommonMark], a
+rationalized version of Markdown syntax with a [spec][the spec].
+(For the JavaScript reference implementation, see
+[commonmark.js].)
 
-The implementations
--------------------
+It provides a shared library (`libcmark`) with functions for parsing
+CommonMark documents to an abstract syntax tree (AST), manipulating
+the AST, and rendering the document to HTML, groff man, LaTeX,
+CommonMark, or an XML representation of the AST.  It also provides a
+command-line program (`cmark`) for parsing and rendering CommonMark
+documents.
 
-The C implementation provides both a shared library (`libcmark`) and a
-standalone program `cmark` that converts CommonMark to HTML.  It is
-written in standard C99 and has no library dependencies.  The parser is
-very fast (see [benchmarks](benchmarks.md)).
+Advantages of this library:
+
+- **Portable.**  The library and program are written in standard
+  C99 and have no external dependencies.  They have been tested with
+  MSVC, gcc, tcc, and clang.
+
+- **Fast.** cmark can render a Markdown version of *War and Peace* in
+  the blink of an eye (127 milliseconds on a ten year old laptop,
+  vs. 100-400 milliseconds for an eye blink).  In our [benchmarks],
+  cmark is 10,000 times faster than the original `Markdown.pl`, and
+  on par with the very fastest available Markdown processors.
+
+- **Accurate.** The library passes all CommonMark conformance tests.
+
+- **Standardized.** The library can be expected to parse CommonMark
+  the same way as any other conforming parser.  So, for example,
+  you can use `commonmark.js` on the client to preview content that
+  will be rendered on the server using `cmark`.
+
+- **Robust.** The library has been extensively fuzz-tested using
+  [american fuzzy lop].  The test suite includes pathological cases
+  that bring many other Markdown parsers to a crawl (for example,
+  thousands-deep nested bracketed text or block quotes).
+
+- **Flexible.** CommonMark input is parsed to an AST which can be
+  manipulated programatically prior to rendering.
+
+- **Multiple renderers.**  Output in HTML, groff man, LaTeX, CommonMark,
+  and a custom XML format is supported. And it is easy to write new
+  renderers to support other formats.
+
+- **Free.** BSD2-licensed.
 
 It is easy to use `libcmark` in python, lua, ruby, and other dynamic
 languages: see the `wrappers/` subdirectory for some simple examples.
 
-The JavaScript implementation provides both an NPM package and a
-single JavaScript file, with no dependencies, that can be linked into
-an HTML page. For further information, see the
-[README in the js directory](js/README.md).
+There are also libraries that wrap `libcmark` for
+[go](https://github.com/rhinoman/go-commonmark),
+[Haskell](http://hackage.haskell.org/package/cmark),
+[ruby](https://github.com/gjtorikian/commonmarker),
+[Perl](https://metacpan.org/release/CommonMark), and
+[R](http://cran.r-project.org/package=commonmark).
 
-**A note on security:**
-Neither implementation attempts to sanitize link attributes or
-raw HTML.  If you use these libraries in applications that accept
-untrusted user input, you must run the output through an HTML
-sanitizer to protect against
-[XSS attacks](http://en.wikipedia.org/wiki/Cross-site_scripting).
-
-Installing (C)
---------------
+Installing
+----------
 
 Building the C program (`cmark`) and shared library (`libcmark`)
 requires [cmake].  If you modify `scanners.re`, then you will also
@@ -42,7 +71,10 @@ the repository to reduce build dependencies.
 If you have GNU make, you can simply `make`, `make test`, and `make
 install`.  This calls [cmake] to create a `Makefile` in the `build`
 directory, then uses that `Makefile` to create the executable and
-library.  The binaries can be found in `build/src`.
+library.  The binaries can be found in `build/src`.  The default
+installation prefix is `/usr/local`.  To change the installation
+prefix, pass the `INSTALL_PREFIX` variable if you run `make` for the
+first time: `make INSTALL_PREFIX=path`.
 
 For a more portable method, you can use [cmake] manually. [cmake] knows
 how to create build environments for many build systems.  For example,
@@ -60,19 +92,13 @@ Or, to create Xcode project files on OSX:
     mkdir build
     cd build
     cmake -G Xcode ..
-    make
-    make test
-    make install
+    open cmark.xcodeproj
 
 The GNU Makefile also provides a few other targets for developers.
 To run a benchmark:
 
     make bench
 
-To run a "fuzz test" against ten long randomly generated inputs:
-
-    make fuzztest
-
 To run a test for memory leaks using `valgrind`:
 
     make leakcheck
@@ -81,13 +107,20 @@ To reformat source code using `astyle`:
 
     make astyle
 
+To run a "fuzz test" against ten long randomly generated inputs:
+
+    make fuzztest
+
+To do a more systematic fuzz test with [american fuzzy lop]:
+
+    AFL_PATH=/path/to/afl_directory make afl
+
 To make a release tarball and zip archive:
 
     make archive
 
-
-Compiling for Windows
----------------------
+Installing (Windows)
+--------------------
 
 To compile with MSVC and NMAKE:
 
@@ -100,148 +133,23 @@ You can cross-compile a Windows binary and dll on linux if you have the
 
 The binaries will be in `build-mingw/windows/bin`.
 
-Installing (JavaScript)
------------------------
-
-The JavaScript library can be installed through `npm`:
+Usage
+-----
 
-    npm install commonmark
+Instructions for the use of the command line program and library can
+be found in the man pages in the `man` subdirectory.
 
-This includes a command-line converter called `commonmark`.
-
-If you want to use it in a client application, you can fetch
-a pre-built copy of `commonmark.js` from
-<http://spec.commonmark.org/js/commonmark.js>.
-
-For further information, see the
-[README in the js directory](js/README.md).
-
-The spec
+Security
 --------
 
-[The spec] contains over 500 embedded examples which serve as conformance
-tests. To run the tests using an executable `$PROG`:
-
-    python3 test/spec_tests.py --program $PROG
-
-If you want to extract the raw test data from the spec without
-actually running the tests, you can do:
-
-    python3 test/spec_tests.py --dump-tests
-
-and you'll get all the tests in JSON format.
-
-[The spec]:  http://spec.commonmark.org/0.13/
-
-The source of [the spec] is `spec.txt`.  This is basically a Markdown
-file, with code examples written in a shorthand form:
-
-    .
-    Markdown source
-    .
-    expected HTML output
-    .
-
-To build an HTML version of the spec, do `make spec.html`.  To build a
-PDF version, do `make spec.pdf`.  (Creating a PDF requires [pandoc]
-and a LaTeX installation.  Creating the HTML version requires only
-`libcmark` and `python3`.)
-
-The spec is written from the point of view of the human writer, not
-the computer reader.  It is not an algorithm---an English translation of
-a computer program---but a declarative description of what counts as a block
-quote, a code block, and each of the other structural elements that can
-make up a Markdown document.
-
-Because John Gruber's [canonical syntax
-description](http://daringfireball.net/projects/markdown/syntax) leaves
-many aspects of the syntax undetermined, writing a precise spec requires
-making a large number of decisions, many of them somewhat arbitrary.
-In making them, we have appealed to existing conventions and
-considerations of simplicity, readability, expressive power, and
-consistency.  We have tried to ensure that "normal" documents in the many
-incompatible existing implementations of Markdown will render, as far as
-possible, as their authors intended.  And we have tried to make the rules
-for different elements work together harmoniously.  In places where
-different decisions could have been made (for example, the rules
-governing list indentation), we have explained the rationale for
-my choices.  In a few cases, we have departed slightly from the canonical
-syntax description, in ways that we think further the goals of Markdown
-as stated in that description.
-
-For the most part, we have limited ourselves to the basic elements
-described in Gruber's canonical syntax description, eschewing extensions
-like footnotes and definition lists.  It is important to get the core
-right before considering such things. However, we have included a visible
-syntax for line breaks and fenced code blocks.
-
-Differences from original Markdown
-----------------------------------
-
-There are only a few places where this spec says things that contradict
-the canonical syntax description:
-
--   It allows all punctuation symbols to be backslash-escaped,
-    not just the symbols with special meanings in Markdown. We found
-    that it was just too hard to remember which symbols could be
-    escaped.
-
--   It introduces an alternative syntax for hard line
-    breaks, a backslash at the end of the line, supplementing the
-    two-spaces-at-the-end-of-line rule. This is motivated by persistent
-    complaints about the “invisible” nature of the two-space rule.
-
--   Link syntax has been made a bit more predictable (in a
-    backwards-compatible way). For example, `Markdown.pl` allows single
-    quotes around a title in inline links, but not in reference links.
-    This kind of difference is really hard for users to remember, so the
-    spec allows single quotes in both contexts.
-
--   The rule for HTML blocks differs, though in most real cases it
-    shouldn't make a difference. (See the section on HTML Blocks
-    for details.) The spec's proposal makes it easy to include Markdown
-    inside HTML block-level tags, if you want to, but also allows you to
-    exclude this. It is also makes parsing much easier, avoiding
-    expensive backtracking.
-
--   It does not collapse adjacent bird-track blocks into a single
-    blockquote:
-
-        > this is two
-
-        > blockquotes
-
-        > this is a single
-        >
-        > blockquote with two paragraphs
-
--   Rules for content in lists differ in a few respects, though (as with
-    HTML blocks), most lists in existing documents should render as
-    intended. There is some discussion of the choice points and
-    differences in the subsection of List Items entitled Motivation.
-    We think that the spec's proposal does better than any existing
-    implementation in rendering lists the way a human writer or reader
-    would intuitively understand them. (We could give numerous examples
-    of perfectly natural looking lists that nearly every existing
-    implementation flubs up.)
-
--   The spec stipulates that two blank lines break out of all list
-    contexts.  This is an attempt to deal with issues that often come up
-    when someone wants to have two adjacent lists, or a list followed by
-    an indented code block.
-
--   Changing bullet characters, or changing from bullets to numbers or
-    vice versa, starts a new list. We think that is almost always going
-    to be the writer's intent.
-
--   The number that begins an ordered list item may be followed by
-    either `.` or `)`. Changing the delimiter style starts a new
-    list.
-
--   The start number of an ordered list is significant.
-
--   Fenced code blocks are supported, delimited by either
-    backticks (```` ``` ```` or tildes (` ~~~ `).
+By default, the library will pass through raw HTML and potentially
+dangerous links (`javascript:`, `vbscript:`, `data:`, `file:`).
+
+It is recommended that users either disable this potentially unsafe
+feature by using the option `CMARK_OPT_SAFE` (or `--safe` with the
+command-line program), or run the output through an HTML sanitizer
+to protect against
+[XSS attacks](http://en.wikipedia.org/wiki/Cross-site_scripting).
 
 Contributing
 ------------
@@ -255,31 +163,21 @@ only for simple, clear, actionable issues.
 Authors
 -------
 
-The spec was written by John MacFarlane, drawing on
-
-- his experience writing and maintaining Markdown implementations in several
-  languages, including the first Markdown parser not based on regular
-  expression substitutions ([pandoc](http://github.com/jgm/pandoc)) and
-  the first markdown parsers based on PEG grammars
-  ([peg-markdown](http://github.com/jgm/peg-markdown),
-  [lunamark](http://github.com/jgm/lunamark))
-- a detailed examination of the differences between existing Markdown
-  implementations using [BabelMark 2](http://johnmacfarlane.net/babelmark2/),
-  and
-- extensive discussions with David Greenspan, Jeff Atwood, Vicent
-  Marti, Neil Williams, and Benjamin Dumke-von der Ehe.
-
-John MacFarlane was also responsible for the original versions of the
-C and JavaScript implementations.  The block parsing algorithm was
-worked out together with David Greenspan.  Vicent Marti
-optimized the C implementation for performance, increasing its speed
-tenfold.  Kārlis Gaņģis helped work out a better parsing algorithm
-for links and emphasis, eliminating several worst-case performance
-issues.  Nick Wellnhofer contributed many improvements, including
-most of the C library's API and its test harness.  Vitaly Puzrin
-has offered much good advice about the JavaScript implementation.
-
+John MacFarlane wrote the original library and program.
+The block parsing algorithm was worked out together with David
+Greenspan. Vicent Marti optimized the C implementation for
+performance, increasing its speed tenfold.  Kārlis Gaņģis helped
+work out a better parsing algorithm for links and emphasis,
+eliminating several worst-case performance issues.
+Nick Wellnhofer contributed many improvements, including
+most of the C library's API and its test harness.
+
+[benchmarks]: benchmarks.md
+[the spec]: http://spec.commonmark.org
+[CommonMark]: http://commonmark.org
 [cmake]: http://www.cmake.org/download/
-[pandoc]: http://johnmacfarlane.net/pandoc/
 [re2c]: http://re2c.org
-
+[commonmark.js]: https://github.com/jgm/commonmark.js
+[Build Status]: https://img.shields.io/travis/jgm/cmark/master.svg?style=flat
+[Windows Build Status]: https://ci.appveyor.com/api/projects/status/32r7s2skrgm9ubva?svg=true
+[american fuzzy lop]: http://lcamtuf.coredump.cx/afl/

http://git-wip-us.apache.org/repos/asf/lucy-clownfish/blob/89c7b809/compiler/modules/CommonMark/src/blocks.c
----------------------------------------------------------------------
diff --git a/compiler/modules/CommonMark/src/blocks.c b/compiler/modules/CommonMark/src/blocks.c
index dafbb9b..f8b7495 100644
--- a/compiler/modules/CommonMark/src/blocks.c
+++ b/compiler/modules/CommonMark/src/blocks.c
@@ -13,18 +13,25 @@
 #include "inlines.h"
 #include "houdini.h"
 #include "buffer.h"
-#include "debug.h"
 
 #define CODE_INDENT 4
+#define TAB_STOP 4
+
 #define peek_at(i, n) (i)->data[n]
 
+static inline bool
+S_is_line_end_char(char c)
+{
+	return (c == '\n' || c == '\r');
+}
+
 static void
 S_parser_feed(cmark_parser *parser, const unsigned char *buffer, size_t len,
               bool eof);
 
 static void
 S_process_line(cmark_parser *parser, const unsigned char *buffer,
-               size_t bytes);
+               bufsize_t bytes);
 
 static cmark_node* make_block(cmark_node_type tag, int start_line, int start_column)
 {
@@ -43,14 +50,14 @@ static cmark_node* make_block(cmark_node_type tag, int start_line, int start_col
 	return e;
 }
 
-// Create a root document cmark_node.
+// Create a root document node.
 static cmark_node* make_document()
 {
 	cmark_node *e = make_block(NODE_DOCUMENT, 1, 1);
 	return e;
 }
 
-cmark_parser *cmark_parser_new()
+cmark_parser *cmark_parser_new(int options)
 {
 	cmark_parser *parser = (cmark_parser*)malloc(sizeof(cmark_parser));
 	cmark_node *document = make_document();
@@ -63,9 +70,16 @@ cmark_parser *cmark_parser_new()
 	parser->root = document;
 	parser->current = document;
 	parser->line_number = 0;
+	parser->offset = 0;
+	parser->column = 0;
+	parser->first_nonspace = 0;
+	parser->first_nonspace_column = 0;
+	parser->indent = 0;
+	parser->blank = false;
 	parser->curline = line;
 	parser->last_line_length = 0;
 	parser->linebuf = buf;
+	parser->options = options;
 
 	return parser;
 }
@@ -84,15 +98,19 @@ static cmark_node*
 finalize(cmark_parser *parser, cmark_node* b);
 
 // Returns true if line has only space characters, else false.
-static bool is_blank(cmark_strbuf *s, int offset)
+static bool is_blank(cmark_strbuf *s, bufsize_t offset)
 {
 	while (offset < s->size) {
 		switch (s->ptr[offset]) {
+		case '\r':
 		case '\n':
 			return true;
 		case ' ':
 			offset++;
 			break;
+		case '\t':
+			offset++;
+			break;
 		default:
 			return false;
 		}
@@ -116,7 +134,7 @@ static inline bool accepts_lines(cmark_node_type block_type)
 	        block_type == NODE_CODE_BLOCK);
 }
 
-static void add_line(cmark_node* node, cmark_chunk *ch, int offset)
+static void add_line(cmark_node* node, cmark_chunk *ch, bufsize_t offset)
 {
 	assert(node->open);
 	cmark_strbuf_put(&node->string_content, ch->data + offset, ch->len - offset);
@@ -124,12 +142,13 @@ static void add_line(cmark_node* node, cmark_chunk *ch, int offset)
 
 static void remove_trailing_blank_lines(cmark_strbuf *ln)
 {
-	int i;
+	bufsize_t i;
+	unsigned char c;
 
 	for (i = ln->size - 1; i >= 0; --i) {
-		unsigned char c = ln->ptr[i];
+		c = ln->ptr[i];
 
-		if (c != ' ' && c != '\t' && c != '\r' && c != '\n')
+		if (c != ' ' && c != '\t' && !S_is_line_end_char(c))
 			break;
 	}
 
@@ -138,12 +157,19 @@ static void remove_trailing_blank_lines(cmark_strbuf *ln)
 		return;
 	}
 
-	i = cmark_strbuf_strchr(ln, '\n', i);
-	if (i >= 0)
+
+	for(; i < ln->size; ++i) {
+		c = ln->ptr[i];
+
+		if (!S_is_line_end_char(c))
+			continue;
+
 		cmark_strbuf_truncate(ln, i);
+		break;
+	}
 }
 
-// Check to see if a cmark_node ends with a blank line, descending
+// Check to see if a node ends with a blank line, descending
 // if needed into lists and sublists.
 static bool ends_with_blank_line(cmark_node* node)
 {
@@ -184,18 +210,14 @@ static int break_out_of_lists(cmark_parser *parser, cmark_node ** bptr)
 static cmark_node*
 finalize(cmark_parser *parser, cmark_node* b)
 {
-	int firstlinelen;
-	int pos;
+	bufsize_t pos;
 	cmark_node* item;
 	cmark_node* subitem;
 	cmark_node* parent;
 
 	parent = b->parent;
 
-	// don't do anything if the cmark_node is already closed
-	if (!b->open)
-		return parent;
-
+	assert(b->open);  // shouldn't call finalize on closed blocks
 	b->open = false;
 
 	if (parser->curline->size == 0) {
@@ -206,9 +228,11 @@ finalize(cmark_parser *parser, cmark_node* b)
 	           (b->type == NODE_CODE_BLOCK && b->as.code.fenced) ||
 	           (b->type == NODE_HEADER && b->as.header.setext)) {
 		b->end_line = parser->line_number;
-		b->end_column = parser->curline->size -
-		                (parser->curline->ptr[parser->curline->size - 1] == '\n' ?
-		                 1 : 0);
+		b->end_column = parser->curline->size;
+		if (b->end_column && parser->curline->ptr[b->end_column - 1] == '\n')
+			b->end_column -= 1;
+		if (b->end_column && parser->curline->ptr[b->end_column - 1] == '\r')
+			b->end_column -= 1;
 	} else {
 		b->end_line = parser->line_number - 1;
 		b->end_column = parser->last_line_length;
@@ -234,19 +258,27 @@ finalize(cmark_parser *parser, cmark_node* b)
 		} else {
 
 			// first line of contents becomes info
-			firstlinelen = cmark_strbuf_strchr(&b->string_content, '\n', 0);
+			for (pos = 0; pos < b->string_content.size; ++pos) {
+				if (S_is_line_end_char(b->string_content.ptr[pos]))
+					break;
+			}
+			assert(pos < b->string_content.size);
 
 			cmark_strbuf tmp = GH_BUF_INIT;
 			houdini_unescape_html_f(
 			    &tmp,
 			    b->string_content.ptr,
-			    firstlinelen
+			    pos
 			);
 			cmark_strbuf_trim(&tmp);
 			cmark_strbuf_unescape(&tmp);
 			b->as.code.info = cmark_chunk_buf_detach(&tmp);
 
-			cmark_strbuf_drop(&b->string_content, firstlinelen + 1);
+			if (b->string_content.ptr[pos] == '\r')
+				pos += 1;
+			if (b->string_content.ptr[pos] == '\n')
+				pos += 1;
+			cmark_strbuf_drop(&b->string_content, pos);
 		}
 		b->as.code.literal = cmark_chunk_buf_detach(&b->string_content);
 		break;
@@ -290,14 +322,14 @@ finalize(cmark_parser *parser, cmark_node* b)
 	return parent;
 }
 
-// Add a cmark_node as child of another.  Return pointer to child.
+// Add a node as child of another.  Return pointer to child.
 static cmark_node* add_child(cmark_parser *parser, cmark_node* parent,
                              cmark_node_type block_type, int start_column)
 {
 	assert(parent);
 
-	// if 'parent' isn't the kind of cmark_node that can accept this child,
-	// then back up til we hit a cmark_node that can.
+	// if 'parent' isn't the kind of node that can accept this child,
+	// then back up til we hit a node that can.
 	while (!can_contain(parent->type, block_type)) {
 		parent = finalize(parser, parent);
 	}
@@ -317,9 +349,9 @@ static cmark_node* add_child(cmark_parser *parser, cmark_node* parent,
 }
 
 
-// Walk through cmark_node and all children, recursively, parsing
+// Walk through node and all children, recursively, parsing
 // string content into inline content where appropriate.
-static void process_inlines(cmark_node* root, cmark_reference_map *refmap)
+static void process_inlines(cmark_node* root, cmark_reference_map *refmap, int options)
 {
 	cmark_iter *iter = cmark_iter_new(root);
 	cmark_node *cur;
@@ -330,7 +362,7 @@ static void process_inlines(cmark_node* root, cmark_reference_map *refmap)
 		if (ev_type == CMARK_EVENT_ENTER) {
 			if (cur->type == NODE_PARAGRAPH ||
 			    cur->type == NODE_HEADER) {
-				cmark_parse_inlines(cur, refmap);
+				cmark_parse_inlines(cur, refmap, options);
 			}
 		}
 	}
@@ -341,16 +373,16 @@ static void process_inlines(cmark_node* root, cmark_reference_map *refmap)
 // Attempts to parse a list item marker (bullet or enumerated).
 // On success, returns length of the marker, and populates
 // data with the details.  On failure, returns 0.
-static int parse_list_marker(cmark_chunk *input, int pos, cmark_list **dataptr)
+static bufsize_t parse_list_marker(cmark_chunk *input, bufsize_t pos, cmark_list **dataptr)
 {
 	unsigned char c;
-	int startpos;
+	bufsize_t startpos;
 	cmark_list *data;
 
 	startpos = pos;
 	c = peek_at(input, pos);
 
-	if ((c == '*' || c == '-' || c == '+') && !scan_hrule(input, pos)) {
+	if (c == '*' || c == '-' || c == '+') {
 		pos++;
 		if (!cmark_isspace(peek_at(input, pos))) {
 			return 0;
@@ -368,11 +400,16 @@ static int parse_list_marker(cmark_chunk *input, int pos, cmark_list **dataptr)
 		}
 	} else if (cmark_isdigit(c)) {
 		int start = 0;
+		int digits = 0;
 
 		do {
 			start = (10 * start) + (peek_at(input, pos) - '0');
 			pos++;
-		} while (cmark_isdigit(peek_at(input, pos)));
+			digits++;
+			// We limit to 9 digits to avoid overflow,
+			// assuming max int is 2^31 - 1
+			// This also seems to be the limit for 'start' in some browsers.
+		} while (digits < 9 && cmark_isdigit(peek_at(input, pos)));
 
 		c = peek_at(input, pos);
 		if (c == '.' || c == ')') {
@@ -419,15 +456,15 @@ static cmark_node *finalize_document(cmark_parser *parser)
 	}
 
 	finalize(parser, parser->root);
-	process_inlines(parser->root, parser->refmap);
+	process_inlines(parser->root, parser->refmap, parser->options);
 
 	return parser->root;
 }
 
-cmark_node *cmark_parse_file(FILE *f)
+cmark_node *cmark_parse_file(FILE *f, int options)
 {
 	unsigned char buffer[4096];
-	cmark_parser *parser = cmark_parser_new();
+	cmark_parser *parser = cmark_parser_new(options);
 	size_t bytes;
 	cmark_node *document;
 
@@ -444,9 +481,9 @@ cmark_node *cmark_parse_file(FILE *f)
 	return document;
 }
 
-cmark_node *cmark_parse_document(const char *buffer, size_t len)
+cmark_node *cmark_parse_document(const char *buffer, size_t len, int options)
 {
-	cmark_parser *parser = cmark_parser_new();
+	cmark_parser *parser = cmark_parser_new(options);
 	cmark_node *document;
 
 	S_parser_feed(parser, (const unsigned char *)buffer, len, true);
@@ -467,38 +504,58 @@ S_parser_feed(cmark_parser *parser, const unsigned char *buffer, size_t len,
               bool eof)
 {
 	const unsigned char *end = buffer + len;
+	static const uint8_t repl[] = {239, 191, 189};
 
 	while (buffer < end) {
-		const unsigned char *eol
-		    = (const unsigned char *)memchr(buffer, '\n',
-		                                    end - buffer);
-		size_t line_len;
-
-		if (eol) {
-			line_len = eol + 1 - buffer;
-		} else if (eof) {
-			line_len = end - buffer;
-		} else {
-			cmark_strbuf_put(parser->linebuf, buffer, end - buffer);
-			break;
+		const unsigned char *eol;
+		bufsize_t chunk_len;
+		bool process = false;
+		for (eol = buffer; eol < end; ++eol) {
+			if (S_is_line_end_char(*eol)) {
+				if (eol < end && *eol == '\r')
+					eol++;
+				if (eol < end && *eol == '\n')
+					eol++;
+				process = true;
+				break;
+			}
+			if (*eol == '\0' && eol < end) {
+				break;
+			}
+		}
+		if (eol >= end && eof) {
+			process = true;
 		}
 
-		if (parser->linebuf->size > 0) {
-			cmark_strbuf_put(parser->linebuf, buffer, line_len);
-			S_process_line(parser, parser->linebuf->ptr,
-			               parser->linebuf->size);
-			cmark_strbuf_clear(parser->linebuf);
+		chunk_len = cmark_strbuf_check_bufsize(eol - buffer);
+		if (process) {
+			if (parser->linebuf->size > 0) {
+				cmark_strbuf_put(parser->linebuf, buffer, chunk_len);
+				S_process_line(parser, parser->linebuf->ptr,
+				               parser->linebuf->size);
+				cmark_strbuf_clear(parser->linebuf);
+			} else {
+				S_process_line(parser, buffer, chunk_len);
+			}
 		} else {
-			S_process_line(parser, buffer, line_len);
+			if (eol < end && *eol == '\0') {
+				// omit NULL byte
+				cmark_strbuf_put(parser->linebuf, buffer, chunk_len);
+				// add replacement character
+				cmark_strbuf_put(parser->linebuf, repl, 3);
+				chunk_len += 1; // so we advance the buffer past NULL
+			} else {
+				cmark_strbuf_put(parser->linebuf, buffer, chunk_len);
+			}
 		}
 
-		buffer += line_len;
+		buffer += chunk_len;
 	}
 }
 
 static void chop_trailing_hashtags(cmark_chunk *ch)
 {
-	int n, orig_n;
+	bufsize_t n, orig_n;
 
 	cmark_chunk_rtrim(ch);
 	orig_n = n = ch->len - 1;
@@ -515,29 +572,77 @@ static void chop_trailing_hashtags(cmark_chunk *ch)
 }
 
 static void
-S_process_line(cmark_parser *parser, const unsigned char *buffer, size_t bytes)
+S_find_first_nonspace(cmark_parser *parser, cmark_chunk *input)
+{
+	char c;
+	int chars_to_tab = TAB_STOP - (parser->column % TAB_STOP);
+
+	parser->first_nonspace = parser->offset;
+	parser->first_nonspace_column = parser->column;
+	while ((c = peek_at(input, parser->first_nonspace))) {
+		if (c == ' ') {
+			parser->first_nonspace += 1;
+			parser->first_nonspace_column += 1;
+			chars_to_tab = chars_to_tab - 1;
+			if (chars_to_tab == 0) {
+				chars_to_tab = TAB_STOP;
+			}
+		} else if (c == '\t') {
+			parser->first_nonspace += 1;
+			parser->first_nonspace_column += chars_to_tab;
+			chars_to_tab = TAB_STOP;
+		} else {
+			break;
+		}
+	}
+
+	parser->indent = parser->first_nonspace_column - parser->column;
+	parser->blank = S_is_line_end_char(peek_at(input, parser->first_nonspace));
+}
+
+static void
+S_advance_offset(cmark_parser *parser, cmark_chunk *input, bufsize_t count, bool columns)
+{
+	char c;
+	int chars_to_tab;
+	while (count > 0 && (c = peek_at(input, parser->offset))) {
+		if (c == '\t') {
+			chars_to_tab = 4 - (parser->column % TAB_STOP);
+			parser->column += chars_to_tab;
+			parser->offset += 1;
+			count -= (columns ? chars_to_tab : 1);
+		} else {
+			parser->offset += 1;
+			parser->column += 1; // assume ascii; block starts are ascii
+			count -= 1;
+		}
+	}
+}
+
+
+static void
+S_process_line(cmark_parser *parser, const unsigned char *buffer, bufsize_t bytes)
 {
 	cmark_node* last_matched_container;
-	int offset = 0;
-	int matched = 0;
+	bufsize_t matched = 0;
 	int lev = 0;
 	int i;
 	cmark_list *data = NULL;
 	bool all_matched = true;
 	cmark_node* container;
-	cmark_node* cur = parser->current;
-	bool blank = false;
-	int first_nonspace;
-	int indent;
+	bool indented;
 	cmark_chunk input;
+	bool maybe_lazy;
 
-	utf8proc_detab(parser->curline, buffer, bytes);
-
-	// Add a newline to the end if not present:
-	// TODO this breaks abstraction:
-	if (parser->curline->ptr[parser->curline->size - 1] != '\n') {
-		cmark_strbuf_putc(parser->curline, '\n');
+	if (parser->options & CMARK_OPT_VALIDATE_UTF8) {
+		utf8proc_check(parser->curline, buffer, bytes);
+	} else {
+		cmark_strbuf_put(parser->curline, buffer, bytes);
 	}
+	parser->offset = 0;
+	parser->column = 0;
+	parser->blank = false;
+
 	input.data = parser->curline->ptr;
 	input.len = parser->curline->size;
 
@@ -546,38 +651,33 @@ S_process_line(cmark_parser *parser, const unsigned char *buffer, size_t bytes)
 
 	parser->line_number++;
 
-	// for each containing cmark_node, try to parse the associated line start.
-	// bail out on failure:  container will point to the last matching cmark_node.
+	// for each containing node, try to parse the associated line start.
+	// bail out on failure:  container will point to the last matching node.
 
 	while (container->last_child && container->last_child->open) {
 		container = container->last_child;
 
-		first_nonspace = offset;
-		while (peek_at(&input, first_nonspace) == ' ') {
-			first_nonspace++;
-		}
-
-		indent = first_nonspace - offset;
-		blank = peek_at(&input, first_nonspace) == '\n';
+		S_find_first_nonspace(parser, &input);
 
 		if (container->type == NODE_BLOCK_QUOTE) {
-			matched = indent <= 3 && peek_at(&input, first_nonspace) == '>';
+			matched = parser->indent <= 3 && peek_at(&input, parser->first_nonspace) == '>';
 			if (matched) {
-				offset = first_nonspace + 1;
-				if (peek_at(&input, offset) == ' ')
-					offset++;
+				S_advance_offset(parser, &input, parser->indent + 1, true);
+				if (peek_at(&input, parser->offset) == ' ')
+					parser->offset++;
 			} else {
 				all_matched = false;
 			}
 
 		} else if (container->type == NODE_ITEM) {
-
-			if (indent >= container->as.list.marker_offset +
+			if (parser->indent >= container->as.list.marker_offset +
 			    container->as.list.padding) {
-				offset += container->as.list.marker_offset +
-				          container->as.list.padding;
-			} else if (blank) {
-				offset = first_nonspace;
+				S_advance_offset(parser, &input,
+				                 container->as.list.marker_offset +
+				                 container->as.list.padding, true);
+			} else if (parser->blank) {
+				S_advance_offset(parser, &input,
+				                 parser->first_nonspace - parser->offset, false);
 			} else {
 				all_matched = false;
 			}
@@ -585,34 +685,36 @@ S_process_line(cmark_parser *parser, const unsigned char *buffer, size_t bytes)
 		} else if (container->type == NODE_CODE_BLOCK) {
 
 			if (!container->as.code.fenced) { // indented
-				if (indent >= CODE_INDENT) {
-					offset += CODE_INDENT;
-				} else if (blank) {
-					offset = first_nonspace;
+				if (parser->indent >= CODE_INDENT) {
+					S_advance_offset(parser, &input, CODE_INDENT, true);
+				} else if (parser->blank) {
+					S_advance_offset(parser, &input,
+					                 parser->first_nonspace - parser->offset,
+					                 false);
 				} else {
 					all_matched = false;
 				}
 			} else { // fenced
 				matched = 0;
-				if (indent <= 3 &&
-					(peek_at(&input, first_nonspace) ==
-					 container->as.code.fence_char)) {
+				if (parser->indent <= 3 &&
+				    (peek_at(&input, parser->first_nonspace) ==
+				     container->as.code.fence_char)) {
 					matched = scan_close_code_fence(&input,
-							first_nonspace);
+					                                parser->first_nonspace);
 				}
 				if (matched >= container->as.code.fence_length) {
 					// closing fence - and since we're at
 					// the end of a line, we can return:
 					all_matched = false;
-					offset += matched;
-					finalize(parser, container);
+					S_advance_offset(parser, &input, matched, false);
+					parser->current = finalize(parser, container);
 					goto finished;
 				} else {
-					// skip opt. spaces of fence offset
+					// skip opt. spaces of fence parser->offset
 					i = container->as.code.fence_offset;
 					while (i > 0 &&
-					    peek_at(&input, offset) == ' ') {
-						offset++;
+					       peek_at(&input, parser->offset) == ' ') {
+						S_advance_offset(parser, &input, 1, false);
 						i--;
 					}
 				}
@@ -624,20 +726,38 @@ S_process_line(cmark_parser *parser, const unsigned char *buffer, size_t bytes)
 
 		} else if (container->type == NODE_HTML) {
 
-			if (blank) {
-				all_matched = false;
+			switch (container->as.html_block_type) {
+			case 1:
+			case 2:
+			case 3:
+			case 4:
+			case 5:
+				// these types of blocks can accept blanks
+				break;
+			case 6:
+			case 7:
+				if (parser->blank) {
+					all_matched = false;
+				}
+				break;
+			default:
+				fprintf(stderr,
+				        "Error (%s:%d): Unknown HTML block type %d\n",
+				        __FILE__, __LINE__,
+				        container->as.html_block_type);
+				exit(1);
 			}
 
 		} else if (container->type == NODE_PARAGRAPH) {
 
-			if (blank) {
+			if (parser->blank) {
 				all_matched = false;
 			}
 
 		}
 
 		if (!all_matched) {
-			container = container->parent;  // back up to last matching cmark_node
+			container = container->parent;  // back up to last matching node
 			break;
 		}
 	}
@@ -645,48 +765,33 @@ S_process_line(cmark_parser *parser, const unsigned char *buffer, size_t bytes)
 	last_matched_container = container;
 
 	// check to see if we've hit 2nd blank line, break out of list:
-	if (blank && container->last_line_blank) {
+	if (parser->blank && container->last_line_blank) {
 		break_out_of_lists(parser, &container);
 	}
 
-	// unless last matched container is code cmark_node, try new container starts:
+	maybe_lazy = parser->current->type == NODE_PARAGRAPH;
+	// try new container starts:
 	while (container->type != NODE_CODE_BLOCK &&
 	       container->type != NODE_HTML) {
 
-		first_nonspace = offset;
-		while (peek_at(&input, first_nonspace) == ' ')
-			first_nonspace++;
-
-		indent = first_nonspace - offset;
-		blank = peek_at(&input, first_nonspace) == '\n';
-
-		if (indent >= CODE_INDENT) {
-			if (cur->type != NODE_PARAGRAPH && !blank) {
-				offset += CODE_INDENT;
-				container = add_child(parser, container, NODE_CODE_BLOCK, offset + 1);
-				container->as.code.fenced = false;
-				container->as.code.fence_char = 0;
-				container->as.code.fence_length = 0;
-				container->as.code.fence_offset = 0;
-				container->as.code.info = cmark_chunk_literal("");
-			} else { // indent > 4 in lazy line
-				break;
-			}
+		S_find_first_nonspace(parser, &input);
+		indented = parser->indent >= CODE_INDENT;
 
-		} else if (peek_at(&input, first_nonspace) == '>') {
+		if (!indented && peek_at(&input, parser->first_nonspace) == '>') {
 
-			offset = first_nonspace + 1;
+			S_advance_offset(parser, &input, parser->first_nonspace + 1 - parser->offset, false);
 			// optional following character
-			if (peek_at(&input, offset) == ' ')
-				offset++;
-			container = add_child(parser, container, NODE_BLOCK_QUOTE, offset + 1);
+			if (peek_at(&input, parser->offset) == ' ')
+				S_advance_offset(parser, &input, 1, false);
+			container = add_child(parser, container, NODE_BLOCK_QUOTE, parser->offset + 1);
 
-		} else if ((matched = scan_atx_header_start(&input, first_nonspace))) {
+		} else if (!indented && (matched = scan_atx_header_start(&input, parser->first_nonspace))) {
 
-			offset = first_nonspace + matched;
-			container = add_child(parser, container, NODE_HEADER, offset + 1);
+			S_advance_offset(parser, &input,
+			                 parser->first_nonspace + matched - parser->offset, false);
+			container = add_child(parser, container, NODE_HEADER, parser->offset + 1);
 
-			int hashpos = cmark_chunk_strchr(&input, '#', first_nonspace);
+			bufsize_t hashpos = cmark_chunk_strchr(&input, '#', parser->first_nonspace);
 			int level = 0;
 
 			while (peek_at(&input, hashpos) == '#') {
@@ -696,78 +801,99 @@ S_process_line(cmark_parser *parser, const unsigned char *buffer, size_t bytes)
 			container->as.header.level = level;
 			container->as.header.setext = false;
 
-		} else if ((matched = scan_open_code_fence(&input, first_nonspace))) {
+		} else if (!indented && (matched = scan_open_code_fence(&input, parser->first_nonspace))) {
 
-			container = add_child(parser, container, NODE_CODE_BLOCK, first_nonspace + 1);
+			container = add_child(parser, container, NODE_CODE_BLOCK, parser->first_nonspace + 1);
 			container->as.code.fenced = true;
-			container->as.code.fence_char = peek_at(&input, first_nonspace);
+			container->as.code.fence_char = peek_at(&input, parser->first_nonspace);
 			container->as.code.fence_length = matched;
-			container->as.code.fence_offset = first_nonspace - offset;
+			container->as.code.fence_offset = parser->first_nonspace - parser->offset;
 			container->as.code.info = cmark_chunk_literal("");
-			offset = first_nonspace + matched;
+			S_advance_offset(parser, &input, parser->first_nonspace + matched - parser->offset, false);
 
-		} else if ((matched = scan_html_block_tag(&input, first_nonspace))) {
+		} else if (!indented &&
+		           ((matched = scan_html_block_start(&input, parser->first_nonspace)) ||
+		            (container->type != NODE_PARAGRAPH &&
+		             (matched = scan_html_block_start_7(&input, parser->first_nonspace))))) {
 
-			container = add_child(parser, container, NODE_HTML, first_nonspace + 1);
-			// note, we don't adjust offset because the tag is part of the text
+			container = add_child(parser, container, NODE_HTML, parser->first_nonspace + 1);
+			container->as.html_block_type = matched;
+			// note, we don't adjust parser->offset because the tag is part of the text
 
-		} else if (container->type == NODE_PARAGRAPH &&
-		           (lev = scan_setext_header_line(&input, first_nonspace)) &&
+		} else if (!indented &&
+		           container->type == NODE_PARAGRAPH &&
+		           (lev = scan_setext_header_line(&input, parser->first_nonspace)) &&
 		           // check that there is only one line in the paragraph:
-		           cmark_strbuf_strrchr(&container->string_content, '\n',
-		                                cmark_strbuf_len(&container->string_content) - 2) < 0) {
+		           (cmark_strbuf_strrchr(&container->string_content, '\n',
+		                                 cmark_strbuf_len(&container->string_content) - 2) < 0)) {
 
 			container->type = NODE_HEADER;
 			container->as.header.level = lev;
 			container->as.header.setext = true;
-			offset = input.len - 1;
+			S_advance_offset(parser, &input, input.len - 1 - parser->offset, false);
 
-		} else if (!(container->type == NODE_PARAGRAPH && !all_matched) &&
-		           (matched = scan_hrule(&input, first_nonspace))) {
+		} else if (!indented &&
+		           !(container->type == NODE_PARAGRAPH &&
+		             !all_matched) &&
+		           (matched = scan_hrule(&input, parser->first_nonspace))) {
 
 			// it's only now that we know the line is not part of a setext header:
-			container = add_child(parser, container, NODE_HRULE, first_nonspace + 1);
+			container = add_child(parser, container, NODE_HRULE, parser->first_nonspace + 1);
 			container = finalize(parser, container);
-			offset = input.len - 1;
+			S_advance_offset(parser, &input, input.len - 1 - parser->offset, false);
 
-		} else if ((matched = parse_list_marker(&input, first_nonspace, &data))) {
+		} else if ((matched = parse_list_marker(&input, parser->first_nonspace, &data)) &&
+		           (!indented || container->type == NODE_LIST)) {
+			// Note that we can have new list items starting with >= 4
+			// spaces indent, as long as the list container is still open.
 
 			// compute padding:
-			offset = first_nonspace + matched;
+			S_advance_offset(parser, &input, parser->first_nonspace + matched - parser->offset, false);
 			i = 0;
-			while (i <= 5 && peek_at(&input, offset + i) == ' ') {
+			while (i <= 5 && peek_at(&input, parser->offset + i) == ' ') {
 				i++;
 			}
 			// i = number of spaces after marker, up to 5
-			if (i >= 5 || i < 1 || peek_at(&input, offset) == '\n') {
+			if (i >= 5 || i < 1 ||
+			    S_is_line_end_char(peek_at(&input, parser->offset))) {
 				data->padding = matched + 1;
 				if (i > 0) {
-					offset += 1;
+					S_advance_offset(parser, &input, 1, false);
 				}
 			} else {
 				data->padding = matched + i;
-				offset += i;
+				S_advance_offset(parser, &input, i, true);
 			}
 
 			// check container; if it's a list, see if this list item
 			// can continue the list; otherwise, create a list container.
 
-			data->marker_offset = indent;
+			data->marker_offset = parser->indent;
 
 			if (container->type != NODE_LIST ||
 			    !lists_match(&container->as.list, data)) {
 				container = add_child(parser, container, NODE_LIST,
-				                      first_nonspace + 1);
+				                      parser->first_nonspace + 1);
 
 				memcpy(&container->as.list, data, sizeof(*data));
 			}
 
 			// add the list item
 			container = add_child(parser, container, NODE_ITEM,
-			                      first_nonspace + 1);
+			                      parser->first_nonspace + 1);
 			/* TODO: static */
 			memcpy(&container->as.list, data, sizeof(*data));
 			free(data);
+
+		} else if (indented && !maybe_lazy && !parser->blank) {
+			S_advance_offset(parser, &input, CODE_INDENT, true);
+			container = add_child(parser, container, NODE_CODE_BLOCK, parser->offset + 1);
+			container->as.code.fenced = false;
+			container->as.code.fence_char = 0;
+			container->as.code.fence_length = 0;
+			container->as.code.fence_offset = 0;
+			container->as.code.info = cmark_chunk_literal("");
+
 		} else {
 			break;
 		}
@@ -776,19 +902,15 @@ S_process_line(cmark_parser *parser, const unsigned char *buffer, size_t bytes)
 			// if it's a line container, it can't contain other containers
 			break;
 		}
+		maybe_lazy = false;
 	}
 
-	// what remains at offset is a text line.  add the text to the
+	// what remains at parser->offset is a text line.  add the text to the
 	// appropriate container.
 
-	first_nonspace = offset;
-	while (peek_at(&input, first_nonspace) == ' ')
-		first_nonspace++;
-
-	indent = first_nonspace - offset;
-	blank = peek_at(&input, first_nonspace) == '\n';
+	S_find_first_nonspace(parser, &input);
 
-	if (blank && container->last_child) {
+	if (parser->blank && container->last_child) {
 		container->last_child->last_line_blank = true;
 	}
 
@@ -796,7 +918,7 @@ S_process_line(cmark_parser *parser, const unsigned char *buffer, size_t bytes)
 	// and we don't count blanks in fenced code for purposes of tight/loose
 	// lists or breaking out of lists.  we also don't set last_line_blank
 	// on an empty list item.
-	container->last_line_blank = (blank &&
+	container->last_line_blank = (parser->blank &&
 	                              container->type != NODE_BLOCK_QUOTE &&
 	                              container->type != NODE_HEADER &&
 	                              !(container->type == NODE_CODE_BLOCK &&
@@ -811,28 +933,68 @@ S_process_line(cmark_parser *parser, const unsigned char *buffer, size_t bytes)
 		cont = cont->parent;
 	}
 
-	if (cur != last_matched_container &&
+	if (parser->current != last_matched_container &&
 	    container == last_matched_container &&
-	    !blank &&
-	    cur->type == NODE_PARAGRAPH &&
-	    cmark_strbuf_len(&cur->string_content) > 0) {
+	    !parser->blank &&
+	    parser->current->type == NODE_PARAGRAPH &&
+	    cmark_strbuf_len(&parser->current->string_content) > 0) {
 
-		add_line(cur, &input, offset);
+		add_line(parser->current, &input, parser->offset);
 
 	} else { // not a lazy continuation
 
 		// finalize any blocks that were not matched and set cur to container:
-		while (cur != last_matched_container) {
-			cur = finalize(parser, cur);
-			assert(cur != NULL);
+		while (parser->current != last_matched_container) {
+			parser->current = finalize(parser, parser->current);
+			assert(parser->current != NULL);
 		}
 
-		if (container->type == NODE_CODE_BLOCK ||
-		    container->type == NODE_HTML) {
+		if (container->type == NODE_CODE_BLOCK) {
+
+			add_line(container, &input, parser->offset);
+
+		} else if (container->type == NODE_HTML) {
+
+			add_line(container, &input, parser->offset);
+
+			int matches_end_condition;
+			switch (container->as.html_block_type) {
+			case 1:
+				// </script>, </style>, </pre>
+				matches_end_condition =
+				    scan_html_block_end_1(&input, parser->first_nonspace);
+				break;
+			case 2:
+				// -->
+				matches_end_condition =
+				    scan_html_block_end_2(&input, parser->first_nonspace);
+				break;
+			case 3:
+				// ?>
+				matches_end_condition =
+				    scan_html_block_end_3(&input, parser->first_nonspace);
+				break;
+			case 4:
+				// >
+				matches_end_condition =
+				    scan_html_block_end_4(&input, parser->first_nonspace);
+				break;
+			case 5:
+				// ]]>
+				matches_end_condition =
+				    scan_html_block_end_5(&input, parser->first_nonspace);
+				break;
+			default:
+				matches_end_condition = 0;
+				break;
+			}
 
-			add_line(container, &input, offset);
+			if (matches_end_condition) {
+				container = finalize(parser, container);
+				assert(parser->current != NULL);
+			}
 
-		} else if (blank) {
+		} else if (parser->blank) {
 
 			// ??? do nothing
 
@@ -842,22 +1004,26 @@ S_process_line(cmark_parser *parser, const unsigned char *buffer, size_t bytes)
 			    container->as.header.setext == false) {
 				chop_trailing_hashtags(&input);
 			}
-			add_line(container, &input, first_nonspace);
+			add_line(container, &input, parser->first_nonspace);
 
 		} else {
 			// create paragraph container for line
-			container = add_child(parser, container, NODE_PARAGRAPH, first_nonspace + 1);
-			add_line(container, &input, first_nonspace);
+			container = add_child(parser, container, NODE_PARAGRAPH, parser->first_nonspace + 1);
+			add_line(container, &input, parser->first_nonspace);
 
 		}
 
 		parser->current = container;
 	}
 finished:
-	parser->last_line_length = parser->curline->size -
-	                           (parser->curline->ptr[parser->curline->size - 1] == '\n' ?
-	                            1 : 0);
-	;
+	parser->last_line_length = parser->curline->size;
+	if (parser->last_line_length &&
+	    parser->curline->ptr[parser->last_line_length - 1] == '\n')
+		parser->last_line_length -= 1;
+	if (parser->last_line_length &&
+	    parser->curline->ptr[parser->last_line_length - 1] == '\r')
+		parser->last_line_length -= 1;
+
 	cmark_strbuf_clear(parser->curline);
 
 }
@@ -871,7 +1037,13 @@ cmark_node *cmark_parser_finish(cmark_parser *parser)
 	}
 
 	finalize_document(parser);
+
+	if (parser->options & CMARK_OPT_NORMALIZE) {
+		cmark_consolidate_text_nodes(parser->root);
+	}
+
 	cmark_strbuf_free(parser->curline);
+
 #if CMARK_DEBUG_NODES
 	if (cmark_node_check(parser->root, stderr)) {
 		abort();

http://git-wip-us.apache.org/repos/asf/lucy-clownfish/blob/89c7b809/compiler/modules/CommonMark/src/buffer.c
----------------------------------------------------------------------
diff --git a/compiler/modules/CommonMark/src/buffer.c b/compiler/modules/CommonMark/src/buffer.c
index 0df6561..e07fba6 100644
--- a/compiler/modules/CommonMark/src/buffer.c
+++ b/compiler/modules/CommonMark/src/buffer.c
@@ -4,6 +4,7 @@
 #include <string.h>
 #include <stdio.h>
 #include <stdlib.h>
+#include <stdint.h>
 
 #include "config.h"
 #include "cmark_ctype.h"
@@ -13,83 +14,90 @@
  * assume ptr is non-NULL and zero terminated even for new cmark_strbufs.
  */
 unsigned char cmark_strbuf__initbuf[1];
-unsigned char cmark_strbuf__oom[1];
-
-#define ENSURE_SIZE(b, d)					\
-	if ((d) > buf->asize && cmark_strbuf_grow(b, (d)) < 0)	\
-		return -1;
 
 #ifndef MIN
 #define MIN(x,y)  ((x<y) ? x : y)
 #endif
 
-void cmark_strbuf_init(cmark_strbuf *buf, int initial_size)
+void cmark_strbuf_init(cmark_strbuf *buf, bufsize_t initial_size)
 {
 	buf->asize = 0;
 	buf->size = 0;
 	buf->ptr = cmark_strbuf__initbuf;
 
-	if (initial_size)
+	if (initial_size > 0)
 		cmark_strbuf_grow(buf, initial_size);
 }
 
-int cmark_strbuf_try_grow(cmark_strbuf *buf, int target_size, bool mark_oom)
+void cmark_strbuf_overflow_err()
 {
-	unsigned char *new_ptr;
-	int new_size;
+	fprintf(stderr, "String buffer overflow");
+	abort();
+}
 
-	if (buf->ptr == cmark_strbuf__oom)
-		return -1;
+static inline void
+S_strbuf_grow_by(cmark_strbuf *buf, size_t add)
+{
+	size_t target_size = (size_t)buf->size + add;
 
-	if (target_size <= buf->asize)
-		return 0;
+	if (target_size < add             /* Integer overflow. */
+	    || target_size > BUFSIZE_MAX  /* Truncation overflow. */
+	   ) {
+		cmark_strbuf_overflow_err();
+		return; /* unreachable */
+	}
+
+	if ((bufsize_t)target_size >= buf->asize)
+		cmark_strbuf_grow(buf, (bufsize_t)target_size);
+}
+
+void cmark_strbuf_grow(cmark_strbuf *buf, bufsize_t target_size)
+{
+	unsigned char *new_ptr;
+
+	if (target_size < buf->asize)
+		return;
 
 	if (buf->asize == 0) {
-		new_size = target_size;
 		new_ptr = NULL;
 	} else {
-		new_size = buf->asize;
 		new_ptr = buf->ptr;
 	}
 
-	/* grow the buffer size by 1.5, until it's big enough
-	 * to fit our target size */
-	while (new_size < target_size)
-		new_size = (new_size << 1) - (new_size >> 1);
+	/* Oversize the buffer by 50% to guarantee amortized linear time
+	 * complexity on append operations. */
+	size_t new_size = (size_t)target_size + (size_t)target_size / 2;
+
+	/* Account for terminating null byte. */
+	new_size += 1;
 
 	/* round allocation up to multiple of 8 */
 	new_size = (new_size + 7) & ~7;
 
+	if (new_size < (size_t)target_size  /* Integer overflow. */
+	    || new_size > BUFSIZE_MAX       /* Truncation overflow. */
+	   ) {
+		if (target_size >= BUFSIZE_MAX) {
+			/* No space for terminating null byte. */
+			cmark_strbuf_overflow_err();
+			return; /* unreachable */
+		}
+		/* Oversize by the maximum possible amount. */
+		new_size = BUFSIZE_MAX;
+	}
+
 	new_ptr = (unsigned char *)realloc(new_ptr, new_size);
 
 	if (!new_ptr) {
-		if (mark_oom)
-			buf->ptr = cmark_strbuf__oom;
-		return -1;
+		perror("realloc in cmark_strbuf_grow");
+		abort();
 	}
 
-	buf->asize = new_size;
+	buf->asize = (bufsize_t)new_size;
 	buf->ptr   = new_ptr;
-
-	/* truncate the existing buffer size if necessary */
-	if (buf->size >= buf->asize)
-		buf->size = buf->asize - 1;
-	buf->ptr[buf->size] = '\0';
-
-	return 0;
-}
-
-int cmark_strbuf_grow(cmark_strbuf *buf, int target_size)
-{
-	return cmark_strbuf_try_grow(buf, target_size, true);
-}
-
-bool cmark_strbuf_oom(const cmark_strbuf *buf)
-{
-	return (buf->ptr == cmark_strbuf__oom);
 }
 
-size_t cmark_strbuf_len(const cmark_strbuf *buf)
+bufsize_t cmark_strbuf_len(const cmark_strbuf *buf)
 {
 	return buf->size;
 }
@@ -98,7 +106,7 @@ void cmark_strbuf_free(cmark_strbuf *buf)
 {
 	if (!buf) return;
 
-	if (buf->ptr != cmark_strbuf__initbuf && buf->ptr != cmark_strbuf__oom)
+	if (buf->ptr != cmark_strbuf__initbuf)
 		free(buf->ptr);
 
 	cmark_strbuf_init(buf, 0);
@@ -112,106 +120,106 @@ void cmark_strbuf_clear(cmark_strbuf *buf)
 		buf->ptr[0] = '\0';
 }
 
-int cmark_strbuf_set(cmark_strbuf *buf, const unsigned char *data, int len)
+void cmark_strbuf_set(cmark_strbuf *buf, const unsigned char *data, bufsize_t len)
 {
 	if (len <= 0 || data == NULL) {
 		cmark_strbuf_clear(buf);
 	} else {
 		if (data != buf->ptr) {
-			ENSURE_SIZE(buf, len + 1);
+			if (len >= buf->asize)
+				cmark_strbuf_grow(buf, len);
 			memmove(buf->ptr, data, len);
 		}
 		buf->size = len;
 		buf->ptr[buf->size] = '\0';
 	}
-	return 0;
 }
 
-int cmark_strbuf_sets(cmark_strbuf *buf, const char *string)
+void cmark_strbuf_sets(cmark_strbuf *buf, const char *string)
 {
-	return cmark_strbuf_set(buf,
-	                        (const unsigned char *)string,
-	                        string ? strlen(string) : 0);
+	cmark_strbuf_set(buf, (const unsigned char *)string,
+	                 string ? cmark_strbuf_safe_strlen(string) : 0);
 }
 
-int cmark_strbuf_putc(cmark_strbuf *buf, int c)
+void cmark_strbuf_putc(cmark_strbuf *buf, int c)
 {
-	ENSURE_SIZE(buf, buf->size + 2);
+	S_strbuf_grow_by(buf, 1);
 	buf->ptr[buf->size++] = c;
 	buf->ptr[buf->size] = '\0';
-	return 0;
 }
 
-int cmark_strbuf_put(cmark_strbuf *buf, const unsigned char *data, int len)
+void cmark_strbuf_put(cmark_strbuf *buf, const unsigned char *data, bufsize_t len)
 {
 	if (len <= 0)
-		return 0;
+		return;
 
-	ENSURE_SIZE(buf, buf->size + len + 1);
+	S_strbuf_grow_by(buf, len);
 	memmove(buf->ptr + buf->size, data, len);
 	buf->size += len;
 	buf->ptr[buf->size] = '\0';
-	return 0;
 }
 
-int cmark_strbuf_puts(cmark_strbuf *buf, const char *string)
+void cmark_strbuf_puts(cmark_strbuf *buf, const char *string)
 {
-	return cmark_strbuf_put(buf, (const unsigned char *)string, strlen(string));
+	cmark_strbuf_put(buf, (const unsigned char *)string,
+	                 cmark_strbuf_safe_strlen(string));
 }
 
-int cmark_strbuf_vprintf(cmark_strbuf *buf, const char *format, va_list ap)
+void cmark_strbuf_vprintf(cmark_strbuf *buf, const char *format, va_list ap)
 {
-	const int expected_size = buf->size + (strlen(format) * 2);
-	int len;
-
-	ENSURE_SIZE(buf, expected_size);
+	size_t expected_size = strlen(format);
+	if (expected_size <= SIZE_MAX / 2)
+		expected_size *= 2;
+	S_strbuf_grow_by(buf, expected_size);
 
 	while (1) {
 		va_list args;
 		va_copy(args, ap);
 
-		len = vsnprintf(
-		          (char *)buf->ptr + buf->size,
-		          buf->asize - buf->size,
-		          format, args
-		      );
+		int len = vsnprintf(
+		              (char *)buf->ptr + buf->size,
+		              buf->asize - buf->size,
+		              format, args
+		          );
+#ifndef HAVE_C99_SNPRINTF
+		// Assume we're on Windows.
+		if (len < 0) {
+			len = _vscprintf(format, args);
+		}
+#endif
 
 		va_end(args);
 
 		if (len < 0) {
-			free(buf->ptr);
-			buf->ptr = cmark_strbuf__oom;
-			return -1;
+			perror("vsnprintf in cmark_strbuf_vprintf");
+			abort();
 		}
 
-		if (len + 1 <= buf->asize - buf->size) {
+		if ((size_t)len < (size_t)(buf->asize - buf->size)) {
 			buf->size += len;
 			break;
 		}
 
-		ENSURE_SIZE(buf, buf->size + len + 1);
+		S_strbuf_grow_by(buf, len);
 	}
-
-	return 0;
 }
 
-int cmark_strbuf_printf(cmark_strbuf *buf, const char *format, ...)
+void cmark_strbuf_printf(cmark_strbuf *buf, const char *format, ...)
 {
-	int r;
 	va_list ap;
 
 	va_start(ap, format);
-	r = cmark_strbuf_vprintf(buf, format, ap);
+	cmark_strbuf_vprintf(buf, format, ap);
 	va_end(ap);
-
-	return r;
 }
 
-void cmark_strbuf_copy_cstr(char *data, int datasize, const cmark_strbuf *buf)
+void cmark_strbuf_copy_cstr(char *data, bufsize_t datasize, const cmark_strbuf *buf)
 {
-	int copylen;
+	bufsize_t copylen;
 
-	assert(data && datasize && buf);
+	assert(buf);
+	if (!data || datasize <= 0)
+		return;
 
 	data[0] = '\0';
 
@@ -236,7 +244,7 @@ unsigned char *cmark_strbuf_detach(cmark_strbuf *buf)
 {
 	unsigned char *data = buf->ptr;
 
-	if (buf->asize == 0 || buf->ptr == cmark_strbuf__oom) {
+	if (buf->asize == 0) {
 		/* return an empty string */
 		return (unsigned char *)calloc(1, 1);
 	}
@@ -245,22 +253,6 @@ unsigned char *cmark_strbuf_detach(cmark_strbuf *buf)
 	return data;
 }
 
-void cmark_strbuf_attach(cmark_strbuf *buf, unsigned char *ptr, int asize)
-{
-	cmark_strbuf_free(buf);
-
-	if (ptr) {
-		buf->ptr = ptr;
-		buf->size = strlen((char *)ptr);
-		if (asize)
-			buf->asize = (asize < buf->size) ? buf->size + 1 : asize;
-		else /* pass 0 to fall back on strlen + 1 */
-			buf->asize = buf->size + 1;
-	} else {
-		cmark_strbuf_grow(buf, asize);
-	}
-}
-
 int cmark_strbuf_cmp(const cmark_strbuf *a, const cmark_strbuf *b)
 {
 	int result = memcmp(a->ptr, b->ptr, MIN(a->size, b->size));
@@ -268,20 +260,28 @@ int cmark_strbuf_cmp(const cmark_strbuf *a, const cmark_strbuf *b)
 	       (a->size < b->size) ? -1 : (a->size > b->size) ? 1 : 0;
 }
 
-int cmark_strbuf_strchr(const cmark_strbuf *buf, int c, int pos)
+bufsize_t cmark_strbuf_strchr(const cmark_strbuf *buf, int c, bufsize_t pos)
 {
+	if (pos >= buf->size)
+		return -1;
+	if (pos < 0)
+		pos = 0;
+
 	const unsigned char *p = (unsigned char *)memchr(buf->ptr + pos, c, buf->size - pos);
 	if (!p)
 		return -1;
 
-	return (int)(p - (const unsigned char *)buf->ptr);
+	return (bufsize_t)(p - (const unsigned char *)buf->ptr);
 }
 
-int cmark_strbuf_strrchr(const cmark_strbuf *buf, int c, int pos)
+bufsize_t cmark_strbuf_strrchr(const cmark_strbuf *buf, int c, bufsize_t pos)
 {
-	int i;
+	if (pos < 0 || buf->size == 0)
+		return -1;
+	if (pos >= buf->size)
+		pos = buf->size - 1;
 
-	for (i = pos; i >= 0; i--) {
+	for (bufsize_t i = pos; i >= 0; i--) {
 		if (buf->ptr[i] == (unsigned char) c)
 			return i;
 	}
@@ -289,17 +289,22 @@ int cmark_strbuf_strrchr(const cmark_strbuf *buf, int c, int pos)
 	return -1;
 }
 
-void cmark_strbuf_truncate(cmark_strbuf *buf, int len)
+void cmark_strbuf_truncate(cmark_strbuf *buf, bufsize_t len)
 {
+	if (len < 0)
+		len = 0;
+
 	if (len < buf->size) {
 		buf->size = len;
 		buf->ptr[buf->size] = '\0';
 	}
 }
 
-void cmark_strbuf_drop(cmark_strbuf *buf, int n)
+void cmark_strbuf_drop(cmark_strbuf *buf, bufsize_t n)
 {
 	if (n > 0) {
+		if (n > buf->size)
+			n = buf->size;
 		buf->size = buf->size - n;
 		if (buf->size)
 			memmove(buf->ptr, buf->ptr + n, buf->size);
@@ -325,7 +330,7 @@ void cmark_strbuf_rtrim(cmark_strbuf *buf)
 
 void cmark_strbuf_trim(cmark_strbuf *buf)
 {
-	int i = 0;
+	bufsize_t i = 0;
 
 	if (!buf->size)
 		return;
@@ -343,7 +348,7 @@ void cmark_strbuf_trim(cmark_strbuf *buf)
 void cmark_strbuf_normalize_whitespace(cmark_strbuf *s)
 {
 	bool last_char_was_space = false;
-	int r, w;
+	bufsize_t r, w;
 
 	for (r = 0, w = 0; r < s->size; ++r) {
 		switch (s->ptr[r]) {
@@ -368,11 +373,11 @@ void cmark_strbuf_normalize_whitespace(cmark_strbuf *s)
 // Destructively unescape a string: remove backslashes before punctuation chars.
 extern void cmark_strbuf_unescape(cmark_strbuf *buf)
 {
-	int r, w;
+	bufsize_t r, w;
 
 	for (r = 0, w = 0; r < buf->size; ++r) {
 		if (buf->ptr[r] == '\\' && cmark_ispunct(buf->ptr[r + 1]))
-			continue;
+			r++;
 
 		buf->ptr[w++] = buf->ptr[r];
 	}

http://git-wip-us.apache.org/repos/asf/lucy-clownfish/blob/89c7b809/compiler/modules/CommonMark/src/buffer.h
----------------------------------------------------------------------
diff --git a/compiler/modules/CommonMark/src/buffer.h b/compiler/modules/CommonMark/src/buffer.h
index fb9f910..babd051 100644
--- a/compiler/modules/CommonMark/src/buffer.h
+++ b/compiler/modules/CommonMark/src/buffer.h
@@ -3,22 +3,25 @@
 
 #include <stddef.h>
 #include <stdarg.h>
+#include <string.h>
+#include <limits.h>
 #include "config.h"
 
 #ifdef __cplusplus
 extern "C" {
 #endif
 
+typedef int bufsize_t;
+
 typedef struct {
 	unsigned char *ptr;
-	int asize, size;
+	bufsize_t asize, size;
 } cmark_strbuf;
 
 extern unsigned char cmark_strbuf__initbuf[];
 
-extern unsigned char cmark_strbuf__oom[];
-
 #define GH_BUF_INIT { cmark_strbuf__initbuf, 0, 0 }
+#define BUFSIZE_MAX INT_MAX
 
 /**
  * Initialize a cmark_strbuf structure.
@@ -26,51 +29,22 @@ extern unsigned char cmark_strbuf__oom[];
  * For the cases where GH_BUF_INIT cannot be used to do static
  * initialization.
  */
-void cmark_strbuf_init(cmark_strbuf *buf, int initial_size);
-
-/**
- * Attempt to grow the buffer to hold at least `target_size` bytes.
- *
- * If the allocation fails, this will return an error.  If mark_oom is true,
- * this will mark the buffer as invalid for future operations; if false,
- * existing buffer content will be preserved, but calling code must handle
- * that buffer was not expanded.
- */
-int cmark_strbuf_try_grow(cmark_strbuf *buf, int target_size, bool mark_oom);
+void cmark_strbuf_init(cmark_strbuf *buf, bufsize_t initial_size);
 
 /**
  * Grow the buffer to hold at least `target_size` bytes.
- *
- * If the allocation fails, this will return an error and the buffer will be
- * marked as invalid for future operations, invaliding contents.
- *
- * @return 0 on success or -1 on failure
  */
-int cmark_strbuf_grow(cmark_strbuf *buf, int target_size);
+void cmark_strbuf_grow(cmark_strbuf *buf, bufsize_t target_size);
 
 void cmark_strbuf_free(cmark_strbuf *buf);
 void cmark_strbuf_swap(cmark_strbuf *buf_a, cmark_strbuf *buf_b);
 
-/**
- * Test if there have been any reallocation failures with this cmark_strbuf.
- *
- * Any function that writes to a cmark_strbuf can fail due to memory allocation
- * issues.  If one fails, the cmark_strbuf will be marked with an OOM error and
- * further calls to modify the buffer will fail.  Check cmark_strbuf_oom() at the
- * end of your sequence and it will be true if you ran out of memory at any
- * point with that buffer.
- *
- * @return false if no error, true if allocation error
- */
-bool cmark_strbuf_oom(const cmark_strbuf *buf);
-
-size_t cmark_strbuf_len(const cmark_strbuf *buf);
+bufsize_t cmark_strbuf_len(const cmark_strbuf *buf);
 
 int cmark_strbuf_cmp(const cmark_strbuf *a, const cmark_strbuf *b);
 
-void cmark_strbuf_attach(cmark_strbuf *buf, unsigned char *ptr, int asize);
 unsigned char *cmark_strbuf_detach(cmark_strbuf *buf);
-void cmark_strbuf_copy_cstr(char *data, int datasize, const cmark_strbuf *buf);
+void cmark_strbuf_copy_cstr(char *data, bufsize_t datasize, const cmark_strbuf *buf);
 
 static inline const char *cmark_strbuf_cstr(const cmark_strbuf *buf)
 {
@@ -79,33 +53,41 @@ static inline const char *cmark_strbuf_cstr(const cmark_strbuf *buf)
 
 #define cmark_strbuf_at(buf, n) ((buf)->ptr[n])
 
-/*
- * Functions below that return int value error codes will return 0 on
- * success or -1 on failure (which generally means an allocation failed).
- * Using a cmark_strbuf where the allocation has failed with result in -1 from
- * all further calls using that buffer.  As a result, you can ignore the
- * return code of these functions and call them in a series then just call
- * cmark_strbuf_oom at the end.
- */
-int cmark_strbuf_set(cmark_strbuf *buf, const unsigned char *data, int len);
-int cmark_strbuf_sets(cmark_strbuf *buf, const char *string);
-int cmark_strbuf_putc(cmark_strbuf *buf, int c);
-int cmark_strbuf_put(cmark_strbuf *buf, const unsigned char *data, int len);
-int cmark_strbuf_puts(cmark_strbuf *buf, const char *string);
-int cmark_strbuf_printf(cmark_strbuf *buf, const char *format, ...)
-CMARK_ATTRIBUTE((format (printf, 2, 3)));
-int cmark_strbuf_vprintf(cmark_strbuf *buf, const char *format, va_list ap);
+void cmark_strbuf_set(cmark_strbuf *buf, const unsigned char *data, bufsize_t len);
+void cmark_strbuf_sets(cmark_strbuf *buf, const char *string);
+void cmark_strbuf_putc(cmark_strbuf *buf, int c);
+void cmark_strbuf_put(cmark_strbuf *buf, const unsigned char *data, bufsize_t len);
+void cmark_strbuf_puts(cmark_strbuf *buf, const char *string);
+void cmark_strbuf_printf(cmark_strbuf *buf, const char *format, ...)
+	CMARK_ATTRIBUTE((format (printf, 2, 3)));
+void cmark_strbuf_vprintf(cmark_strbuf *buf, const char *format, va_list ap);
 void cmark_strbuf_clear(cmark_strbuf *buf);
 
-int cmark_strbuf_strchr(const cmark_strbuf *buf, int c, int pos);
-int cmark_strbuf_strrchr(const cmark_strbuf *buf, int c, int pos);
-void cmark_strbuf_drop(cmark_strbuf *buf, int n);
-void cmark_strbuf_truncate(cmark_strbuf *buf, int len);
+bufsize_t cmark_strbuf_strchr(const cmark_strbuf *buf, int c, bufsize_t pos);
+bufsize_t cmark_strbuf_strrchr(const cmark_strbuf *buf, int c, bufsize_t pos);
+void cmark_strbuf_drop(cmark_strbuf *buf, bufsize_t n);
+void cmark_strbuf_truncate(cmark_strbuf *buf, bufsize_t len);
 void cmark_strbuf_rtrim(cmark_strbuf *buf);
 void cmark_strbuf_trim(cmark_strbuf *buf);
 void cmark_strbuf_normalize_whitespace(cmark_strbuf *s);
 void cmark_strbuf_unescape(cmark_strbuf *s);
 
+/* Print error and abort. */
+void cmark_strbuf_overflow_err(void);
+
+static inline bufsize_t
+cmark_strbuf_check_bufsize(size_t size) {
+	if (size > BUFSIZE_MAX) {
+		cmark_strbuf_overflow_err();
+	}
+	return (bufsize_t)size;
+}
+
+static inline bufsize_t
+cmark_strbuf_safe_strlen(const char *str) {
+	return cmark_strbuf_check_bufsize(strlen(str));
+}
+
 #ifdef __cplusplus
 }
 #endif

http://git-wip-us.apache.org/repos/asf/lucy-clownfish/blob/89c7b809/compiler/modules/CommonMark/src/chunk.h
----------------------------------------------------------------------
diff --git a/compiler/modules/CommonMark/src/chunk.h b/compiler/modules/CommonMark/src/chunk.h
index 54c4b16..f23a02d 100644
--- a/compiler/modules/CommonMark/src/chunk.h
+++ b/compiler/modules/CommonMark/src/chunk.h
@@ -7,10 +7,12 @@
 #include "cmark_ctype.h"
 #include "buffer.h"
 
+#define CMARK_CHUNK_EMPTY { NULL, 0, 0 }
+
 typedef struct {
 	unsigned char *data;
-	int len;
-	int alloc;  // also implies a NULL-terminated string
+	bufsize_t len;
+	bufsize_t alloc;  // also implies a NULL-terminated string
 } cmark_chunk;
 
 static inline void cmark_chunk_free(cmark_chunk *c)
@@ -49,10 +51,10 @@ static inline void cmark_chunk_trim(cmark_chunk *c)
 	cmark_chunk_rtrim(c);
 }
 
-static inline int cmark_chunk_strchr(cmark_chunk *ch, int c, int offset)
+static inline bufsize_t cmark_chunk_strchr(cmark_chunk *ch, int c, bufsize_t offset)
 {
 	const unsigned char *p = (unsigned char *)memchr(ch->data + offset, c, ch->len - offset);
-	return p ? (int)(p - ch->data) : ch->len;
+	return p ? (bufsize_t)(p - ch->data) : ch->len;
 }
 
 static inline const char *cmark_chunk_to_cstr(cmark_chunk *c)
@@ -64,7 +66,9 @@ static inline const char *cmark_chunk_to_cstr(cmark_chunk *c)
 	}
 	str = (unsigned char *)malloc(c->len + 1);
 	if(str != NULL) {
-		memcpy(str, c->data, c->len);
+		if(c->len > 0) {
+			memcpy(str, c->data, c->len);
+		}
 		str[c->len] = 0;
 	}
 	c->data  = str;
@@ -78,19 +82,26 @@ static inline void cmark_chunk_set_cstr(cmark_chunk *c, const char *str)
 	if (c->alloc) {
 		free(c->data);
 	}
-	c->len   = strlen(str);
-	c->data  = (unsigned char *)malloc(c->len + 1);
-	c->alloc = 1;
-	memcpy(c->data, str, c->len + 1);
+	if (str == NULL) {
+		c->len   = 0;
+		c->data  = NULL;
+		c->alloc = 0;
+	} else {
+		c->len   = cmark_strbuf_safe_strlen(str);
+		c->data  = (unsigned char *)malloc(c->len + 1);
+		c->alloc = 1;
+		memcpy(c->data, str, c->len + 1);
+	}
 }
 
 static inline cmark_chunk cmark_chunk_literal(const char *data)
 {
-	cmark_chunk c = {(unsigned char *)data, data ? strlen(data) : 0, 0};
+	bufsize_t len = data ? cmark_strbuf_safe_strlen(data) : 0;
+	cmark_chunk c = {(unsigned char *)data, len, 0};
 	return c;
 }
 
-static inline cmark_chunk cmark_chunk_dup(const cmark_chunk *ch, int pos, int len)
+static inline cmark_chunk cmark_chunk_dup(const cmark_chunk *ch, bufsize_t pos, bufsize_t len)
 {
 	cmark_chunk c = {ch->data + pos, len, 0};
 	return c;

http://git-wip-us.apache.org/repos/asf/lucy-clownfish/blob/89c7b809/compiler/modules/CommonMark/src/cmark.c
----------------------------------------------------------------------
diff --git a/compiler/modules/CommonMark/src/cmark.c b/compiler/modules/CommonMark/src/cmark.c
index 1d7a500..ca9807b 100644
--- a/compiler/modules/CommonMark/src/cmark.c
+++ b/compiler/modules/CommonMark/src/cmark.c
@@ -6,14 +6,24 @@
 #include "cmark.h"
 #include "buffer.h"
 
-char *cmark_markdown_to_html(const char *text, int len)
+int cmark_version()
+{
+	return CMARK_VERSION;
+}
+
+const char *cmark_version_string()
+{
+	return CMARK_VERSION_STRING;
+}
+
+char *cmark_markdown_to_html(const char *text, size_t len, int options)
 {
 	cmark_node *doc;
 	char *result;
 
-	doc = cmark_parse_document(text, len);
+	doc = cmark_parse_document(text, len, options);
 
-	result = cmark_render_html(doc, CMARK_OPT_DEFAULT);
+	result = cmark_render_html(doc, options);
 	cmark_node_free(doc);
 
 	return result;

http://git-wip-us.apache.org/repos/asf/lucy-clownfish/blob/89c7b809/compiler/modules/CommonMark/src/cmark.h
----------------------------------------------------------------------
diff --git a/compiler/modules/CommonMark/src/cmark.h b/compiler/modules/CommonMark/src/cmark.h
index 04ca6d7..4a85f26 100644
--- a/compiler/modules/CommonMark/src/cmark.h
+++ b/compiler/modules/CommonMark/src/cmark.h
@@ -2,7 +2,8 @@
 #define CMARK_H
 
 #include <stdio.h>
-#include "cmark_export.h"
+#include <cmark_export.h>
+#include <cmark_version.h>
 
 #ifdef __cplusplus
 extern "C" {
@@ -18,16 +19,12 @@ extern "C" {
  * ## Simple Interface
  */
 
-/** Current version of library.
- */
-#define CMARK_VERSION "0.1"
-
 /** Convert 'text' (assumed to be a UTF-8 encoded string with length
  * 'len' from CommonMark Markdown to HTML, returning a null-terminated,
  * UTF-8-encoded string.
  */
 CMARK_EXPORT
-char *cmark_markdown_to_html(const char *text, int len);
+char *cmark_markdown_to_html(const char *text, size_t len, int options);
 
 /** ## Node Structure
  */
@@ -213,6 +210,12 @@ CMARK_EXPORT
 cmark_event_type
 cmark_iter_get_event_type(cmark_iter *iter);
 
+/** Returns the root node.
+ */
+CMARK_EXPORT
+cmark_node*
+cmark_iter_get_root(cmark_iter *iter);
+
 /** Resets the iterator so that the current node is 'current' and
  * the event type is 'event_type'.  The new current node must be a
  * descendant of the root node or the root node itself.
@@ -226,6 +229,17 @@ cmark_iter_reset(cmark_iter *iter, cmark_node *current,
  * ## Accessors
  */
 
+/** Returns the user data of 'node'.
+ */
+CMARK_EXPORT void*
+cmark_node_get_user_data(cmark_node *node);
+
+/** Sets arbitrary user data for 'node'.  Returns 1 on success,
+ * 0 on failure.
+ */
+CMARK_EXPORT int
+cmark_node_set_user_data(cmark_node *node, void *user_data);
+
 /** Returns the type of 'node', or `CMARK_NODE_NONE` on error.
  */
 CMARK_EXPORT cmark_node_type
@@ -398,11 +412,12 @@ cmark_consolidate_text_nodes(cmark_node *root);
  *
  * Simple interface:
  *
- *     cmark_node *document = cmark_parse_document("Hello *world*", 12);
+ *     cmark_node *document = cmark_parse_document("Hello *world*", 12,
+ *                                                 CMARK_OPT_DEFAULT);
  *
  * Streaming interface:
  *
- *     cmark_parser *parser = cmark_parser_new();
+ *     cmark_parser *parser = cmark_parser_new(CMARK_OPT_DEFAULT);
  *     FILE *fp = fopen("myfile.md", "r");
  *     while ((bytes = fread(buffer, 1, sizeof(buffer), fp)) > 0) {
  *     	   cmark_parser_feed(parser, buffer, bytes);
@@ -417,7 +432,7 @@ cmark_consolidate_text_nodes(cmark_node *root);
 /** Creates a new parser object.
  */
 CMARK_EXPORT
-cmark_parser *cmark_parser_new();
+cmark_parser *cmark_parser_new(int options);
 
 /** Frees memory allocated for a parser object.
  */
@@ -438,13 +453,13 @@ cmark_node *cmark_parser_finish(cmark_parser *parser);
  * Returns a pointer to a tree of nodes.
  */
 CMARK_EXPORT
-cmark_node *cmark_parse_document(const char *buffer, size_t len);
+cmark_node *cmark_parse_document(const char *buffer, size_t len, int options);
 
 /** Parse a CommonMark document in file 'f', returning a pointer to
  * a tree of nodes.
  */
 CMARK_EXPORT
-cmark_node *cmark_parse_file(FILE *f);
+cmark_node *cmark_parse_file(FILE *f, int options);
 
 /**
  * ## Rendering
@@ -453,18 +468,28 @@ cmark_node *cmark_parse_file(FILE *f);
 /** Render a 'node' tree as XML.
  */
 CMARK_EXPORT
-char *cmark_render_xml(cmark_node *root, long options);
+char *cmark_render_xml(cmark_node *root, int options);
 
 /** Render a 'node' tree as an HTML fragment.  It is up to the user
  * to add an appropriate header and footer.
  */
 CMARK_EXPORT
-char *cmark_render_html(cmark_node *root, long options);
+char *cmark_render_html(cmark_node *root, int options);
 
 /** Render a 'node' tree as a groff man page, without the header.
  */
 CMARK_EXPORT
-char *cmark_render_man(cmark_node *root, long options);
+char *cmark_render_man(cmark_node *root, int options, int width);
+
+/** Render a 'node' tree as a commonmark document.
+ */
+CMARK_EXPORT
+char *cmark_render_commonmark(cmark_node *root, int options, int width);
+
+/** Render a 'node' tree as a LaTeX document.
+ */
+CMARK_EXPORT
+char *cmark_render_latex(cmark_node *root, int options, int width);
 
 /** Default writer options.
  */
@@ -482,6 +507,45 @@ char *cmark_render_man(cmark_node *root, long options);
  */
 #define CMARK_OPT_NORMALIZE 4
 
+/** Convert straight quotes to curly, --- to em dashes, -- to en dashes.
+ */
+#define CMARK_OPT_SMART 8
+
+/** Validate UTF-8 in the input before parsing, replacing illegal
+ * sequences with the replacement character U+FFFD.
+ */
+#define CMARK_OPT_VALIDATE_UTF8 16
+
+/** Suppress raw HTML and unsafe links (`javascript:`, `vbscript:`,
+ * `file:`, and `data:`, except for `image/png`, `image/gif`,
+ * `image/jpeg`, or `image/webp` mime types).  Raw HTML is replaced
+ * by a placeholder HTML comment. Unsafe links are replaced by
+ * empty strings.
+ */
+#define CMARK_OPT_SAFE 32
+
+/**
+ * ## Version information
+ */
+
+/** The library version as integer for runtime checks. Also available as
+ * macro CMARK_VERSION for compile time checks.
+ *
+ * * Bits 16-23 contain the major version.
+ * * Bits 8-15 contain the minor version.
+ * * Bits 0-7 contain the patchlevel.
+ *
+ * In hexadecimal format, the number 0x010203 represents version 1.2.3.
+ */
+CMARK_EXPORT
+int cmark_version();
+
+/** The library version string for runtime checks. Also available as
+ * macro CMARK_VERSION_STRING for compile time checks.
+ */
+CMARK_EXPORT
+const char *cmark_version_string();
+
 /** # AUTHORS
  *
  * John MacFarlane, Vicent Marti,  Kārlis Gaņģis, Nick Wellnhofer.
@@ -506,7 +570,6 @@ char *cmark_render_man(cmark_node *root, long options);
 #define NODE_STRONG               CMARK_NODE_STRONG
 #define NODE_LINK                 CMARK_NODE_LINK
 #define NODE_IMAGE                CMARK_NODE_IMAGE
-#define NODE_LINK_LABEL           CMARK_NODE_LINK_LABEL
 #define BULLET_LIST               CMARK_BULLET_LIST
 #define ORDERED_LIST              CMARK_ORDERED_LIST
 #define PERIOD_DELIM              CMARK_PERIOD_DELIM

http://git-wip-us.apache.org/repos/asf/lucy-clownfish/blob/89c7b809/compiler/modules/CommonMark/src/cmark_version.h
----------------------------------------------------------------------
diff --git a/compiler/modules/CommonMark/src/cmark_version.h b/compiler/modules/CommonMark/src/cmark_version.h
new file mode 100644
index 0000000..fb15ba5
--- /dev/null
+++ b/compiler/modules/CommonMark/src/cmark_version.h
@@ -0,0 +1,7 @@
+#ifndef CMARK_VERSION_H
+#define CMARK_VERSION_H
+
+#define CMARK_VERSION ((0 << 16) | (21 << 8)  | 0)
+#define CMARK_VERSION_STRING "0.21.0"
+
+#endif


[07/20] lucy-clownfish git commit: Upgrade libcmark to 0.21.0

Posted by nw...@apache.org.
http://git-wip-us.apache.org/repos/asf/lucy-clownfish/blob/89c7b809/compiler/modules/CommonMark/src/html_unescape.h
----------------------------------------------------------------------
diff --git a/compiler/modules/CommonMark/src/html_unescape.h b/compiler/modules/CommonMark/src/html_unescape.h
deleted file mode 100644
index 1eb318b..0000000
--- a/compiler/modules/CommonMark/src/html_unescape.h
+++ /dev/null
@@ -1,13375 +0,0 @@
-/* ANSI-C code produced by gperf version 3.0.3 */
-/* Command-line: /Library/Developer/CommandLineTools/usr/bin/gperf -L ANSI-C -I -t -N find_entity -H hash_entity -K entity -C -l -F ',{0}' --null-strings -m5 -P -Q entity_pool src/html_unescape.gperf  */
-/* Computed positions: -k'1-7,10,12,$' */
-
-#if !((' ' == 32) && ('!' == 33) && ('"' == 34) && ('#' == 35) \
-      && ('%' == 37) && ('&' == 38) && ('\'' == 39) && ('(' == 40) \
-      && (')' == 41) && ('*' == 42) && ('+' == 43) && (',' == 44) \
-      && ('-' == 45) && ('.' == 46) && ('/' == 47) && ('0' == 48) \
-      && ('1' == 49) && ('2' == 50) && ('3' == 51) && ('4' == 52) \
-      && ('5' == 53) && ('6' == 54) && ('7' == 55) && ('8' == 56) \
-      && ('9' == 57) && (':' == 58) && (';' == 59) && ('<' == 60) \
-      && ('=' == 61) && ('>' == 62) && ('?' == 63) && ('A' == 65) \
-      && ('B' == 66) && ('C' == 67) && ('D' == 68) && ('E' == 69) \
-      && ('F' == 70) && ('G' == 71) && ('H' == 72) && ('I' == 73) \
-      && ('J' == 74) && ('K' == 75) && ('L' == 76) && ('M' == 77) \
-      && ('N' == 78) && ('O' == 79) && ('P' == 80) && ('Q' == 81) \
-      && ('R' == 82) && ('S' == 83) && ('T' == 84) && ('U' == 85) \
-      && ('V' == 86) && ('W' == 87) && ('X' == 88) && ('Y' == 89) \
-      && ('Z' == 90) && ('[' == 91) && ('\\' == 92) && (']' == 93) \
-      && ('^' == 94) && ('_' == 95) && ('a' == 97) && ('b' == 98) \
-      && ('c' == 99) && ('d' == 100) && ('e' == 101) && ('f' == 102) \
-      && ('g' == 103) && ('h' == 104) && ('i' == 105) && ('j' == 106) \
-      && ('k' == 107) && ('l' == 108) && ('m' == 109) && ('n' == 110) \
-      && ('o' == 111) && ('p' == 112) && ('q' == 113) && ('r' == 114) \
-      && ('s' == 115) && ('t' == 116) && ('u' == 117) && ('v' == 118) \
-      && ('w' == 119) && ('x' == 120) && ('y' == 121) && ('z' == 122) \
-      && ('{' == 123) && ('|' == 124) && ('}' == 125) && ('~' == 126))
-/* The character set is not based on ISO-646.  */
-#error "gperf generated tables don't work with this execution character set. Please report a bug to <bu...@gnu.org>."
-#endif
-
-#line 1 "src/html_unescape.gperf"
-struct html_ent {
-	int entity;
-	unsigned char utf8[4];
-};
-#include <string.h>
-#include <stddef.h>
-
-#define TOTAL_KEYWORDS 2125
-#define MIN_WORD_LENGTH 2
-#define MAX_WORD_LENGTH 31
-#define MIN_HASH_VALUE 39
-#define MAX_HASH_VALUE 16000
-/* maximum key range = 15962, duplicates = 0 */
-
-#ifdef __GNUC__
-__inline
-#else
-#ifdef __cplusplus
-inline
-#endif
-#endif
-static unsigned int
-hash_entity (register const char *str, register unsigned int len)
-{
-  static const unsigned short asso_values[] =
-    {
-      16001, 16001, 16001, 16001, 16001, 16001, 16001, 16001, 16001, 16001,
-      16001, 16001, 16001, 16001, 16001, 16001, 16001, 16001, 16001, 16001,
-      16001, 16001, 16001, 16001, 16001, 16001, 16001, 16001, 16001, 16001,
-      16001, 16001, 16001, 16001, 16001, 16001, 16001, 16001, 16001, 16001,
-      16001, 16001, 16001, 16001, 16001, 16001, 16001, 16001, 16001,     2,
-          3,     7,     2,     4,     8, 16001,    10, 16001, 16001, 16001,
-      16001, 16001, 16001, 16001, 16001,  1890,  1538,   220,   165,  1045,
-        535,  1971,  1187,  1262,    35,   126,   201,   133,   350,  1487,
-       1965,     3,   478,   134,     8,   147,    73,    41,    23,   212,
-          9, 16001,     2, 16001,     2, 16001, 16001,  4154,    29,  3168,
-        429,    10,   146,  1925,  2307,   280,  1313,  1924,     4,   651,
-         27,  1031,    65,   176,     2,     6,    17,    15,   107,   482,
-       3207,  3865,   757,   131,   178,     4,     4, 16001, 16001, 16001,
-      16001, 16001, 16001, 16001, 16001, 16001, 16001, 16001, 16001, 16001,
-      16001, 16001, 16001, 16001, 16001, 16001, 16001, 16001, 16001, 16001,
-      16001, 16001, 16001, 16001, 16001, 16001, 16001, 16001, 16001, 16001,
-      16001, 16001, 16001, 16001, 16001, 16001, 16001, 16001, 16001, 16001,
-      16001, 16001, 16001, 16001, 16001, 16001, 16001, 16001, 16001, 16001,
-      16001, 16001, 16001, 16001, 16001, 16001, 16001, 16001, 16001, 16001,
-      16001, 16001, 16001, 16001, 16001, 16001, 16001, 16001, 16001, 16001,
-      16001, 16001, 16001, 16001, 16001, 16001, 16001, 16001, 16001, 16001,
-      16001, 16001, 16001, 16001, 16001, 16001, 16001, 16001, 16001, 16001,
-      16001, 16001, 16001, 16001, 16001, 16001, 16001, 16001, 16001, 16001,
-      16001, 16001, 16001, 16001, 16001, 16001, 16001, 16001, 16001, 16001,
-      16001, 16001, 16001, 16001, 16001, 16001, 16001, 16001, 16001, 16001,
-      16001, 16001, 16001, 16001, 16001, 16001, 16001, 16001, 16001, 16001
-    };
-  register unsigned int hval = len;
-
-  switch (hval)
-    {
-      default:
-        hval += asso_values[(unsigned char)str[11]];
-      /*FALLTHROUGH*/
-      case 11:
-      case 10:
-        hval += asso_values[(unsigned char)str[9]];
-      /*FALLTHROUGH*/
-      case 9:
-      case 8:
-      case 7:
-        hval += asso_values[(unsigned char)str[6]];
-      /*FALLTHROUGH*/
-      case 6:
-        hval += asso_values[(unsigned char)str[5]];
-      /*FALLTHROUGH*/
-      case 5:
-        hval += asso_values[(unsigned char)str[4]+1];
-      /*FALLTHROUGH*/
-      case 4:
-        hval += asso_values[(unsigned char)str[3]+3];
-      /*FALLTHROUGH*/
-      case 3:
-        hval += asso_values[(unsigned char)str[2]+1];
-      /*FALLTHROUGH*/
-      case 2:
-        hval += asso_values[(unsigned char)str[1]+4];
-      /*FALLTHROUGH*/
-      case 1:
-        hval += asso_values[(unsigned char)str[0]];
-        break;
-    }
-  return hval + asso_values[(unsigned char)str[len - 1]];
-}
-
-struct entity_pool_t
-  {
-    char entity_pool_str39[sizeof("rarr")];
-    char entity_pool_str41[sizeof("larr")];
-    char entity_pool_str49[sizeof("lat")];
-    char entity_pool_str52[sizeof("uarr")];
-    char entity_pool_str55[sizeof("npr")];
-    char entity_pool_str62[sizeof("rarrtl")];
-    char entity_pool_str64[sizeof("larrtl")];
-    char entity_pool_str65[sizeof("roarr")];
-    char entity_pool_str67[sizeof("loarr")];
-    char entity_pool_str68[sizeof("not")];
-    char entity_pool_str69[sizeof("rpar")];
-    char entity_pool_str70[sizeof("bot")];
-    char entity_pool_str71[sizeof("lpar")];
-    char entity_pool_str73[sizeof("spar")];
-    char entity_pool_str75[sizeof("ll")];
-    char entity_pool_str76[sizeof("uharr")];
-    char entity_pool_str77[sizeof("epar")];
-    char entity_pool_str81[sizeof("el")];
-    char entity_pool_str83[sizeof("rotimes")];
-    char entity_pool_str85[sizeof("lotimes")];
-    char entity_pool_str86[sizeof("par")];
-    char entity_pool_str88[sizeof("nharr")];
-    char entity_pool_str94[sizeof("npar")];
-    char entity_pool_str97[sizeof("tprime")];
-    char entity_pool_str101[sizeof("els")];
-    char entity_pool_str102[sizeof("eparsl")];
-    char entity_pool_str104[sizeof("ensp")];
-    char entity_pool_str109[sizeof("bprime")];
-    char entity_pool_str110[sizeof("lnap")];
-    char entity_pool_str111[sizeof("blk14")];
-    char entity_pool_str115[sizeof("blk12")];
-    char entity_pool_str117[sizeof("blk34")];
-    char entity_pool_str119[sizeof("nparsl")];
-    char entity_pool_str123[sizeof("nldr")];
-    char entity_pool_str124[sizeof("rlarr")];
-    char entity_pool_str125[sizeof("npart")];
-    char entity_pool_str126[sizeof("llarr")];
-    char entity_pool_str127[sizeof("nlt")];
-    char entity_pool_str128[sizeof("slarr")];
-    char entity_pool_str138[sizeof("nparallel")];
-    char entity_pool_str143[sizeof("Tau")];
-    char entity_pool_str144[sizeof("varr")];
-    char entity_pool_str146[sizeof("squ")];
-    char entity_pool_str149[sizeof("nlarr")];
-    char entity_pool_str152[sizeof("tau")];
-    char entity_pool_str165[sizeof("lne")];
-    char entity_pool_str166[sizeof("rrarr")];
-    char entity_pool_str168[sizeof("lrarr")];
-    char entity_pool_str170[sizeof("srarr")];
-    char entity_pool_str171[sizeof("rharul")];
-    char entity_pool_str173[sizeof("lharul")];
-    char entity_pool_str174[sizeof("erarr")];
-    char entity_pool_str176[sizeof("pr")];
-    char entity_pool_str177[sizeof("rharu")];
-    char entity_pool_str179[sizeof("lharu")];
-    char entity_pool_str184[sizeof("Uarr")];
-    char entity_pool_str188[sizeof("nGt")];
-    char entity_pool_str190[sizeof("bne")];
-    char entity_pool_str191[sizeof("nrarr")];
-    char entity_pool_str194[sizeof("swarr")];
-    char entity_pool_str198[sizeof("rarrap")];
-    char entity_pool_str200[sizeof("upuparrows")];
-    char entity_pool_str202[sizeof("Darr")];
-    char entity_pool_str205[sizeof("rbarr")];
-    char entity_pool_str206[sizeof("Dot")];
-    char entity_pool_str207[sizeof("lbarr")];
-    char entity_pool_str215[sizeof("nwarr")];
-    char entity_pool_str217[sizeof("smt")];
-    char entity_pool_str222[sizeof("emsp14")];
-    char entity_pool_str223[sizeof("rarrpl")];
-    char entity_pool_str225[sizeof("larrpl")];
-    char entity_pool_str230[sizeof("phmmat")];
-    char entity_pool_str232[sizeof("emsp13")];
-    char entity_pool_str234[sizeof("LT")];
-    char entity_pool_str238[sizeof("Larr")];
-    char entity_pool_str239[sizeof("rbrkslu")];
-    char entity_pool_str241[sizeof("lbrkslu")];
-    char entity_pool_str243[sizeof("napos")];
-    char entity_pool_str251[sizeof("nle")];
-    char entity_pool_str253[sizeof("rHar")];
-    char entity_pool_str255[sizeof("lHar")];
-    char entity_pool_str256[sizeof("qprime")];
-    char entity_pool_str258[sizeof("lap")];
-    char entity_pool_str265[sizeof("nbsp")];
-    char entity_pool_str266[sizeof("uHar")];
-    char entity_pool_str267[sizeof("top")];
-    char entity_pool_str269[sizeof("Vbar")];
-    char entity_pool_str272[sizeof("Ll")];
-    char entity_pool_str276[sizeof("prap")];
-    char entity_pool_str278[sizeof("emsp")];
-    char entity_pool_str281[sizeof("nap")];
-    char entity_pool_str294[sizeof("looparrowleft")];
-    char entity_pool_str296[sizeof("le")];
-    char entity_pool_str300[sizeof("sharp")];
-    char entity_pool_str302[sizeof("ee")];
-    char entity_pool_str310[sizeof("les")];
-    char entity_pool_str311[sizeof("in")];
-    char entity_pool_str312[sizeof("prop")];
-    char entity_pool_str314[sizeof("topbot")];
-    char entity_pool_str317[sizeof("int")];
-    char entity_pool_str319[sizeof("ne")];
-    char entity_pool_str329[sizeof("nprcue")];
-    char entity_pool_str331[sizeof("pre")];
-    char entity_pool_str332[sizeof("epsi")];
-    char entity_pool_str337[sizeof("upsi")];
-    char entity_pool_str338[sizeof("there4")];
-    char entity_pool_str342[sizeof("rbrke")];
-    char entity_pool_str343[sizeof("searr")];
-    char entity_pool_str344[sizeof("lbrke")];
-    char entity_pool_str346[sizeof("blacktriangle")];
-    char entity_pool_str349[sizeof("lneq")];
-    char entity_pool_str352[sizeof("lneqq")];
-    char entity_pool_str354[sizeof("plus")];
-    char entity_pool_str355[sizeof("nles")];
-    char entity_pool_str356[sizeof("nedot")];
-    char entity_pool_str357[sizeof("blacktriangleleft")];
-    char entity_pool_str358[sizeof("blacktriangleright")];
-    char entity_pool_str364[sizeof("nearr")];
-    char entity_pool_str367[sizeof("blacktriangledown")];
-    char entity_pool_str373[sizeof("nless")];
-    char entity_pool_str374[sizeof("emacr")];
-    char entity_pool_str378[sizeof("vprop")];
-    char entity_pool_str379[sizeof("umacr")];
-    char entity_pool_str383[sizeof("smeparsl")];
-    char entity_pool_str387[sizeof("Map")];
-    char entity_pool_str390[sizeof("plusdu")];
-    char entity_pool_str391[sizeof("Not")];
-    char entity_pool_str408[sizeof("Verbar")];
-    char entity_pool_str426[sizeof("perp")];
-    char entity_pool_str430[sizeof("fltns")];
-    char entity_pool_str431[sizeof("plusmn")];
-    char entity_pool_str435[sizeof("nleq")];
-    char entity_pool_str438[sizeof("nleqq")];
-    char entity_pool_str440[sizeof("frac34")];
-    char entity_pool_str441[sizeof("frac14")];
-    char entity_pool_str442[sizeof("verbar")];
-    char entity_pool_str443[sizeof("frac12")];
-    char entity_pool_str444[sizeof("frac35")];
-    char entity_pool_str445[sizeof("frac15")];
-    char entity_pool_str446[sizeof("frac45")];
-    char entity_pool_str449[sizeof("frac25")];
-    char entity_pool_str451[sizeof("frac13")];
-    char entity_pool_str453[sizeof("frac16")];
-    char entity_pool_str454[sizeof("prurel")];
-    char entity_pool_str455[sizeof("frac23")];
-    char entity_pool_str456[sizeof("frac38")];
-    char entity_pool_str457[sizeof("frac18")];
-    char entity_pool_str458[sizeof("frac56")];
-    char entity_pool_str462[sizeof("frac58")];
-    char entity_pool_str464[sizeof("frac78")];
-    char entity_pool_str465[sizeof("leq")];
-    char entity_pool_str466[sizeof("darr")];
-    char entity_pool_str469[sizeof("Upsi")];
-    char entity_pool_str470[sizeof("dot")];
-    char entity_pool_str471[sizeof("phone")];
-    char entity_pool_str474[sizeof("Cap")];
-    char entity_pool_str478[sizeof("blacksquare")];
-    char entity_pool_str479[sizeof("rnmid")];
-    char entity_pool_str483[sizeof("leqq")];
-    char entity_pool_str486[sizeof("intcal")];
-    char entity_pool_str490[sizeof("dharr")];
-    char entity_pool_str494[sizeof("rhard")];
-    char entity_pool_str496[sizeof("lhard")];
-    char entity_pool_str505[sizeof("pluse")];
-    char entity_pool_str511[sizeof("Umacr")];
-    char entity_pool_str512[sizeof("Vee")];
-    char entity_pool_str515[sizeof("Rarr")];
-    char entity_pool_str527[sizeof("Cross")];
-    char entity_pool_str529[sizeof("rsqb")];
-    char entity_pool_str531[sizeof("lsqb")];
-    char entity_pool_str538[sizeof("Rarrtl")];
-    char entity_pool_str541[sizeof("esdot")];
-    char entity_pool_str546[sizeof("vee")];
-    char entity_pool_str547[sizeof("nbumpe")];
-    char entity_pool_str553[sizeof("llcorner")];
-    char entity_pool_str554[sizeof("fpartint")];
-    char entity_pool_str558[sizeof("squf")];
-    char entity_pool_str559[sizeof("plankv")];
-    char entity_pool_str562[sizeof("eqvparsl")];
-    char entity_pool_str564[sizeof("ulcorner")];
-    char entity_pool_str566[sizeof("wp")];
-    char entity_pool_str571[sizeof("lozf")];
-    char entity_pool_str575[sizeof("COPY")];
-    char entity_pool_str577[sizeof("ulcorn")];
-    char entity_pool_str582[sizeof("veebar")];
-    char entity_pool_str584[sizeof("part")];
-    char entity_pool_str589[sizeof("square")];
-    char entity_pool_str591[sizeof("nbump")];
-    char entity_pool_str592[sizeof("bernou")];
-    char entity_pool_str593[sizeof("wr")];
-    char entity_pool_str594[sizeof("rBarr")];
-    char entity_pool_str595[sizeof("lrcorner")];
-    char entity_pool_str596[sizeof("lBarr")];
-    char entity_pool_str599[sizeof("bnot")];
-    char entity_pool_str601[sizeof("semi")];
-    char entity_pool_str606[sizeof("urcorner")];
-    char entity_pool_str612[sizeof("NotSubset")];
-    char entity_pool_str614[sizeof("ropf")];
-    char entity_pool_str615[sizeof("Qopf")];
-    char entity_pool_str616[sizeof("lopf")];
-    char entity_pool_str618[sizeof("sopf")];
-    char entity_pool_str619[sizeof("urcorn")];
-    char entity_pool_str620[sizeof("Topf")];
-    char entity_pool_str621[sizeof("Zopf")];
-    char entity_pool_str622[sizeof("eopf")];
-    char entity_pool_str626[sizeof("ropar")];
-    char entity_pool_str627[sizeof("uopf")];
-    char entity_pool_str628[sizeof("lopar")];
-    char entity_pool_str629[sizeof("topf")];
-    char entity_pool_str635[sizeof("Xopf")];
-    char entity_pool_str639[sizeof("nopf")];
-    char entity_pool_str641[sizeof("bopf")];
-    char entity_pool_str642[sizeof("epsiv")];
-    char entity_pool_str643[sizeof("fnof")];
-    char entity_pool_str644[sizeof("imacr")];
-    char entity_pool_str647[sizeof("Jopf")];
-    char entity_pool_str649[sizeof("nhpar")];
-    char entity_pool_str653[sizeof("Wopf")];
-    char entity_pool_str658[sizeof("Sqrt")];
-    char entity_pool_str659[sizeof("nsub")];
-    char entity_pool_str661[sizeof("napid")];
-    char entity_pool_str664[sizeof("NotSuperset")];
-    char entity_pool_str667[sizeof("brvbar")];
-    char entity_pool_str670[sizeof("sol")];
-    char entity_pool_str675[sizeof("easter")];
-    char entity_pool_str677[sizeof("popf")];
-    char entity_pool_str680[sizeof("dHar")];
-    char entity_pool_str685[sizeof("Vopf")];
-    char entity_pool_str690[sizeof("nsupset")];
-    char entity_pool_str691[sizeof("nsup")];
-    char entity_pool_str692[sizeof("vBar")];
-    char entity_pool_str694[sizeof("nsubset")];
-    char entity_pool_str700[sizeof("thkap")];
-    char entity_pool_str704[sizeof("nis")];
-    char entity_pool_str705[sizeof("profsurf")];
-    char entity_pool_str706[sizeof("solb")];
-    char entity_pool_str710[sizeof("lnsim")];
-    char entity_pool_str712[sizeof("solbar")];
-    char entity_pool_str717[sizeof("Square")];
-    char entity_pool_str719[sizeof("vopf")];
-    char entity_pool_str723[sizeof("uharl")];
-    char entity_pool_str725[sizeof("ulcrop")];
-    char entity_pool_str729[sizeof("eqsim")];
-    char entity_pool_str730[sizeof("equiv")];
-    char entity_pool_str733[sizeof("ell")];
-    char entity_pool_str734[sizeof("smashp")];
-    char entity_pool_str735[sizeof("mp")];
-    char entity_pool_str738[sizeof("Kopf")];
-    char entity_pool_str741[sizeof("simrarr")];
-    char entity_pool_str743[sizeof("flat")];
-    char entity_pool_str745[sizeof("Mopf")];
-    char entity_pool_str746[sizeof("Sopf")];
-    char entity_pool_str747[sizeof("mldr")];
-    char entity_pool_str748[sizeof("rlm")];
-    char entity_pool_str749[sizeof("iprod")];
-    char entity_pool_str756[sizeof("lparlt")];
-    char entity_pool_str758[sizeof("fopf")];
-    char entity_pool_str759[sizeof("Uopf")];
-    char entity_pool_str763[sizeof("varsubsetneq")];
-    char entity_pool_str764[sizeof("varsubsetneqq")];
-    char entity_pool_str767[sizeof("urcrop")];
-    char entity_pool_str768[sizeof("LessLess")];
-    char entity_pool_str770[sizeof("Re")];
-    char entity_pool_str773[sizeof("NotNestedLessLess")];
-    char entity_pool_str777[sizeof("Dopf")];
-    char entity_pool_str779[sizeof("forkv")];
-    char entity_pool_str781[sizeof("nsqsube")];
-    char entity_pool_str783[sizeof("nsupe")];
-    char entity_pool_str787[sizeof("nsube")];
-    char entity_pool_str788[sizeof("qopf")];
-    char entity_pool_str789[sizeof("rlhar")];
-    char entity_pool_str792[sizeof("lrm")];
-    char entity_pool_str796[sizeof("nlsim")];
-    char entity_pool_str798[sizeof("pound")];
-    char entity_pool_str799[sizeof("varsupsetneq")];
-    char entity_pool_str800[sizeof("varsupsetneqq")];
-    char entity_pool_str802[sizeof("bnequiv")];
-    char entity_pool_str813[sizeof("Lopf")];
-    char entity_pool_str817[sizeof("nsqsupe")];
-    char entity_pool_str820[sizeof("rarrlp")];
-    char entity_pool_str821[sizeof("wedbar")];
-    char entity_pool_str822[sizeof("larrlp")];
-    char entity_pool_str824[sizeof("Yopf")];
-    char entity_pool_str829[sizeof("NotReverseElement")];
-    char entity_pool_str832[sizeof("Copf")];
-    char entity_pool_str833[sizeof("lrhar")];
-    char entity_pool_str848[sizeof("parsl")];
-    char entity_pool_str849[sizeof("uml")];
-    char entity_pool_str850[sizeof("marker")];
-    char entity_pool_str851[sizeof("nsupseteq")];
-    char entity_pool_str855[sizeof("nsubseteq")];
-    char entity_pool_str861[sizeof("squarf")];
-    char entity_pool_str862[sizeof("Vert")];
-    char entity_pool_str874[sizeof("SquareSupersetEqual")];
-    char entity_pool_str876[sizeof("prsim")];
-    char entity_pool_str879[sizeof("SquareSubsetEqual")];
-    char entity_pool_str882[sizeof("SquareSuperset")];
-    char entity_pool_str887[sizeof("SquareSubset")];
-    char entity_pool_str888[sizeof("nvap")];
-    char entity_pool_str892[sizeof("iopf")];
-    char entity_pool_str894[sizeof("pm")];
-    char entity_pool_str896[sizeof("vert")];
-    char entity_pool_str898[sizeof("thetav")];
-    char entity_pool_str901[sizeof("loz")];
-    char entity_pool_str905[sizeof("map")];
-    char entity_pool_str920[sizeof("lesseqqgtr")];
-    char entity_pool_str934[sizeof("rscr")];
-    char entity_pool_str935[sizeof("Qscr")];
-    char entity_pool_str936[sizeof("lscr")];
-    char entity_pool_str938[sizeof("sscr")];
-    char entity_pool_str940[sizeof("Tscr")];
-    char entity_pool_str941[sizeof("Zscr")];
-    char entity_pool_str942[sizeof("escr")];
-    char entity_pool_str947[sizeof("uscr")];
-    char entity_pool_str949[sizeof("tscr")];
-    char entity_pool_str951[sizeof("imof")];
-    char entity_pool_str952[sizeof("Coproduct")];
-    char entity_pool_str955[sizeof("Xscr")];
-    char entity_pool_str956[sizeof("Xi")];
-    char entity_pool_str959[sizeof("nscr")];
-    char entity_pool_str960[sizeof("ni")];
-    char entity_pool_str961[sizeof("bscr")];
-    char entity_pool_str962[sizeof("Nopf")];
-    char entity_pool_str967[sizeof("Jscr")];
-    char entity_pool_str968[sizeof("preceq")];
-    char entity_pool_str971[sizeof("nvrArr")];
-    char entity_pool_str972[sizeof("backprime")];
-    char entity_pool_str973[sizeof("Wscr")];
-    char entity_pool_str975[sizeof("varphi")];
-    char entity_pool_str984[sizeof("nsmid")];
-    char entity_pool_str991[sizeof("dlcorn")];
-    char entity_pool_str997[sizeof("pscr")];
-    char entity_pool_str998[sizeof("pi")];
-    char entity_pool_str1005[sizeof("Vscr")];
-    char entity_pool_str1011[sizeof("nesim")];
-    char entity_pool_str1021[sizeof("simne")];
-    char entity_pool_str1028[sizeof("nsupseteqq")];
-    char entity_pool_str1032[sizeof("nsubseteqq")];
-    char entity_pool_str1033[sizeof("drcorn")];
-    char entity_pool_str1038[sizeof("rbrace")];
-    char entity_pool_str1039[sizeof("vscr")];
-    char entity_pool_str1040[sizeof("lbrace")];
-    char entity_pool_str1041[sizeof("dopf")];
-    char entity_pool_str1049[sizeof("frasl")];
-    char entity_pool_str1055[sizeof("LessTilde")];
-    char entity_pool_str1058[sizeof("Kscr")];
-    char entity_pool_str1064[sizeof("pluscir")];
-    char entity_pool_str1065[sizeof("Mscr")];
-    char entity_pool_str1066[sizeof("Sscr")];
-    char entity_pool_str1067[sizeof("rbrksld")];
-    char entity_pool_str1069[sizeof("lbrksld")];
-    char entity_pool_str1070[sizeof("RBarr")];
-    char entity_pool_str1073[sizeof("sqcaps")];
-    char entity_pool_str1074[sizeof("rArr")];
-    char entity_pool_str1075[sizeof("bNot")];
-    char entity_pool_str1076[sizeof("lArr")];
-    char entity_pool_str1078[sizeof("fscr")];
-    char entity_pool_str1079[sizeof("Uscr")];
-    char entity_pool_str1087[sizeof("uArr")];
-    char entity_pool_str1090[sizeof("Ropf")];
-    char entity_pool_str1094[sizeof("wopf")];
-    char entity_pool_str1097[sizeof("Dscr")];
-    char entity_pool_str1098[sizeof("opar")];
-    char entity_pool_str1099[sizeof("seswar")];
-    char entity_pool_str1103[sizeof("Del")];
-    char entity_pool_str1104[sizeof("rAarr")];
-    char entity_pool_str1105[sizeof("rho")];
-    char entity_pool_str1106[sizeof("lAarr")];
-    char entity_pool_str1107[sizeof("preccurlyeq")];
-    char entity_pool_str1108[sizeof("qscr")];
-    char entity_pool_str1111[sizeof("macr")];
-    char entity_pool_str1115[sizeof("notin")];
-    char entity_pool_str1120[sizeof("equivDD")];
-    char entity_pool_str1125[sizeof("sqcap")];
-    char entity_pool_str1127[sizeof("nspar")];
-    char entity_pool_str1131[sizeof("olt")];
-    char entity_pool_str1132[sizeof("ratio")];
-    char entity_pool_str1133[sizeof("Lscr")];
-    char entity_pool_str1137[sizeof("dharl")];
-    char entity_pool_str1139[sizeof("dlcrop")];
-    char entity_pool_str1140[sizeof("DoubleDot")];
-    char entity_pool_str1141[sizeof("dotplus")];
-    char entity_pool_str1142[sizeof("or")];
-    char entity_pool_str1144[sizeof("Yscr")];
-    char entity_pool_str1147[sizeof("Fopf")];
-    char entity_pool_str1152[sizeof("Cscr")];
-    char entity_pool_str1153[sizeof("olarr")];
-    char entity_pool_str1154[sizeof("nrarrw")];
-    char entity_pool_str1159[sizeof("lvertneqq")];
-    char entity_pool_str1160[sizeof("eqslantgtr")];
-    char entity_pool_str1164[sizeof("thorn")];
-    char entity_pool_str1169[sizeof("eqslantless")];
-    char entity_pool_str1172[sizeof("incare")];
-    char entity_pool_str1179[sizeof("vArr")];
-    char entity_pool_str1180[sizeof("rppolint")];
-    char entity_pool_str1181[sizeof("drcrop")];
-    char entity_pool_str1187[sizeof("parallel")];
-    char entity_pool_str1195[sizeof("orarr")];
-    char entity_pool_str1196[sizeof("ssmile")];
-    char entity_pool_str1200[sizeof("DoubleLeftTee")];
-    char entity_pool_str1201[sizeof("erDot")];
-    char entity_pool_str1202[sizeof("diams")];
-    char entity_pool_str1203[sizeof("ssetmn")];
-    char entity_pool_str1208[sizeof("oS")];
-    char entity_pool_str1212[sizeof("iscr")];
-    char entity_pool_str1213[sizeof("ii")];
-    char entity_pool_str1214[sizeof("rect")];
-    char entity_pool_str1217[sizeof("nsccue")];
-    char entity_pool_str1218[sizeof("sect")];
-    char entity_pool_str1220[sizeof("mlcp")];
-    char entity_pool_str1224[sizeof("oror")];
-    char entity_pool_str1226[sizeof("DoubleContourIntegral")];
-    char entity_pool_str1230[sizeof("equals")];
-    char entity_pool_str1232[sizeof("Hat")];
-    char entity_pool_str1236[sizeof("sstarf")];
-    char entity_pool_str1237[sizeof("mstpos")];
-    char entity_pool_str1239[sizeof("die")];
-    char entity_pool_str1240[sizeof("measuredangle")];
-    char entity_pool_str1252[sizeof("forall")];
-    char entity_pool_str1255[sizeof("notinvb")];
-    char entity_pool_str1263[sizeof("mopf")];
-    char entity_pool_str1270[sizeof("niv")];
-    char entity_pool_str1280[sizeof("vBarv")];
-    char entity_pool_str1282[sizeof("Nscr")];
-    char entity_pool_str1284[sizeof("period")];
-    char entity_pool_str1292[sizeof("becaus")];
-    char entity_pool_str1298[sizeof("between")];
-    char entity_pool_str1299[sizeof("Int")];
-    char entity_pool_str1307[sizeof("because")];
-    char entity_pool_str1308[sizeof("piv")];
-    char entity_pool_str1326[sizeof("rfr")];
-    char entity_pool_str1327[sizeof("Qfr")];
-    char entity_pool_str1328[sizeof("lfr")];
-    char entity_pool_str1330[sizeof("sfr")];
-    char entity_pool_str1331[sizeof("nleftrightarrow")];
-    char entity_pool_str1332[sizeof("Tfr")];
-    char entity_pool_str1333[sizeof("Zfr")];
-    char entity_pool_str1334[sizeof("efr")];
-    char entity_pool_str1338[sizeof("sim")];
-    char entity_pool_str1339[sizeof("ufr")];
-    char entity_pool_str1340[sizeof("roplus")];
-    char entity_pool_str1341[sizeof("tfr")];
-    char entity_pool_str1342[sizeof("loplus")];
-    char entity_pool_str1347[sizeof("Xfr")];
-    char entity_pool_str1350[sizeof("real")];
-    char entity_pool_str1351[sizeof("nfr")];
-    char entity_pool_str1353[sizeof("bfr")];
-    char entity_pool_str1355[sizeof("NotHumpEqual")];
-    char entity_pool_str1359[sizeof("Jfr")];
-    char entity_pool_str1361[sizeof("dscr")];
-    char entity_pool_str1365[sizeof("Wfr")];
-    char entity_pool_str1367[sizeof("blacklozenge")];
-    char entity_pool_str1369[sizeof("zopf")];
-    char entity_pool_str1370[sizeof("reals")];
-    char entity_pool_str1372[sizeof("NotCupCap")];
-    char entity_pool_str1375[sizeof("simplus")];
-    char entity_pool_str1377[sizeof("ForAll")];
-    char entity_pool_str1389[sizeof("pfr")];
-    char entity_pool_str1395[sizeof("omacr")];
-    char entity_pool_str1397[sizeof("Vfr")];
-    char entity_pool_str1409[sizeof("Emacr")];
-    char entity_pool_str1410[sizeof("Rscr")];
-    char entity_pool_str1414[sizeof("wscr")];
-    char entity_pool_str1423[sizeof("ShortUpArrow")];
-    char entity_pool_str1429[sizeof("setmn")];
-    char entity_pool_str1431[sizeof("vfr")];
-    char entity_pool_str1450[sizeof("Kfr")];
-    char entity_pool_str1455[sizeof("operp")];
-    char entity_pool_str1457[sizeof("Mfr")];
-    char entity_pool_str1458[sizeof("Sfr")];
-    char entity_pool_str1461[sizeof("nltrie")];
-    char entity_pool_str1467[sizeof("Fscr")];
-    char entity_pool_str1470[sizeof("ffr")];
-    char entity_pool_str1471[sizeof("Ufr")];
-    char entity_pool_str1473[sizeof("shortmid")];
-    char entity_pool_str1488[sizeof("nvsim")];
-    char entity_pool_str1489[sizeof("Dfr")];
-    char entity_pool_str1490[sizeof("lessdot")];
-    char entity_pool_str1493[sizeof("profline")];
-    char entity_pool_str1500[sizeof("qfr")];
-    char entity_pool_str1501[sizeof("dArr")];
-    char entity_pool_str1503[sizeof("nrtrie")];
-    char entity_pool_str1507[sizeof("ShortRightArrow")];
-    char entity_pool_str1515[sizeof("Therefore")];
-    char entity_pool_str1519[sizeof("DD")];
-    char entity_pool_str1524[sizeof("therefore")];
-    char entity_pool_str1525[sizeof("Lfr")];
-    char entity_pool_str1532[sizeof("target")];
-    char entity_pool_str1535[sizeof("Element")];
-    char entity_pool_str1536[sizeof("Yfr")];
-    char entity_pool_str1537[sizeof("ClockwiseContourIntegral")];
-    char entity_pool_str1542[sizeof("olcir")];
-    char entity_pool_str1544[sizeof("Cfr")];
-    char entity_pool_str1559[sizeof("female")];
-    char entity_pool_str1560[sizeof("nsucceq")];
-    char entity_pool_str1561[sizeof("oast")];
-    char entity_pool_str1568[sizeof("percnt")];
-    char entity_pool_str1578[sizeof("ordf")];
-    char entity_pool_str1580[sizeof("ord")];
-    char entity_pool_str1581[sizeof("Rho")];
-    char entity_pool_str1583[sizeof("mscr")];
-    char entity_pool_str1585[sizeof("nvrtrie")];
-    char entity_pool_str1589[sizeof("lnE")];
-    char entity_pool_str1597[sizeof("nhArr")];
-    char entity_pool_str1598[sizeof("Or")];
-    char entity_pool_str1602[sizeof("divide")];
-    char entity_pool_str1604[sizeof("ifr")];
-    char entity_pool_str1605[sizeof("elinters")];
-    char entity_pool_str1615[sizeof("bsol")];
-    char entity_pool_str1616[sizeof("nvlArr")];
-    char entity_pool_str1626[sizeof("Imacr")];
-    char entity_pool_str1628[sizeof("backsimeq")];
-    char entity_pool_str1629[sizeof("twixt")];
-    char entity_pool_str1630[sizeof("olcross")];
-    char entity_pool_str1639[sizeof("rarrsim")];
-    char entity_pool_str1640[sizeof("DoubleDownArrow")];
-    char entity_pool_str1641[sizeof("larrsim")];
-    char entity_pool_str1642[sizeof("emptyset")];
-    char entity_pool_str1643[sizeof("oopf")];
-    char entity_pool_str1645[sizeof("exist")];
-    char entity_pool_str1648[sizeof("llhard")];
-    char entity_pool_str1656[sizeof("excl")];
-    char entity_pool_str1657[sizeof("Eopf")];
-    char entity_pool_str1658[sizeof("nlArr")];
-    char entity_pool_str1663[sizeof("thinsp")];
-    char entity_pool_str1664[sizeof("NotSubsetEqual")];
-    char entity_pool_str1665[sizeof("phi")];
-    char entity_pool_str1666[sizeof("DoubleLeftArrow")];
-    char entity_pool_str1668[sizeof("topcir")];
-    char entity_pool_str1672[sizeof("div")];
-    char entity_pool_str1674[sizeof("Nfr")];
-    char entity_pool_str1675[sizeof("nlE")];
-    char entity_pool_str1689[sizeof("zscr")];
-    char entity_pool_str1690[sizeof("lrhard")];
-    char entity_pool_str1697[sizeof("lltri")];
-    char entity_pool_str1700[sizeof("nrArr")];
-    char entity_pool_str1701[sizeof("NotSupersetEqual")];
-    char entity_pool_str1703[sizeof("swArr")];
-    char entity_pool_str1704[sizeof("ThickSpace")];
-    char entity_pool_str1708[sizeof("ultri")];
-    char entity_pool_str1709[sizeof("notnivb")];
-    char entity_pool_str1711[sizeof("prime")];
-    char entity_pool_str1714[sizeof("primes")];
-    char entity_pool_str1716[sizeof("ohm")];
-    char entity_pool_str1719[sizeof("CircleTimes")];
-    char entity_pool_str1720[sizeof("nltri")];
-    char entity_pool_str1723[sizeof("siml")];
-    char entity_pool_str1724[sizeof("nwArr")];
-    char entity_pool_str1727[sizeof("varpi")];
-    char entity_pool_str1730[sizeof("orv")];
-    char entity_pool_str1735[sizeof("setminus")];
-    char entity_pool_str1739[sizeof("lrtri")];
-    char entity_pool_str1743[sizeof("permil")];
-    char entity_pool_str1744[sizeof("mid")];
-    char entity_pool_str1750[sizeof("urtri")];
-    char entity_pool_str1753[sizeof("dfr")];
-    char entity_pool_str1754[sizeof("mho")];
-    char entity_pool_str1755[sizeof("prE")];
-    char entity_pool_str1759[sizeof("vsupne")];
-    char entity_pool_str1762[sizeof("nrtri")];
-    char entity_pool_str1763[sizeof("vsubne")];
-    char entity_pool_str1765[sizeof("eDot")];
-    char entity_pool_str1778[sizeof("lesges")];
-    char entity_pool_str1781[sizeof("backepsilon")];
-    char entity_pool_str1783[sizeof("ratail")];
-    char entity_pool_str1785[sizeof("latail")];
-    char entity_pool_str1788[sizeof("UpEquilibrium")];
-    char entity_pool_str1791[sizeof("epsilon")];
-    char entity_pool_str1796[sizeof("upsilon")];
-    char entity_pool_str1798[sizeof("midast")];
-    char entity_pool_str1799[sizeof("Hopf")];
-    char entity_pool_str1800[sizeof("vltri")];
-    char entity_pool_str1802[sizeof("Rfr")];
-    char entity_pool_str1805[sizeof("Wedge")];
-    char entity_pool_str1806[sizeof("wfr")];
-    char entity_pool_str1812[sizeof("barwed")];
-    char entity_pool_str1815[sizeof("malt")];
-    char entity_pool_str1820[sizeof("Chi")];
-    char entity_pool_str1821[sizeof("emptyv")];
-    char entity_pool_str1822[sizeof("notni")];
-    char entity_pool_str1827[sizeof("LessGreater")];
-    char entity_pool_str1829[sizeof("diam")];
-    char entity_pool_str1842[sizeof("vrtri")];
-    char entity_pool_str1849[sizeof("CircleMinus")];
-    char entity_pool_str1851[sizeof("Omacr")];
-    char entity_pool_str1852[sizeof("seArr")];
-    char entity_pool_str1859[sizeof("Ffr")];
-    char entity_pool_str1865[sizeof("precneqq")];
-    char entity_pool_str1867[sizeof("Diamond")];
-    char entity_pool_str1868[sizeof("ordm")];
-    char entity_pool_str1873[sizeof("neArr")];
-    char entity_pool_str1874[sizeof("Iopf")];
-    char entity_pool_str1875[sizeof("CircleDot")];
-    char entity_pool_str1878[sizeof("prnap")];
-    char entity_pool_str1884[sizeof("dotminus")];
-    char entity_pool_str1903[sizeof("nshortmid")];
-    char entity_pool_str1905[sizeof("bottom")];
-    char entity_pool_str1907[sizeof("pointint")];
-    char entity_pool_str1917[sizeof("SquareUnion")];
-    char entity_pool_str1925[sizeof("jopf")];
-    char entity_pool_str1928[sizeof("Upsilon")];
-    char entity_pool_str1936[sizeof("Colone")];
-    char entity_pool_str1938[sizeof("nvlt")];
-    char entity_pool_str1941[sizeof("NestedLessLess")];
-    char entity_pool_str1942[sizeof("Colon")];
-    char entity_pool_str1945[sizeof("bsolhsub")];
-    char entity_pool_str1949[sizeof("DoubleLeftRightArrow")];
-    char entity_pool_str1950[sizeof("plussim")];
-    char entity_pool_str1959[sizeof("image")];
-    char entity_pool_str1960[sizeof("egs")];
-    char entity_pool_str1963[sizeof("oscr")];
-    char entity_pool_str1964[sizeof("swnwar")];
-    char entity_pool_str1969[sizeof("zeetrf")];
-    char entity_pool_str1973[sizeof("maltese")];
-    char entity_pool_str1975[sizeof("mfr")];
-    char entity_pool_str1976[sizeof("rarrfs")];
-    char entity_pool_str1977[sizeof("Escr")];
-    char entity_pool_str1978[sizeof("larrfs")];
-    char entity_pool_str1985[sizeof("mnplus")];
-    char entity_pool_str1986[sizeof("ngt")];
-    char entity_pool_str1987[sizeof("ngtr")];
-    char entity_pool_str1996[sizeof("gl")];
-    char entity_pool_str2003[sizeof("diamondsuit")];
-    char entity_pool_str2004[sizeof("GT")];
-    char entity_pool_str2014[sizeof("lesssim")];
-    char entity_pool_str2015[sizeof("dsol")];
-    char entity_pool_str2023[sizeof("upharpoonleft")];
-    char entity_pool_str2024[sizeof("SquareIntersection")];
-    char entity_pool_str2025[sizeof("lsime")];
-    char entity_pool_str2027[sizeof("nLt")];
-    char entity_pool_str2029[sizeof("NotLess")];
-    char entity_pool_str2031[sizeof("gnap")];
-    char entity_pool_str2035[sizeof("scap")];
-    char entity_pool_str2038[sizeof("mapstoleft")];
-    char entity_pool_str2039[sizeof("NotLessLess")];
-    char entity_pool_str2043[sizeof("rfloor")];
-    char entity_pool_str2045[sizeof("lfloor")];
-    char entity_pool_str2048[sizeof("nsime")];
-    char entity_pool_str2050[sizeof("bsime")];
-    char entity_pool_str2051[sizeof("NotLessEqual")];
-    char entity_pool_str2052[sizeof("NotLessTilde")];
-    char entity_pool_str2056[sizeof("ncap")];
-    char entity_pool_str2059[sizeof("NotLessGreater")];
-    char entity_pool_str2070[sizeof("precsim")];
-    char entity_pool_str2072[sizeof("looparrowright")];
-    char entity_pool_str2076[sizeof("Pr")];
-    char entity_pool_str2077[sizeof("rcub")];
-    char entity_pool_str2078[sizeof("mapstoup")];
-    char entity_pool_str2079[sizeof("lcub")];
-    char entity_pool_str2081[sizeof("zfr")];
-    char entity_pool_str2084[sizeof("uparrow")];
-    char entity_pool_str2086[sizeof("gne")];
-    char entity_pool_str2090[sizeof("sce")];
-    char entity_pool_str2091[sizeof("Im")];
-    char entity_pool_str2096[sizeof("rcaron")];
-    char entity_pool_str2098[sizeof("lcaron")];
-    char entity_pool_str2099[sizeof("Oopf")];
-    char entity_pool_str2100[sizeof("scaron")];
-    char entity_pool_str2101[sizeof("backsim")];
-    char entity_pool_str2102[sizeof("Tcaron")];
-    char entity_pool_str2103[sizeof("Zcaron")];
-    char entity_pool_str2104[sizeof("ecaron")];
-    char entity_pool_str2106[sizeof("Bernoullis")];
-    char entity_pool_str2110[sizeof("nge")];
-    char entity_pool_str2111[sizeof("tcaron")];
-    char entity_pool_str2113[sizeof("fork")];
-    char entity_pool_str2119[sizeof("Hscr")];
-    char entity_pool_str2121[sizeof("ncaron")];
-    char entity_pool_str2122[sizeof("elsdot")];
-    char entity_pool_str2124[sizeof("tbrk")];
-    char entity_pool_str2128[sizeof("triplus")];
-    char entity_pool_str2131[sizeof("diamond")];
-    char entity_pool_str2134[sizeof("ncup")];
-    char entity_pool_str2136[sizeof("bbrk")];
-    char entity_pool_str2138[sizeof("frown")];
-    char entity_pool_str2139[sizeof("bkarow")];
-    char entity_pool_str2141[sizeof("spades")];
-    char entity_pool_str2143[sizeof("psi")];
-    char entity_pool_str2150[sizeof("Bopf")];
-    char entity_pool_str2156[sizeof("dollar")];
-    char entity_pool_str2164[sizeof("disin")];
-    char entity_pool_str2170[sizeof("spadesuit")];
-    char entity_pool_str2176[sizeof("NotTilde")];
-    char entity_pool_str2177[sizeof("doublebarwedge")];
-    char entity_pool_str2179[sizeof("gap")];
-    char entity_pool_str2186[sizeof("bbrktbrk")];
-    char entity_pool_str2189[sizeof("swarrow")];
-    char entity_pool_str2190[sizeof("bepsi")];
-    char entity_pool_str2194[sizeof("Iscr")];
-    char entity_pool_str2198[sizeof("NotTildeFullEqual")];
-    char entity_pool_str2199[sizeof("eqcolon")];
-    char entity_pool_str2202[sizeof("tint")];
-    char entity_pool_str2205[sizeof("intprod")];
-    char entity_pool_str2207[sizeof("nsupE")];
-    char entity_pool_str2210[sizeof("nwarrow")];
-    char entity_pool_str2211[sizeof("nsubE")];
-    char entity_pool_str2214[sizeof("nges")];
-    char entity_pool_str2216[sizeof("Uparrow")];
-    char entity_pool_str2217[sizeof("ge")];
-    char entity_pool_str2218[sizeof("OpenCurlyDoubleQuote")];
-    char entity_pool_str2223[sizeof("smallsetminus")];
-    char entity_pool_str2228[sizeof("Scaron")];
-    char entity_pool_str2230[sizeof("nvltrie")];
-    char entity_pool_str2231[sizeof("ges")];
-    char entity_pool_str2232[sizeof("blank")];
-    char entity_pool_str2233[sizeof("QUOT")];
-    char entity_pool_str2238[sizeof("block")];
-    char entity_pool_str2239[sizeof("trade")];
-    char entity_pool_str2245[sizeof("jscr")];
-    char entity_pool_str2246[sizeof("wedge")];
-    char entity_pool_str2254[sizeof("Amacr")];
-    char entity_pool_str2256[sizeof("Equal")];
-    char entity_pool_str2259[sizeof("Dcaron")];
-    char entity_pool_str2262[sizeof("DotDot")];
-    char entity_pool_str2270[sizeof("gneq")];
-    char entity_pool_str2271[sizeof("varpropto")];
-    char entity_pool_str2273[sizeof("gneqq")];
-    char entity_pool_str2274[sizeof("Proportional")];
-    char entity_pool_str2279[sizeof("isins")];
-    char entity_pool_str2281[sizeof("eDDot")];
-    char entity_pool_str2282[sizeof("isin")];
-    char entity_pool_str2286[sizeof("TripleDot")];
-    char entity_pool_str2290[sizeof("Fouriertrf")];
-    char entity_pool_str2291[sizeof("Proportion")];
-    char entity_pool_str2294[sizeof("ngeq")];
-    char entity_pool_str2295[sizeof("Lcaron")];
-    char entity_pool_str2297[sizeof("ngeqq")];
-    char entity_pool_str2313[sizeof("lE")];
-    char entity_pool_str2314[sizeof("Ccaron")];
-    char entity_pool_str2320[sizeof("bsemi")];
-    char entity_pool_str2326[sizeof("propto")];
-    char entity_pool_str2331[sizeof("lesdot")];
-    char entity_pool_str2332[sizeof("Conint")];
-    char entity_pool_str2334[sizeof("And")];
-    char entity_pool_str2338[sizeof("searrow")];
-    char entity_pool_str2343[sizeof("orslope")];
-    char entity_pool_str2344[sizeof("harr")];
-    char entity_pool_str2350[sizeof("late")];
-    char entity_pool_str2352[sizeof("CenterDot")];
-    char entity_pool_str2355[sizeof("ofr")];
-    char entity_pool_str2359[sizeof("nearrow")];
-    char entity_pool_str2361[sizeof("qint")];
-    char entity_pool_str2364[sizeof("lates")];
-    char entity_pool_str2365[sizeof("kappav")];
-    char entity_pool_str2368[sizeof("horbar")];
-    char entity_pool_str2369[sizeof("Efr")];
-    char entity_pool_str2370[sizeof("hoarr")];
-    char entity_pool_str2371[sizeof("npre")];
-    char entity_pool_str2377[sizeof("inodot")];
-    char entity_pool_str2379[sizeof("udarr")];
-    char entity_pool_str2386[sizeof("geq")];
-    char entity_pool_str2391[sizeof("nsimeq")];
-    char entity_pool_str2404[sizeof("geqq")];
-    char entity_pool_str2407[sizeof("efDot")];
-    char entity_pool_str2410[sizeof("rpargt")];
-    char entity_pool_str2419[sizeof("Oscr")];
-    char entity_pool_str2422[sizeof("plusdo")];
-    char entity_pool_str2425[sizeof("lagran")];
-    char entity_pool_str2429[sizeof("thicksim")];
-    char entity_pool_str2440[sizeof("precnsim")];
-    char entity_pool_str2444[sizeof("Ncaron")];
-    char entity_pool_str2449[sizeof("napE")];
-    char entity_pool_str2457[sizeof("iiint")];
-    char entity_pool_str2470[sizeof("Bscr")];
-    char entity_pool_str2483[sizeof("mapstodown")];
-    char entity_pool_str2486[sizeof("varrho")];
-    char entity_pool_str2488[sizeof("isinsv")];
-    char entity_pool_str2491[sizeof("nvHarr")];
-    char entity_pool_str2494[sizeof("NotLeftTriangleBar")];
-    char entity_pool_str2496[sizeof("equest")];
-    char entity_pool_str2498[sizeof("NotLeftTriangleEqual")];
-    char entity_pool_str2499[sizeof("NotLeftTriangle")];
-    char entity_pool_str2502[sizeof("Aopf")];
-    char entity_pool_str2503[sizeof("hbar")];
-    char entity_pool_str2507[sizeof("vangrt")];
-    char entity_pool_str2511[sizeof("Hfr")];
-    char entity_pool_str2517[sizeof("range")];
-    char entity_pool_str2518[sizeof("smte")];
-    char entity_pool_str2519[sizeof("lsim")];
-    char entity_pool_str2521[sizeof("npolint")];
-    char entity_pool_str2523[sizeof("dcaron")];
-    char entity_pool_str2525[sizeof("esim")];
-    char entity_pool_str2527[sizeof("Union")];
-    char entity_pool_str2532[sizeof("smtes")];
-    char entity_pool_str2536[sizeof("kopf")];
-    char entity_pool_str2537[sizeof("gopf")];
-    char entity_pool_str2542[sizeof("nsim")];
-    char entity_pool_str2544[sizeof("bsim")];
-    char entity_pool_str2546[sizeof("SmallCircle")];
-    char entity_pool_str2548[sizeof("NotDoubleVerticalBar")];
-    char entity_pool_str2549[sizeof("NotNestedGreaterGreater")];
-    char entity_pool_str2565[sizeof("EqualTilde")];
-    char entity_pool_str2568[sizeof("notindot")];
-    char entity_pool_str2572[sizeof("Rcaron")];
-    char entity_pool_str2577[sizeof("Popf")];
-    char entity_pool_str2583[sizeof("Gopf")];
-    char entity_pool_str2586[sizeof("Ifr")];
-    char entity_pool_str2589[sizeof("wedgeq")];
-    char entity_pool_str2595[sizeof("prod")];
-    char entity_pool_str2617[sizeof("osol")];
-    char entity_pool_str2624[sizeof("DoubleUpArrow")];
-    char entity_pool_str2627[sizeof("Congruent")];
-    char entity_pool_str2631[sizeof("gnsim")];
-    char entity_pool_str2635[sizeof("scsim")];
-    char entity_pool_str2637[sizeof("jfr")];
-    char entity_pool_str2645[sizeof("upsih")];
-    char entity_pool_str2650[sizeof("nLl")];
-    char entity_pool_str2653[sizeof("DoubleUpDownArrow")];
-    char entity_pool_str2655[sizeof("ngsim")];
-    char entity_pool_str2664[sizeof("hearts")];
-    char entity_pool_str2666[sizeof("lesseqgtr")];
-    char entity_pool_str2670[sizeof("nesear")];
-    char entity_pool_str2676[sizeof("Exists")];
-    char entity_pool_str2687[sizeof("smile")];
-    char entity_pool_str2689[sizeof("uwangle")];
-    char entity_pool_str2693[sizeof("heartsuit")];
-    char entity_pool_str2700[sizeof("HorizontalLine")];
-    char entity_pool_str2703[sizeof("GreaterLess")];
-    char entity_pool_str2705[sizeof("rsaquo")];
-    char entity_pool_str2707[sizeof("lsaquo")];
-    char entity_pool_str2709[sizeof("realine")];
-    char entity_pool_str2710[sizeof("Dashv")];
-    char entity_pool_str2714[sizeof("simdot")];
-    char entity_pool_str2715[sizeof("GreaterEqual")];
-    char entity_pool_str2716[sizeof("GreaterTilde")];
-    char entity_pool_str2721[sizeof("GreaterEqualLess")];
-    char entity_pool_str2723[sizeof("GreaterGreater")];
-    char entity_pool_str2737[sizeof("rceil")];
-    char entity_pool_str2739[sizeof("lceil")];
-    char entity_pool_str2743[sizeof("lessgtr")];
-    char entity_pool_str2746[sizeof("oline")];
-    char entity_pool_str2753[sizeof("thksim")];
-    char entity_pool_str2755[sizeof("InvisibleTimes")];
-    char entity_pool_str2762[sizeof("race")];
-    char entity_pool_str2766[sizeof("iquest")];
-    char entity_pool_str2774[sizeof("imagline")];
-    char entity_pool_str2779[sizeof("UpTee")];
-    char entity_pool_str2781[sizeof("midcir")];
-    char entity_pool_str2790[sizeof("ofcir")];
-    char entity_pool_str2793[sizeof("ddarr")];
-    char entity_pool_str2800[sizeof("rangd")];
-    char entity_pool_str2802[sizeof("langd")];
-    char entity_pool_str2808[sizeof("Equilibrium")];
-    char entity_pool_str2809[sizeof("parsim")];
-    char entity_pool_str2810[sizeof("Vdashl")];
-    char entity_pool_str2811[sizeof("Ofr")];
-    char entity_pool_str2816[sizeof("Because")];
-    char entity_pool_str2818[sizeof("rAtail")];
-    char entity_pool_str2820[sizeof("lAtail")];
-    char entity_pool_str2821[sizeof("ominus")];
-    char entity_pool_str2822[sizeof("Ascr")];
-    char entity_pool_str2826[sizeof("Epsilon")];
-    char entity_pool_str2832[sizeof("ShortLeftArrow")];
-    char entity_pool_str2845[sizeof("isinv")];
-    char entity_pool_str2847[sizeof("micro")];
-    char entity_pool_str2851[sizeof("zcaron")];
-    char entity_pool_str2856[sizeof("kscr")];
-    char entity_pool_str2857[sizeof("gscr")];
-    char entity_pool_str2862[sizeof("Bfr")];
-    char entity_pool_str2863[sizeof("gel")];
-    char entity_pool_str2864[sizeof("hercon")];
-    char entity_pool_str2871[sizeof("triminus")];
-    char entity_pool_str2877[sizeof("egrave")];
-    char entity_pool_str2881[sizeof("sdot")];
-    char entity_pool_str2882[sizeof("ugrave")];
-    char entity_pool_str2884[sizeof("Zdot")];
-    char entity_pool_str2885[sizeof("edot")];
-    char entity_pool_str2890[sizeof("NotTildeTilde")];
-    char entity_pool_str2892[sizeof("tdot")];
-    char entity_pool_str2897[sizeof("Pscr")];
-    char entity_pool_str2898[sizeof("Pi")];
-    char entity_pool_str2903[sizeof("Gscr")];
-    char entity_pool_str2910[sizeof("plustwo")];
-    char entity_pool_str2914[sizeof("NotElement")];
-    char entity_pool_str2916[sizeof("PlusMinus")];
-    char entity_pool_str2919[sizeof("hopf")];
-    char entity_pool_str2920[sizeof("gammad")];
-    char entity_pool_str2922[sizeof("mDDot")];
-    char entity_pool_str2926[sizeof("divideontimes")];
-    char entity_pool_str2940[sizeof("doteq")];
-    char entity_pool_str2956[sizeof("varepsilon")];
-    char entity_pool_str2963[sizeof("Precedes")];
-    char entity_pool_str2966[sizeof("Gammad")];
-    char entity_pool_str2974[sizeof("dashv")];
-    char entity_pool_str2979[sizeof("NotCongruent")];
-    char entity_pool_str2982[sizeof("ubreve")];
-    char entity_pool_str2990[sizeof("ogt")];
-    char entity_pool_str2994[sizeof("RoundImplies")];
-    char entity_pool_str3002[sizeof("PrecedesSlantEqual")];
-    char entity_pool_str3005[sizeof("sime")];
-    char entity_pool_str3014[sizeof("Ugrave")];
-    char entity_pool_str3016[sizeof("dbkarow")];
-    char entity_pool_str3021[sizeof("sdote")];
-    char entity_pool_str3023[sizeof("veeeq")];
-    char entity_pool_str3027[sizeof("mapsto")];
-    char entity_pool_str3030[sizeof("times")];
-    char entity_pool_str3033[sizeof("rangle")];
-    char entity_pool_str3035[sizeof("langle")];
-    char entity_pool_str3038[sizeof("leftarrowtail")];
-    char entity_pool_str3039[sizeof("hamilt")];
-    char entity_pool_str3044[sizeof("udhar")];
-    char entity_pool_str3053[sizeof("nisd")];
-    char entity_pool_str3055[sizeof("rfisht")];
-    char entity_pool_str3057[sizeof("lfisht")];
-    char entity_pool_str3058[sizeof("harrcir")];
-    char entity_pool_str3066[sizeof("OpenCurlyQuote")];
-    char entity_pool_str3068[sizeof("ufisht")];
-    char entity_pool_str3069[sizeof("NotHumpDownHump")];
-    char entity_pool_str3072[sizeof("LeftTee")];
-    char entity_pool_str3074[sizeof("rsh")];
-    char entity_pool_str3076[sizeof("lsh")];
-    char entity_pool_str3080[sizeof("gvertneqq")];
-    char entity_pool_str3083[sizeof("timesb")];
-    char entity_pool_str3092[sizeof("scpolint")];
-    char entity_pool_str3095[sizeof("Cdot")];
-    char entity_pool_str3103[sizeof("dwangle")];
-    char entity_pool_str3114[sizeof("Ubreve")];
-    char entity_pool_str3132[sizeof("LeftUpVector")];
-    char entity_pool_str3135[sizeof("LeftUpVectorBar")];
-    char entity_pool_str3139[sizeof("Ecaron")];
-    char entity_pool_str3142[sizeof("homtht")];
-    char entity_pool_str3147[sizeof("igrave")];
-    char entity_pool_str3155[sizeof("npreceq")];
-    char entity_pool_str3156[sizeof("ecolon")];
-    char entity_pool_str3167[sizeof("dd")];
-    char entity_pool_str3174[sizeof("simeq")];
-    char entity_pool_str3179[sizeof("notinE")];
-    char entity_pool_str3198[sizeof("bigoplus")];
-    char entity_pool_str3214[sizeof("Afr")];
-    char entity_pool_str3215[sizeof("leftarrow")];
-    char entity_pool_str3216[sizeof("oint")];
-    char entity_pool_str3218[sizeof("Tab")];
-    char entity_pool_str3227[sizeof("ogon")];
-    char entity_pool_str3230[sizeof("lt")];
-    char entity_pool_str3231[sizeof("nLeftrightarrow")];
-    char entity_pool_str3235[sizeof("rarrb")];
-    char entity_pool_str3237[sizeof("larrb")];
-    char entity_pool_str3239[sizeof("hscr")];
-    char entity_pool_str3246[sizeof("LeftUpDownVector")];
-    char entity_pool_str3248[sizeof("kfr")];
-    char entity_pool_str3249[sizeof("gfr")];
-    char entity_pool_str3250[sizeof("UpArrowBar")];
-    char entity_pool_str3259[sizeof("nsce")];
-    char entity_pool_str3260[sizeof("ltdot")];
-    char entity_pool_str3261[sizeof("gesl")];
-    char entity_pool_str3262[sizeof("xodot")];
-    char entity_pool_str3263[sizeof("star")];
-    char entity_pool_str3266[sizeof("lowbar")];
-    char entity_pool_str3268[sizeof("xharr")];
-    char entity_pool_str3269[sizeof("ecir")];
-    char entity_pool_str3271[sizeof("utdot")];
-    char entity_pool_str3272[sizeof("natur")];
-    char entity_pool_str3273[sizeof("Lsh")];
-    char entity_pool_str3274[sizeof("infin")];
-    char entity_pool_str3276[sizeof("comp")];
-    char entity_pool_str3278[sizeof("sigmav")];
-    char entity_pool_str3285[sizeof("xotime")];
-    char entity_pool_str3289[sizeof("Pfr")];
-    char entity_pool_str3295[sizeof("Gfr")];
-    char entity_pool_str3298[sizeof("bigcap")];
-    char entity_pool_str3300[sizeof("simlE")];
-    char entity_pool_str3319[sizeof("iiiint")];
-    char entity_pool_str3320[sizeof("barwedge")];
-    char entity_pool_str3321[sizeof("Barwed")];
-    char entity_pool_str3329[sizeof("xlarr")];
-    char entity_pool_str3330[sizeof("LessEqualGreater")];
-    char entity_pool_str3332[sizeof("crarr")];
-    char entity_pool_str3333[sizeof("isindot")];
-    char entity_pool_str3335[sizeof("commat")];
-    char entity_pool_str3342[sizeof("middot")];
-    char entity_pool_str3349[sizeof("lesdotor")];
-    char entity_pool_str3356[sizeof("sigmaf")];
-    char entity_pool_str3366[sizeof("rarrbfs")];
-    char entity_pool_str3368[sizeof("larrbfs")];
-    char entity_pool_str3371[sizeof("xrarr")];
-    char entity_pool_str3376[sizeof("bigcup")];
-    char entity_pool_str3378[sizeof("clubs")];
-    char entity_pool_str3379[sizeof("hArr")];
-    char entity_pool_str3380[sizeof("rtrie")];
-    char entity_pool_str3382[sizeof("ltrie")];
-    char entity_pool_str3383[sizeof("imped")];
-    char entity_pool_str3388[sizeof("eogon")];
-    char entity_pool_str3389[sizeof("rx")];
-    char entity_pool_str3390[sizeof("ltrPar")];
-    char entity_pool_str3391[sizeof("Star")];
-    char entity_pool_str3393[sizeof("uogon")];
-    char entity_pool_str3396[sizeof("Tilde")];
-    char entity_pool_str3398[sizeof("half")];
-    char entity_pool_str3405[sizeof("tilde")];
-    char entity_pool_str3412[sizeof("Leftarrow")];
-    char entity_pool_str3417[sizeof("gesles")];
-    char entity_pool_str3422[sizeof("cap")];
-    char entity_pool_str3423[sizeof("strns")];
-    char entity_pool_str3427[sizeof("Lt")];
-    char entity_pool_str3439[sizeof("prnE")];
-    char entity_pool_str3447[sizeof("sqsupe")];
-    char entity_pool_str3462[sizeof("sqsupset")];
-    char entity_pool_str3467[sizeof("tridot")];
-    char entity_pool_str3468[sizeof("order")];
-    char entity_pool_str3471[sizeof("caps")];
-    char entity_pool_str3475[sizeof("cross")];
-    char entity_pool_str3482[sizeof("dfisht")];
-    char entity_pool_str3487[sizeof("xmap")];
-    char entity_pool_str3491[sizeof("sqsup")];
-    char entity_pool_str3503[sizeof("rtri")];
-    char entity_pool_str3505[sizeof("ltri")];
-    char entity_pool_str3506[sizeof("it")];
-    char entity_pool_str3507[sizeof("rmoust")];
-    char entity_pool_str3509[sizeof("lmoust")];
-    char entity_pool_str3510[sizeof("gnE")];
-    char entity_pool_str3511[sizeof("lgE")];
-    char entity_pool_str3514[sizeof("scE")];
-    char entity_pool_str3516[sizeof("utri")];
-    char entity_pool_str3518[sizeof("vellip")];
-    char entity_pool_str3520[sizeof("ETH")];
-    char entity_pool_str3523[sizeof("lmidot")];
-    char entity_pool_str3525[sizeof("Uogon")];
-    char entity_pool_str3526[sizeof("CounterClockwiseContourIntegral")];
-    char entity_pool_str3534[sizeof("ngE")];
-    char entity_pool_str3535[sizeof("nwnear")];
-    char entity_pool_str3543[sizeof("lesg")];
-    char entity_pool_str3546[sizeof("plusb")];
-    char entity_pool_str3550[sizeof("Rsh")];
-    char entity_pool_str3555[sizeof("copysr")];
-    char entity_pool_str3557[sizeof("infintie")];
-    char entity_pool_str3559[sizeof("imath")];
-    char entity_pool_str3560[sizeof("Esim")];
-    char entity_pool_str3565[sizeof("Phi")];
-    char entity_pool_str3573[sizeof("glE")];
-    char entity_pool_str3579[sizeof("vnsup")];
-    char entity_pool_str3582[sizeof("simgE")];
-    char entity_pool_str3586[sizeof("DoubleLongLeftArrow")];
-    char entity_pool_str3591[sizeof("DoubleLongLeftRightArrow")];
-    char entity_pool_str3594[sizeof("nvgt")];
-    char entity_pool_str3607[sizeof("Mellintrf")];
-    char entity_pool_str3611[sizeof("Prime")];
-    char entity_pool_str3615[sizeof("iinfin")];
-    char entity_pool_str3620[sizeof("ReverseElement")];
-    char entity_pool_str3627[sizeof("EmptySmallSquare")];
-    char entity_pool_str3628[sizeof("radic")];
-    char entity_pool_str3631[sizeof("hfr")];
-    char entity_pool_str3632[sizeof("zdot")];
-    char entity_pool_str3633[sizeof("male")];
-    char entity_pool_str3635[sizeof("rarrc")];
-    char entity_pool_str3636[sizeof("prec")];
-    char entity_pool_str3637[sizeof("scnap")];
-    char entity_pool_str3641[sizeof("DifferentialD")];
-    char entity_pool_str3643[sizeof("models")];
-    char entity_pool_str3657[sizeof("ltcir")];
-    char entity_pool_str3658[sizeof("iogon")];
-    char entity_pool_str3665[sizeof("capcap")];
-    char entity_pool_str3667[sizeof("iff")];
-    char entity_pool_str3669[sizeof("ddotseq")];
-    char entity_pool_str3671[sizeof("CirclePlus")];
-    char entity_pool_str3676[sizeof("rthree")];
-    char entity_pool_str3678[sizeof("lthree")];
-    char entity_pool_str3681[sizeof("PrecedesTilde")];
-    char entity_pool_str3685[sizeof("dtdot")];
-    char entity_pool_str3687[sizeof("clubsuit")];
-    char entity_pool_str3689[sizeof("racute")];
-    char entity_pool_str3691[sizeof("lacute")];
-    char entity_pool_str3692[sizeof("trpezium")];
-    char entity_pool_str3693[sizeof("sacute")];
-    char entity_pool_str3696[sizeof("Zacute")];
-    char entity_pool_str3697[sizeof("eacute")];
-    char entity_pool_str3699[sizeof("TildeTilde")];
-    char entity_pool_str3701[sizeof("Uarrocir")];
-    char entity_pool_str3702[sizeof("uacute")];
-    char entity_pool_str3703[sizeof("lowast")];
-    char entity_pool_str3714[sizeof("nacute")];
-    char entity_pool_str3716[sizeof("NotPrecedes")];
-    char entity_pool_str3720[sizeof("Lmidot")];
-    char entity_pool_str3725[sizeof("UpArrow")];
-    char entity_pool_str3727[sizeof("rarrw")];
-    char entity_pool_str3738[sizeof("DownTee")];
-    char entity_pool_str3742[sizeof("FilledSmallSquare")];
-    char entity_pool_str3743[sizeof("capcup")];
-    char entity_pool_str3749[sizeof("GreaterFullEqual")];
-    char entity_pool_str3756[sizeof("nvle")];
-    char entity_pool_str3758[sizeof("trie")];
-    char entity_pool_str3764[sizeof("omicron")];
-    char entity_pool_str3766[sizeof("DoubleRightTee")];
-    char entity_pool_str3767[sizeof("Cconint")];
-    char entity_pool_str3768[sizeof("rsquor")];
-    char entity_pool_str3770[sizeof("lsquor")];
-    char entity_pool_str3772[sizeof("zigrarr")];
-    char entity_pool_str3780[sizeof("copf")];
-    char entity_pool_str3782[sizeof("ContourIntegral")];
-    char entity_pool_str3798[sizeof("hairsp")];
-    char entity_pool_str3799[sizeof("sqsupseteq")];
-    char entity_pool_str3800[sizeof("csub")];
-    char entity_pool_str3801[sizeof("upharpoonright")];
-    char entity_pool_str3805[sizeof("DownBreve")];
-    char entity_pool_str3817[sizeof("ShortDownArrow")];
-    char entity_pool_str3819[sizeof("xopf")];
-    char entity_pool_str3821[sizeof("Sacute")];
-    char entity_pool_str3829[sizeof("vsupnE")];
-    char entity_pool_str3830[sizeof("cir")];
-    char entity_pool_str3831[sizeof("plusacir")];
-    char entity_pool_str3832[sizeof("csup")];
-    char entity_pool_str3833[sizeof("vsubnE")];
-    char entity_pool_str3834[sizeof("Uacute")];
-    char entity_pool_str3836[sizeof("isinE")];
-    char entity_pool_str3845[sizeof("gEl")];
-    char entity_pool_str3851[sizeof("sqcups")];
-    char entity_pool_str3853[sizeof("smid")];
-    char entity_pool_str3855[sizeof("lg")];
-    char entity_pool_str3857[sizeof("DoubleLongRightArrow")];
-    char entity_pool_str3858[sizeof("NotPrecedesSlantEqual")];
-    char entity_pool_str3861[sizeof("eg")];
-    char entity_pool_str3864[sizeof("AMP")];
-    char entity_pool_str3874[sizeof("nmid")];
-    char entity_pool_str3883[sizeof("timesd")];
-    char entity_pool_str3886[sizeof("DownLeftVector")];
-    char entity_pool_str3887[sizeof("zwnj")];
-    char entity_pool_str3888[sizeof("Lacute")];
-    char entity_pool_str3889[sizeof("DownLeftVectorBar")];
-    char entity_pool_str3898[sizeof("ograve")];
-    char entity_pool_str3899[sizeof("Yacute")];
-    char entity_pool_str3903[sizeof("sqcup")];
-    char entity_pool_str3906[sizeof("odot")];
-    char entity_pool_str3907[sizeof("Cacute")];
-    char entity_pool_str3909[sizeof("nu")];
-    char entity_pool_str3910[sizeof("tritime")];
-    char entity_pool_str3912[sizeof("Egrave")];
-    char entity_pool_str3913[sizeof("eplus")];
-    char entity_pool_str3915[sizeof("backcong")];
-    char entity_pool_str3918[sizeof("uplus")];
-    char entity_pool_str3920[sizeof("Edot")];
-    char entity_pool_str3924[sizeof("csupe")];
-    char entity_pool_str3926[sizeof("simg")];
-    char entity_pool_str3927[sizeof("UpperRightArrow")];
-    char entity_pool_str3928[sizeof("csube")];
-    char entity_pool_str3930[sizeof("dtri")];
-    char entity_pool_str3931[sizeof("prnsim")];
-    char entity_pool_str3936[sizeof("boxUr")];
-    char entity_pool_str3937[sizeof("uuarr")];
-    char entity_pool_str3945[sizeof("DownLeftTeeVector")];
-    char entity_pool_str3946[sizeof("gsime")];
-    char entity_pool_str3950[sizeof("bigotimes")];
-    char entity_pool_str3951[sizeof("Dagger")];
-    char entity_pool_str3954[sizeof("Intersection")];
-    char entity_pool_str3967[sizeof("iacute")];
-    char entity_pool_str3969[sizeof("prcue")];
-    char entity_pool_str3981[sizeof("egsdot")];
-    char entity_pool_str3987[sizeof("Implies")];
-    char entity_pool_str3988[sizeof("VDash")];
-    char entity_pool_str3996[sizeof("bump")];
-    char entity_pool_str4015[sizeof("Mu")];
-    char entity_pool_str4022[sizeof("vDash")];
-    char entity_pool_str4028[sizeof("lvnE")];
-    char entity_pool_str4033[sizeof("LeftTeeArrow")];
-    char entity_pool_str4037[sizeof("Nacute")];
-    char entity_pool_str4042[sizeof("UnderBrace")];
-    char entity_pool_str4043[sizeof("Psi")];
-    char entity_pool_str4047[sizeof("rhov")];
-    char entity_pool_str4049[sizeof("lescc")];
-    char entity_pool_str4055[sizeof("sup1")];
-    char entity_pool_str4058[sizeof("sup2")];
-    char entity_pool_str4066[sizeof("sup3")];
-    char entity_pool_str4071[sizeof("bigodot")];
-    char entity_pool_str4078[sizeof("Downarrow")];
-    char entity_pool_str4080[sizeof("xsqcup")];
-    char entity_pool_str4082[sizeof("barvee")];
-    char entity_pool_str4087[sizeof("NegativeMediumSpace")];
-    char entity_pool_str4088[sizeof("bumpe")];
-    char entity_pool_str4100[sizeof("cscr")];
-    char entity_pool_str4109[sizeof("nsc")];
-    char entity_pool_str4115[sizeof("sup")];
-    char entity_pool_str4122[sizeof("cedil")];
-    char entity_pool_str4125[sizeof("boxVr")];
-    char entity_pool_str4127[sizeof("origof")];
-    char entity_pool_str4128[sizeof("zwj")];
-    char entity_pool_str4129[sizeof("Igrave")];
-    char entity_pool_str4137[sizeof("Idot")];
-    char entity_pool_str4139[sizeof("xscr")];
-    char entity_pool_str4140[sizeof("xi")];
-    char entity_pool_str4144[sizeof("nGtv")];
-    char entity_pool_str4153[sizeof("boxHu")];
-    char entity_pool_str4163[sizeof("THORN")];
-    char entity_pool_str4165[sizeof("Racute")];
-    char entity_pool_str4167[sizeof("rarrhk")];
-    char entity_pool_str4169[sizeof("larrhk")];
-    char entity_pool_str4177[sizeof("rtriltri")];
-    char entity_pool_str4189[sizeof("boxV")];
-    char entity_pool_str4215[sizeof("dagger")];
-    char entity_pool_str4220[sizeof("Omicron")];
-    char entity_pool_str4226[sizeof("DoubleVerticalBar")];
-    char entity_pool_str4229[sizeof("nexists")];
-    char entity_pool_str4232[sizeof("Nu")];
-    char entity_pool_str4233[sizeof("nexist")];
-    char entity_pool_str4234[sizeof("gE")];
-    char entity_pool_str4238[sizeof("ap")];
-    char entity_pool_str4243[sizeof("Sup")];
-    char entity_pool_str4244[sizeof("doteqdot")];
-    char entity_pool_str4247[sizeof("eng")];
-    char entity_pool_str4249[sizeof("caron")];
-    char entity_pool_str4251[sizeof("boxHU")];
-    char entity_pool_str4252[sizeof("gesdot")];
-    char entity_pool_str4257[sizeof("ReverseEquilibrium")];
-    char entity_pool_str4262[sizeof("boxUL")];
-    char entity_pool_str4264[sizeof("supmult")];
-    char entity_pool_str4267[sizeof("pitchfork")];
-    char entity_pool_str4272[sizeof("numsp")];
-    char entity_pool_str4285[sizeof("rang")];
-    char entity_pool_str4287[sizeof("lang")];
-    char entity_pool_str4290[sizeof("ocir")];
-    char entity_pool_str4292[sizeof("rationals")];
-    char entity_pool_str4294[sizeof("coprod")];
-    char entity_pool_str4307[sizeof("ltlarr")];
-    char entity_pool_str4308[sizeof("breve")];
-    char entity_pool_str4310[sizeof("nang")];
-    char entity_pool_str4315[sizeof("swarhk")];
-    char entity_pool_str4322[sizeof("raquo")];
-    char entity_pool_str4324[sizeof("laquo")];
-    char entity_pool_str4325[sizeof("supsub")];
-    char entity_pool_str4329[sizeof("Cup")];
-    char entity_pool_str4330[sizeof("ape")];
-    char entity_pool_str4331[sizeof("quest")];
-    char entity_pool_str4336[sizeof("nwarhk")];
-    char entity_pool_str4340[sizeof("supset")];
-    char entity_pool_str4342[sizeof("downarrow")];
-    char entity_pool_str4351[sizeof("duarr")];
-    char entity_pool_str4353[sizeof("apos")];
-    char entity_pool_str4354[sizeof("Ograve")];
-    char entity_pool_str4355[sizeof("shortparallel")];
-    char entity_pool_str4364[sizeof("nsucc")];
-    char entity_pool_str4368[sizeof("LongLeftArrow")];
-    char entity_pool_str4377[sizeof("lesdoto")];
-    char entity_pool_str4384[sizeof("supne")];
-    char entity_pool_str4388[sizeof("nGg")];
-    char entity_pool_str4396[sizeof("raemptyv")];
-    char entity_pool_str4397[sizeof("supsup")];
-    char entity_pool_str4398[sizeof("laemptyv")];
-    char entity_pool_str4401[sizeof("topfork")];
-    char entity_pool_str4423[sizeof("Eogon")];
-    char entity_pool_str4429[sizeof("risingdotseq")];
-    char entity_pool_str4431[sizeof("bumpeq")];
-    char entity_pool_str4435[sizeof("lstrok")];
-    char entity_pool_str4439[sizeof("Tstrok")];
-    char entity_pool_str4440[sizeof("gsim")];
-    char entity_pool_str4443[sizeof("bemptyv")];
-    char entity_pool_str4444[sizeof("zacute")];
-    char entity_pool_str4445[sizeof("gsiml")];
-    char entity_pool_str4448[sizeof("tstrok")];
-    char entity_pool_str4450[sizeof("roang")];
-    char entity_pool_str4451[sizeof("boxVL")];
-    char entity_pool_str4452[sizeof("loang")];
-    char entity_pool_str4456[sizeof("nleqslant")];
-    char entity_pool_str4462[sizeof("sbquo")];
-    char entity_pool_str4464[sizeof("searhk")];
-    char entity_pool_str4465[sizeof("lnapprox")];
-    char entity_pool_str4468[sizeof("Supset")];
-    char entity_pool_str4470[sizeof("boxHd")];
-    char entity_pool_str4471[sizeof("varkappa")];
-    char entity_pool_str4475[sizeof("circeq")];
-    char entity_pool_str4477[sizeof("yopf")];
-    char entity_pool_str4479[sizeof("UnionPlus")];
-    char entity_pool_str4484[sizeof("Lang")];
-    char entity_pool_str4485[sizeof("nearhk")];
-    char entity_pool_str4486[sizeof("shcy")];
-    char entity_pool_str4492[sizeof("cfr")];
-    char entity_pool_str4506[sizeof("Kappa")];
-    char entity_pool_str4507[sizeof("ljcy")];
-    char entity_pool_str4508[sizeof("MediumSpace")];
-    char entity_pool_str4511[sizeof("supseteq")];
-    char entity_pool_str4512[sizeof("supseteqq")];
-    char entity_pool_str4517[sizeof("reg")];
-    char entity_pool_str4518[sizeof("amacr")];
-    char entity_pool_str4519[sizeof("leg")];
-    char entity_pool_str4524[sizeof("weierp")];
-    char entity_pool_str4525[sizeof("TScy")];
-    char entity_pool_str4529[sizeof("supsetneq")];
-    char entity_pool_str4530[sizeof("njcy")];
-    char entity_pool_str4531[sizeof("xfr")];
-    char entity_pool_str4533[sizeof("mu")];
-    char entity_pool_str4539[sizeof("nvinfin")];
-    char entity_pool_str4540[sizeof("boxUR")];
-    char entity_pool_str4545[sizeof("xoplus")];
-    char entity_pool_str4551[sizeof("leftleftarrows")];
-    char entity_pool_str4552[sizeof("sum")];
-    char entity_pool_str4559[sizeof("beth")];
-    char entity_pool_str4563[sizeof("complement")];
-    char entity_pool_str4573[sizeof("num")];
-    char entity_pool_str4574[sizeof("amp")];
-    char entity_pool_str4583[sizeof("boxUl")];
-    char entity_pool_str4590[sizeof("NotGreater")];
-    char entity_pool_str4591[sizeof("boxplus")];
-    char entity_pool_str4592[sizeof("jmath")];
-    char entity_pool_str4594[sizeof("sfrown")];
-    char entity_pool_str4596[sizeof("Dstrok")];
-    char entity_pool_str4598[sizeof("and")];
-    char entity_pool_str4599[sizeof("NotGreaterGreater")];
-    char entity_pool_str4606[sizeof("NotGreaterSlantEqual")];
-    char entity_pool_str4608[sizeof("NotGreaterLess")];
-    char entity_pool_str4609[sizeof("quot")];
-    char entity_pool_str4616[sizeof("NotGreaterFullEqual")];
-    char entity_pool_str4617[sizeof("hyphen")];
-    char entity_pool_str4618[sizeof("planck")];
-    char entity_pool_str4620[sizeof("TildeEqual")];
-    char entity_pool_str4627[sizeof("tosa")];
-    char entity_pool_str4632[sizeof("Lstrok")];
-    char entity_pool_str4635[sizeof("shy")];
-    char entity_pool_str4639[sizeof("xnis")];
-    char entity_pool_str4640[sizeof("Iogon")];
-    char entity_pool_str4643[sizeof("DZcy")];
-    char entity_pool_str4645[sizeof("ohbar")];
-    char entity_pool_str4652[sizeof("cirscir")];
-    char entity_pool_str4654[sizeof("sext")];
-    char entity_pool_str4668[sizeof("para")];
-    char entity_pool_str4671[sizeof("ast")];
-    char entity_pool_str4678[sizeof("questeq")];
-    char entity_pool_str4680[sizeof("Sum")];
-    char entity_pool_str4682[sizeof("DScy")];
-    char entity_pool_str4684[sizeof("ENG")];
-    char entity_pool_str4686[sizeof("ZHcy")];
-    char entity_pool_str4689[sizeof("longleftarrow")];
-    char entity_pool_str4691[sizeof("dash")];
-    char entity_pool_str4699[sizeof("DownTeeArrow")];
-    char entity_pool_str4706[sizeof("supsetneqq")];
-    char entity_pool_str4714[sizeof("profalar")];
-    char entity_pool_str4718[sizeof("oacute")];
-    char entity_pool_str4729[sizeof("boxVR")];
-    char entity_pool_str4732[sizeof("Eacute")];
-    char entity_pool_str4738[sizeof("supplus")];
-    char entity_pool_str4740[sizeof("hookleftarrow")];
-    char entity_pool_str4743[sizeof("CloseCurlyQuote")];
-    char entity_pool_str4746[sizeof("trisb")];
-    char entity_pool_str4747[sizeof("dotsquare")];
-    char entity_pool_str4751[sizeof("rtimes")];
-    char entity_pool_str4753[sizeof("ltimes")];
-    char entity_pool_str4756[sizeof("toea")];
-    char entity_pool_str4757[sizeof("Agrave")];
-    char entity_pool_str4760[sizeof("Assign")];
-    char entity_pool_str4761[sizeof("Rang")];
-    char entity_pool_str4762[sizeof("iocy")];
-    char entity_pool_str4764[sizeof("NotPrecedesEqual")];
-    char entity_pool_str4766[sizeof("aopf")];
-    char entity_pool_str4768[sizeof("chi")];
-    char entity_pool_str4771[sizeof("quaternions")];
-    char entity_pool_str4772[sizeof("boxVl")];
-    char entity_pool_str4773[sizeof("NotGreaterEqual")];
-    char entity_pool_str4777[sizeof("xhArr")];
-    char entity_pool_str4791[sizeof("orderof")];
-    char entity_pool_str4794[sizeof("rsquo")];
-    char entity_pool_str4796[sizeof("lsquo")];
-    char entity_pool_str4797[sizeof("yscr")];
-    char entity_pool_str4800[sizeof("gdot")];
-    char entity_pool_str4802[sizeof("NotSquareSubsetEqual")];
-    char entity_pool_str4803[sizeof("KHcy")];
-    char entity_pool_str4809[sizeof("bsolb")];
-    char entity_pool_str4810[sizeof("NotSquareSubset")];
-    char entity_pool_str4811[sizeof("SHcy")];
-    char entity_pool_str4821[sizeof("YIcy")];
-    char entity_pool_str4825[sizeof("cwint")];
-    char entity_pool_str4828[sizeof("Theta")];
-    char entity_pool_str4837[sizeof("theta")];
-    char entity_pool_str4838[sizeof("xlArr")];
-    char entity_pool_str4840[sizeof("NotSquareSupersetEqual")];
-    char entity_pool_str4843[sizeof("demptyv")];
-    char entity_pool_str4844[sizeof("triangle")];
-    char entity_pool_str4846[sizeof("Gdot")];
-    char entity_pool_str4848[sizeof("NotSquareSuperset")];
-    char entity_pool_str4857[sizeof("Abreve")];
-    char entity_pool_str4860[sizeof("dstrok")];
-    char entity_pool_str4861[sizeof("pertenk")];
-    char entity_pool_str4866[sizeof("rbrack")];
-    char entity_pool_str4868[sizeof("lbrack")];
-    char entity_pool_str4872[sizeof("odsold")];
-    char entity_pool_str4878[sizeof("omid")];
-    char entity_pool_str4880[sizeof("xrArr")];
-    char entity_pool_str4882[sizeof("triangleleft")];
-    char entity_pool_str4883[sizeof("NotGreaterTilde")];
-    char entity_pool_str4884[sizeof("colone")];
-    char entity_pool_str4886[sizeof("Longleftarrow")];
-    char entity_pool_str4888[sizeof("iota")];
-    char entity_pool_str4890[sizeof("colon")];
-    char entity_pool_str4891[sizeof("Zeta")];
-    char entity_pool_str4892[sizeof("gbreve")];
-    char entity_pool_str4897[sizeof("CHcy")];
-    char entity_pool_str4900[sizeof("YUcy")];
-    char entity_pool_str4901[sizeof("REG")];
-    char entity_pool_str4902[sizeof("szlig")];
-    char entity_pool_str4909[sizeof("dzcy")];
-    char entity_pool_str4911[sizeof("beta")];
-    char entity_pool_str4918[sizeof("euro")];
-    char entity_pool_str4921[sizeof("LeftArrow")];
-    char entity_pool_str4924[sizeof("CapitalDifferentialD")];
-    char entity_pool_str4926[sizeof("ring")];
-    char entity_pool_str4927[sizeof("Laplacetrf")];
-    char entity_pool_str4932[sizeof("djcy")];
-    char entity_pool_str4934[sizeof("oplus")];
-    char entity_pool_str4937[sizeof("integers")];
-    char entity_pool_str4938[sizeof("Gbreve")];
-    char entity_pool_str4940[sizeof("ubrcy")];
-    char entity_pool_str4941[sizeof("euml")];
-    char entity_pool_str4944[sizeof("deg")];
-    char entity_pool_str4946[sizeof("uuml")];
-    char entity_pool_str4949[sizeof("Iacute")];
-    char entity_pool_str4950[sizeof("succeq")];
-    char entity_pool_str4952[sizeof("KJcy")];
-    char entity_pool_str4961[sizeof("CupCap")];
-    char entity_pool_str4975[sizeof("tscy")];
-    char entity_pool_str4982[sizeof("cent")];
-    char entity_pool_str4991[sizeof("DJcy")];
-    char entity_pool_str5009[sizeof("TildeFullEqual")];
-    char entity_pool_str5011[sizeof("triangleq")];
-    char entity_pool_str5016[sizeof("duhar")];
-    char entity_pool_str5025[sizeof("LeftDoubleBracket")];
-    char entity_pool_str5027[sizeof("LJcy")];
-    char entity_pool_str5036[sizeof("iecy")];
-    char entity_pool_str5043[sizeof("trianglelefteq")];
-    char entity_pool_str5049[sizeof("nequiv")];
-    char entity_pool_str5055[sizeof("nshortparallel")];
-    char entity_pool_str5062[sizeof("ndash")];
-    char entity_pool_str5063[sizeof("bowtie")];
-    char entity_pool_str5065[sizeof("fjlig")];
-    char entity_pool_str5072[sizeof("Ubrcy")];
-    char entity_pool_str5074[sizeof("vartheta")];
-    char entity_pool_str5078[sizeof("Uuml")];
-    char entity_pool_str5084[sizeof("vartriangleright")];
-    char entity_pool_str5085[sizeof("vartriangleleft")];
-    char entity_pool_str5086[sizeof("ascr")];
-    char entity_pool_str5089[sizeof("succcurlyeq")];
-    char entity_pool_str5093[sizeof("cwconint")];
-    char entity_pool_str5101[sizeof("sc")];
-    char entity_pool_str5103[sizeof("fllig")];
-    char entity_pool_str5105[sizeof("circledast")];
-    char entity_pool_str5108[sizeof("Vdash")];
-    char entity_pool_str5112[sizeof("nVdash")];
-    char entity_pool_str5120[sizeof("suplarr")];
-    char entity_pool_str5124[sizeof("robrk")];
-    char entity_pool_str5126[sizeof("lobrk")];
-    char entity_pool_str5142[sizeof("vdash")];
-    char entity_pool_str5143[sizeof("Yuml")];
-    char entity_pool_str5151[sizeof("gt")];
-    char entity_pool_str5156[sizeof("ccaps")];
-    char entity_pool_str5173[sizeof("Succeeds")];
-    char entity_pool_str5174[sizeof("Oacute")];
-    char entity_pool_str5175[sizeof("TRADE")];
-    char entity_pool_str5176[sizeof("NJcy")];
-    char entity_pool_str5181[sizeof("gtdot")];
-    char entity_pool_str5189[sizeof("yfr")];
-    char entity_pool_str5192[sizeof("compfn")];
-    char entity_pool_str5197[sizeof("Gt")];
-    char entity_pool_str5198[sizeof("scnE")];
-    char entity_pool_str5199[sizeof("ijlig")];
-    char entity_pool_str5203[sizeof("circledS")];
-    char entity_pool_str5206[sizeof("yen")];
-    char entity_pool_str5208[sizeof("thetasym")];
-    char entity_pool_str5211[sizeof("iuml")];
-    char entity_pool_str5212[sizeof("SucceedsSlantEqual")];
-    char entity_pool_str5217[sizeof("boxH")];
-    char entity_pool_str5218[sizeof("mumap")];
-    char entity_pool_str5222[sizeof("rightrightarrows")];
-    char entity_pool_str5227[sizeof("coloneq")];
-    char entity_pool_str5229[sizeof("Sc")];
-    char entity_pool_str5230[sizeof("glj")];
-    char entity_pool_str5231[sizeof("iexcl")];
-    char entity_pool_str5234[sizeof("ccups")];
-    char entity_pool_str5236[sizeof("xcap")];
-    char entity_pool_str5237[sizeof("zhcy")];
-    char entity_pool_str5241[sizeof("boxHD")];
-    char entity_pool_str5250[sizeof("leqslant")];
-    char entity_pool_str5252[sizeof("UpperLeftArrow")];
-    char entity_pool_str5257[sizeof("dblac")];
-    char entity_pool_str5260[sizeof("puncsp")];
-    char entity_pool_str5262[sizeof("ccaron")];
-    char entity_pool_str5264[sizeof("rbbrk")];
-    char entity_pool_str5266[sizeof("lbbrk")];
-    char entity_pool_str5268[sizeof("Aogon")];
-    char entity_pool_str5269[sizeof("LeftTriangleBar")];
-    char entity_pool_str5272[sizeof("gesdotol")];
-    char entity_pool_str5273[sizeof("LeftTriangleEqual")];
-    char entity_pool_str5274[sizeof("LeftTriangle")];
-    char entity_pool_str5280[sizeof("conint")];
-    char entity_pool_str5283[sizeof("drbkarow")];
-    char entity_pool_str5295[sizeof("rtrif")];
-    char entity_pool_str5297[sizeof("ltrif")];
-    char entity_pool_str5300[sizeof("ReverseUpEquilibrium")];
-    char entity_pool_str5306[sizeof("LeftCeiling")];
-    char entity_pool_str5308[sizeof("utrif")];
-    char entity_pool_str5314[sizeof("xcup")];
-    char entity_pool_str5319[sizeof("fallingdotseq")];
-    char entity_pool_str5325[sizeof("rcedil")];
-    char entity_pool_str5327[sizeof("lcedil")];
-    char entity_pool_str5329[sizeof("scedil")];
-    char entity_pool_str5331[sizeof("Tcedil")];
-    char entity_pool_str5333[sizeof("starf")];
-    char entity_pool_str5334[sizeof("boxminus")];
-    char entity_pool_str5340[sizeof("tcedil")];
-    char entity_pool_str5341[sizeof("ZeroWidthSpace")];
-    char entity_pool_str5350[sizeof("ncedil")];
-    char entity_pool_str5358[sizeof("phiv")];
-    char entity_pool_str5375[sizeof("ic")];
-    char entity_pool_str5384[sizeof("capdot")];
-    char entity_pool_str5387[sizeof("dscy")];
-    char entity_pool_str5397[sizeof("check")];
-    char entity_pool_str5398[sizeof("ovbar")];
-    char entity_pool_str5405[sizeof("ntriangleleft")];
-    char entity_pool_str5411[sizeof("RightTee")];
-    char entity_pool_str5412[sizeof("nvge")];
-    char entity_pool_str5424[sizeof("leftrightsquigarrow")];
-    char entity_pool_str5431[sizeof("lozenge")];
-    char entity_pool_str5434[sizeof("RightTriangleBar")];
-    char entity_pool_str5436[sizeof("RightTeeVector")];
-    char entity_pool_str5438[sizeof("RightTriangleEqual")];
-    char entity_pool_str5439[sizeof("RightTriangle")];
-    char entity_pool_str5449[sizeof("Kcedil")];
-    char entity_pool_str5457[sizeof("Scedil")];
-    char entity_pool_str5468[sizeof("cirfnint")];
-    char entity_pool_str5471[sizeof("empty")];
-    char entity_pool_str5478[sizeof("afr")];
-    char entity_pool_str5482[sizeof("DiacriticalTilde")];
-    char entity_pool_str5489[sizeof("LeftDownVector")];
-    char entity_pool_str5492[sizeof("LeftDownVectorBar")];
-    char entity_pool_str5501[sizeof("lEg")];
-    char entity_pool_str5509[sizeof("ApplyFunction")];
-    char entity_pool_str5512[sizeof("bumpE")];
-    char entity_pool_str5524[sizeof("Lcedil")];
-    char entity_pool_str5528[sizeof("caret")];
-    char entity_pool_str5530[sizeof("Barv")];
-    char entity_pool_str5543[sizeof("Ccedil")];
-    char entity_pool_str5547[sizeof("circledR")];
-    char entity_pool_str5548[sizeof("LeftDownTeeVector")];
-    char entity_pool_str5552[sizeof("tshcy")];
-    char entity_pool_str5556[sizeof("DotEqual")];
-    char entity_pool_str5564[sizeof("centerdot")];
-    char entity_pool_str5566[sizeof("ntrianglelefteq")];
-    char entity_pool_str5568[sizeof("minus")];
-    char entity_pool_str5570[sizeof("gimel")];
-    char entity_pool_str5577[sizeof("Aacute")];
-    char entity_pool_str5578[sizeof("gtcir")];
-    char entity_pool_str5583[sizeof("gtrarr")];
-    char entity_pool_str5584[sizeof("bull")];
-    char entity_pool_str5587[sizeof("DownArrow")];
-    char entity_pool_str5593[sizeof("rdquor")];
-    char entity_pool_str5595[sizeof("ldquor")];
-    char entity_pool_str5598[sizeof("intlarhk")];
-    char entity_pool_str5602[sizeof("utilde")];
-    char entity_pool_str5612[sizeof("gacute")];
-    char entity_pool_str5614[sizeof("ntilde")];
-    char entity_pool_str5615[sizeof("af")];
-    char entity_pool_str5618[sizeof("Hstrok")];
-    char entity_pool_str5620[sizeof("exponentiale")];
-    char entity_pool_str5621[sizeof("minusb")];
-    char entity_pool_str5625[sizeof("RightUpTeeVector")];
-    char entity_pool_str5630[sizeof("UpTeeArrow")];
-    char entity_pool_str5639[sizeof("zeta")];
-    char entity_pool_str5644[sizeof("DiacriticalDot")];
-    char entity_pool_str5645[sizeof("DiacriticalDoubleAcute")];
-    char entity_pool_str5663[sizeof("nleftarrow")];
-    char entity_pool_str5664[sizeof("hkswarow")];
-    char entity_pool_str5666[sizeof("iiota")];
-    char entity_pool_str5669[sizeof("apacir")];
-    char entity_pool_str5673[sizeof("Ncedil")];
-    char entity_pool_str5678[sizeof("capand")];
-    char entity_pool_str5686[sizeof("mdash")];
-    char entity_pool_str5689[sizeof("filig")];
-    char entity_pool_str5690[sizeof("scnsim")];
-    char entity_pool_str5699[sizeof("realpart")];
-    char entity_pool_str5703[sizeof("leftthreetimes")];
-    char entity_pool_str5704[sizeof("asymp")];
-    char entity_pool_str5718[sizeof("hellip")];
-    char entity_pool_str5722[sizeof("dtrif")];
-    char entity_pool_str5724[sizeof("NotExists")];
-    char entity_pool_str5728[sizeof("sccue")];
-    char entity_pool_str5733[sizeof("YAcy")];
-    char entity_pool_str5734[sizeof("Utilde")];
-    char entity_pool_str5741[sizeof("NotEqual")];
-    char entity_pool_str5747[sizeof("ThinSpace")];
-    char entity_pool_str5754[sizeof("apE")];
-    char entity_pool_str5762[sizeof("bullet")];
-    char entity_pool_str5765[sizeof("CloseCurlyDoubleQuote")];
-    char entity_pool_str5766[sizeof("Delta")];
-    char entity_pool_str5776[sizeof("gg")];
-    char entity_pool_str5780[sizeof("otimes")];
-    char entity_pool_str5799[sizeof("wreath")];
-    char entity_pool_str5801[sizeof("Rcedil")];
-    char entity_pool_str5807[sizeof("eth")];
-    char entity_pool_str5808[sizeof("supnE")];
-    char entity_pool_str5811[sizeof("awint")];
-    char entity_pool_str5817[sizeof("Breve")];
-    char entity_pool_str5822[sizeof("Gg")];
-    char entity_pool_str5824[sizeof("HumpEqual")];
-    char entity_pool_str5837[sizeof("Lleftarrow")];
-    char entity_pool_str5838[sizeof("boxdr")];
-    char entity_pool_str5847[sizeof("succneqq")];
-    char entity_pool_str5848[sizeof("uring")];
-    char entity_pool_str5849[sizeof("LessSlantEqual")];
-    char entity_pool_str5860[sizeof("nvdash")];
-    char entity_pool_str5866[sizeof("Hacek")];
-    char entity_pool_str5867[sizeof("itilde")];
-    char entity_pool_str5870[sizeof("Iota")];
-    char entity_pool_str5872[sizeof("IOcy")];
-    char entity_pool_str5884[sizeof("boxDr")];
-    char entity_pool_str5891[sizeof("SucceedsTilde")];
-    char entity_pool_str5905[sizeof("LeftFloor")];
-    char entity_pool_str5906[sizeof("Vvdash")];
-    char entity_pool_str5923[sizeof("triangledown")];
-    char entity_pool_str5927[sizeof("LongLeftRightArrow")];
-    char entity_pool_str5928[sizeof("RightFloor")];
-    char entity_pool_str5931[sizeof("DownRightTeeVector")];
-    char entity_pool_str5933[sizeof("quatint")];
-    char entity_pool_str5937[sizeof("Ntilde")];
-    char entity_pool_str5940[sizeof("Bumpeq")];
-    char entity_pool_str5949[sizeof("gvnE")];
-    char entity_pool_str5951[sizeof("boxhu")];
-    char entity_pool_str5956[sizeof("gtlPar")];
-    char entity_pool_str5959[sizeof("nprec")];
-    char entity_pool_str5962[sizeof("ouml")];
-    char entity_pool_str5970[sizeof("gescc")];
-    char entity_pool_str5976[sizeof("Euml")];
-    char entity_pool_str5980[sizeof("Uring")];
-    char entity_pool_str5982[sizeof("UnderBracket")];
-    char entity_pool_str5983[sizeof("nLtv")];
-    char entity_pool_str5984[sizeof("LeftArrowBar")];
-    char entity_pool_str5985[sizeof("ncongdot")];
-    char entity_pool_str6003[sizeof("asympeq")];
-    char entity_pool_str6023[sizeof("minusdu")];
-    char entity_pool_str6030[sizeof("delta")];
-    char entity_pool_str6032[sizeof("harrw")];
-    char entity_pool_str6038[sizeof("andslope")];
-    char entity_pool_str6043[sizeof("cdot")];
-    char entity_pool_str6048[sizeof("Cayleys")];
-    char entity_pool_str6049[sizeof("boxhU")];
-    char entity_pool_str6052[sizeof("succsim")];
-    char entity_pool_str6061[sizeof("cirE")];
-    char entity_pool_str6062[sizeof("sdotb")];
-    char entity_pool_str6066[sizeof("odash")];
-    char entity_pool_str6067[sizeof("cirmid")];
-    char entity_pool_str6068[sizeof("suphsub")];
-    char entity_pool_str6069[sizeof("supdsub")];
-    char entity_pool_str6077[sizeof("supdot")];
-    char entity_pool_str6079[sizeof("awconint")];
-    char entity_pool_str6084[sizeof("TSHcy")];
-    char entity_pool_str6087[sizeof("grave")];
-    char entity_pool_str6101[sizeof("lsimg")];
-    char entity_pool_str6106[sizeof("UpArrowDownArrow")];
-    char entity_pool_str6121[sizeof("LeftVector")];
-    char entity_pool_str6122[sizeof("DoubleRightArrow")];
-    char entity_pool_str6129[sizeof("NegativeThinSpace")];
-    char entity_pool_str6140[sizeof("lhblk")];
-    char entity_pool_str6146[sizeof("cire")];
-    char entity_pool_str6147[sizeof("nVDash")];
-    char entity_pool_str6151[sizeof("uhblk")];
-    char entity_pool_str6155[sizeof("imagpart")];
-    char entity_pool_str6161[sizeof("RightUpDownVector")];
-    char entity_pool_str6164[sizeof("boxdL")];
-    char entity_pool_str6176[sizeof("gla")];
-    char entity_pool_str6193[sizeof("Iuml")];
-    char entity_pool_str6203[sizeof("oelig")];
-    char entity_pool_str6208[sizeof("NotLessSlantEqual")];
-    char entity_pool_str6210[sizeof("boxDL")];
-    char entity_pool_str6215[sizeof("gamma")];
-    char entity_pool_str6236[sizeof("Otimes")];
-    char entity_pool_str6248[sizeof("longleftrightarrow")];
-    char entity_pool_str6261[sizeof("Gamma")];
-    char entity_pool_str6262[sizeof("bigwedge")];
-    char entity_pool_str6268[sizeof("boxhd")];
-    char entity_pool_str6283[sizeof("supE")];
-    char entity_pool_str6292[sizeof("LeftUpTeeVector")];
-    char entity_pool_str6298[sizeof("gesdoto")];
-    char entity_pool_str6304[sizeof("kappa")];
-    char entity_pool_str6315[sizeof("ngeqslant")];
-    char entity_pool_str6340[sizeof("gtrless")];
-    char entity_pool_str6351[sizeof("fflig")];
-    char entity_pool_str6352[sizeof("bigsqcup")];
-    char entity_pool_str6367[sizeof("kgreen")];
-    char entity_pool_str6368[sizeof("supe")];
-    char entity_pool_str6370[sizeof("boxtimes")];
-    char entity_pool_str6386[sizeof("gnapprox")];
-    char entity_pool_str6394[sizeof("downdownarrows")];
-    char entity_pool_str6403[sizeof("biguplus")];
-    char entity_pool_str6404[sizeof("khcy")];
-    char entity_pool_str6406[sizeof("ddagger")];
-    char entity_pool_str6418[sizeof("Ouml")];
-    char entity_pool_str6420[sizeof("Beta")];
-    char entity_pool_str6421[sizeof("minusd")];
-    char entity_pool_str6422[sizeof("succnsim")];
-    char entity_pool_str6424[sizeof("ctdot")];
-    char entity_pool_str6427[sizeof("kjcy")];
-    char entity_pool_str6428[sizeof("gjcy")];
-    char entity_pool_str6430[sizeof("ncong")];
-    char entity_pool_str6431[sizeof("xvee")];
-    char entity_pool_str6432[sizeof("bcong")];
-    char entity_pool_str6439[sizeof("sqsube")];
-    char entity_pool_str6442[sizeof("boxdR")];
-    char entity_pool_str6445[sizeof("Longleftrightarrow")];
-    char entity_pool_str6447[sizeof("sqsub")];
-    char entity_pool_str6451[sizeof("DownLeftRightVector")];
-    char entity_pool_str6454[sizeof("sqsubset")];
-    char entity_pool_str6456[sizeof("NotVerticalBar")];
-    char entity_pool_str6461[sizeof("NotEqualTilde")];
-    char entity_pool_str6485[sizeof("boxdl")];
-    char entity_pool_str6488[sizeof("boxDR")];
-    char entity_pool_str6490[sizeof("andand")];
-    char entity_pool_str6502[sizeof("RightVector")];
-    char entity_pool_str6504[sizeof("IJlig")];
-    char e

<TRUNCATED>

[02/20] lucy-clownfish git commit: Rework handling of man page paragraphs

Posted by nw...@apache.org.
Rework handling of man page paragraphs


Project: http://git-wip-us.apache.org/repos/asf/lucy-clownfish/repo
Commit: http://git-wip-us.apache.org/repos/asf/lucy-clownfish/commit/1a6ff500
Tree: http://git-wip-us.apache.org/repos/asf/lucy-clownfish/tree/1a6ff500
Diff: http://git-wip-us.apache.org/repos/asf/lucy-clownfish/diff/1a6ff500

Branch: refs/heads/master
Commit: 1a6ff500ac8c5a8f13c77026e5b7807e4240885e
Parents: c0f9515
Author: Nick Wellnhofer <we...@aevum.de>
Authored: Sun Jul 26 22:51:20 2015 +0200
Committer: Nick Wellnhofer <we...@aevum.de>
Committed: Thu Aug 6 18:19:19 2015 +0200

----------------------------------------------------------------------
 compiler/src/CFCCMan.c | 95 ++++++++++++++++++++++++++-------------------
 1 file changed, 56 insertions(+), 39 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/lucy-clownfish/blob/1a6ff500/compiler/src/CFCCMan.c
----------------------------------------------------------------------
diff --git a/compiler/src/CFCCMan.c b/compiler/src/CFCCMan.c
index d6ba04d..be9aaaf 100644
--- a/compiler/src/CFCCMan.c
+++ b/compiler/src/CFCCMan.c
@@ -66,10 +66,10 @@ static char*
 S_man_create_inheritance(CFCClass *klass);
 
 static char*
-S_md_to_man(CFCClass *klass, const char *md, int needs_indent);
+S_md_to_man(CFCClass *klass, const char *md, int level);
 
 static char*
-S_nodes_to_man(CFCClass *klass, cmark_node *node, int needs_indent);
+S_nodes_to_man(CFCClass *klass, cmark_node *node, int level);
 
 static char*
 S_man_escape(const char *content);
@@ -132,7 +132,7 @@ S_man_create_name(CFCClass *klass) {
         raw_brief = CFCDocuComment_get_brief(docucom);
     }
     if (raw_brief && raw_brief[0] != '\0') {
-        char *brief = S_md_to_man(klass, raw_brief, false);
+        char *brief = S_md_to_man(klass, raw_brief, 0);
         result = CFCUtil_cat(result, " \\- ", brief, NULL);
         FREEMEM(brief);
     }
@@ -159,7 +159,7 @@ S_man_create_description(CFCClass *klass) {
     const char *raw_description = CFCDocuComment_get_long(docucom);
     if (!raw_description || raw_description[0] == '\0') { return result; }
 
-    char *description = S_md_to_man(klass, raw_description, false);
+    char *description = S_md_to_man(klass, raw_description, 0);
     result = CFCUtil_cat(result, ".SH DESCRIPTION\n", description, NULL);
     FREEMEM(description);
 
@@ -308,7 +308,7 @@ S_man_create_func(CFCClass *klass, CFCFunction *func, const char *full_sym) {
     if (docucomment) {
         // Description
         const char *raw_desc = CFCDocuComment_get_description(docucomment);
-        char *desc = S_md_to_man(klass, raw_desc, true);
+        char *desc = S_md_to_man(klass, raw_desc, 1);
         result = CFCUtil_cat(result, ".IP\n", desc, NULL);
         FREEMEM(desc);
 
@@ -320,7 +320,7 @@ S_man_create_func(CFCClass *klass, CFCFunction *func, const char *full_sym) {
         if (param_names[0]) {
             result = CFCUtil_cat(result, ".RS\n", NULL);
             for (size_t i = 0; param_names[i] != NULL; i++) {
-                char *doc = S_md_to_man(klass, param_docs[i], true);
+                char *doc = S_md_to_man(klass, param_docs[i], 1);
                 result = CFCUtil_cat(result, ".TP\n.I ", param_names[i],
                                      "\n", doc, NULL);
                 FREEMEM(doc);
@@ -331,7 +331,7 @@ S_man_create_func(CFCClass *klass, CFCFunction *func, const char *full_sym) {
         // Return value
         const char *retval_doc = CFCDocuComment_get_retval(docucomment);
         if (retval_doc && strlen(retval_doc)) {
-            char *doc = S_md_to_man(klass, retval_doc, true);
+            char *doc = S_md_to_man(klass, retval_doc, 1);
             result = CFCUtil_cat(result, ".IP\n.B Returns:\n", doc, NULL);
             FREEMEM(doc);
         }
@@ -409,24 +409,49 @@ S_man_create_inheritance(CFCClass *klass) {
 }
 
 static char*
-S_md_to_man(CFCClass *klass, const char *md, int needs_indent) {
+S_md_to_man(CFCClass *klass, const char *md, int level) {
     int options = CMARK_OPT_NORMALIZE
                   | CMARK_OPT_SMART
                   | CMARK_OPT_VALIDATE_UTF8
                   | CMARK_OPT_SAFE;
     cmark_node *doc = cmark_parse_document(md, strlen(md), options);
-    char *result = S_nodes_to_man(klass, doc, needs_indent);
+    char *result = S_nodes_to_man(klass, doc, level);
     cmark_node_free(doc);
 
     return result;
 }
 
+/*
+ * The first level is indented with .IP, the next levels with .RS and .RE.
+ * Every change of indentation requires an adjustment to the next paragraph.
+ *
+ * - After increasing the indent, the next paragraph must start with .IP.
+ * - After decreasing the indentation to a lever larger than zero, the
+ *   next paragraph mus also start with .IP.
+ * - After decreasing the indentation to level zero, the next paragraph
+ *   must start with .P.
+ *
+ * Level 0
+ * .IP
+ * Level 1
+ * .RS
+ * .IP
+ * Level 2
+ * .RE
+ * .IP
+ * Level 1
+ * .P
+ * Level 0
+ *
+ */
+
+#define ADJUST_REINDENT  1
+#define ADJUST_VSPACE    2
+
 static char*
-S_nodes_to_man(CFCClass *klass, cmark_node *node, int needs_indent) {
+S_nodes_to_man(CFCClass *klass, cmark_node *node, int level) {
     char *result = CFCUtil_strdup("");
-    int level      = needs_indent ? 1 : 0;
-    int has_indent = needs_indent;
-    int has_vspace = true;
+    int needs_adjust = 0;
     int found_matching_code_block = false;
     cmark_iter *iter = cmark_iter_new(node);
     cmark_event_type ev_type;
@@ -441,30 +466,27 @@ S_nodes_to_man(CFCClass *klass, cmark_node *node, int needs_indent) {
 
             case CMARK_NODE_PARAGRAPH:
                 if (ev_type == CMARK_EVENT_ENTER) {
-                    if (level > 0 && !has_indent) {
-                        result = CFCUtil_cat(result, ".IP\n", NULL);
-                        has_indent = true;
-                    }
-                    else if (level == 0 && has_indent) {
-                        result = CFCUtil_cat(result, ".P\n", NULL);
-                        has_indent = false;
+                    if (needs_adjust == ADJUST_REINDENT) {
+                        const char *man = level == 0 ? ".P\n" : ".IP\n";
+                        result = CFCUtil_cat(result, man, NULL);
                     }
-                    else if (!has_vspace) {
+                    else if (needs_adjust == ADJUST_VSPACE) {
                         result = CFCUtil_cat(result, "\n", NULL);
                     }
                 }
                 else {
                     result = CFCUtil_cat(result, "\n", NULL);
-                    has_vspace = false;
+                    needs_adjust = ADJUST_VSPACE;
                 }
                 break;
 
             case CMARK_NODE_BLOCK_QUOTE:
-            case CMARK_NODE_LIST:
+            case CMARK_NODE_LIST: {
+                int prev_adjust = needs_adjust;
+                needs_adjust = ADJUST_REINDENT;
                 if (ev_type == CMARK_EVENT_ENTER) {
                     if (level > 0) {
                         result = CFCUtil_cat(result, ".RS\n", NULL);
-                        has_indent = false;
                     }
                     ++level;
                 }
@@ -472,16 +494,19 @@ S_nodes_to_man(CFCClass *klass, cmark_node *node, int needs_indent) {
                     --level;
                     if (level > 0) {
                         result = CFCUtil_cat(result, ".RE\n", NULL);
-                        has_indent = false;
+                    }
+                    else if (prev_adjust == ADJUST_REINDENT) {
+                        // Avoid .P after consecutive .REs.
+                        needs_adjust = 0;
                     }
                 }
                 break;
+            }
 
             case CMARK_NODE_ITEM:
                 if (ev_type == CMARK_EVENT_ENTER) {
                     result = CFCUtil_cat(result, ".IP \\(bu\n", NULL);
-                    has_indent = true;
-                    has_vspace = true;
+                    needs_adjust = 0;
                 }
                 break;
 
@@ -489,11 +514,10 @@ S_nodes_to_man(CFCClass *klass, cmark_node *node, int needs_indent) {
                 // Only works on top level for now.
                 if (ev_type == CMARK_EVENT_ENTER) {
                     result = CFCUtil_cat(result, ".SS\n", NULL);
-                    has_indent = false;
                 }
                 else {
                     result = CFCUtil_cat(result, "\n", NULL);
-                    has_vspace = true;
+                    needs_adjust = 0;
                 }
                 break;
 
@@ -515,12 +539,9 @@ S_nodes_to_man(CFCClass *klass, cmark_node *node, int needs_indent) {
 
                     if (level > 0) {
                         result = CFCUtil_cat(result, ".RE\n", NULL);
-                        has_indent = false;
-                    }
-                    else {
-                        has_indent = true;
-                        has_vspace = false;
                     }
+
+                    needs_adjust = ADJUST_REINDENT;
                 }
 
                 if (CFCMarkdown_code_block_is_last(node)) {
@@ -535,12 +556,8 @@ S_nodes_to_man(CFCClass *klass, cmark_node *node, int needs_indent) {
                             NULL);
                         if (level > 0) {
                             result = CFCUtil_cat(result, ".RE\n", NULL);
-                            has_indent = false;
-                        }
-                        else {
-                            has_indent = true;
-                            has_vspace = false;
                         }
+                        needs_adjust = ADJUST_REINDENT;
                     }
                     else {
                         // Reset.


[10/20] lucy-clownfish git commit: Upgrade libcmark to 0.21.0

Posted by nw...@apache.org.
http://git-wip-us.apache.org/repos/asf/lucy-clownfish/blob/89c7b809/compiler/modules/CommonMark/src/commonmark.c
----------------------------------------------------------------------
diff --git a/compiler/modules/CommonMark/src/commonmark.c b/compiler/modules/CommonMark/src/commonmark.c
new file mode 100644
index 0000000..0f4c2bc
--- /dev/null
+++ b/compiler/modules/CommonMark/src/commonmark.c
@@ -0,0 +1,462 @@
+#include <stdlib.h>
+#include <stdio.h>
+#include <string.h>
+#include <assert.h>
+#include <ctype.h>
+
+#include "config.h"
+#include "cmark.h"
+#include "node.h"
+#include "buffer.h"
+#include "utf8.h"
+#include "scanners.h"
+#include "render.h"
+
+#define safe_strlen(s) cmark_strbuf_safe_strlen(s)
+#define OUT(s, wrap, escaping) renderer->out(renderer, s, wrap, escaping)
+#define LIT(s) renderer->out(renderer, s, false, LITERAL)
+#define CR() renderer->cr(renderer)
+#define BLANKLINE() renderer->blankline(renderer)
+
+// Functions to convert cmark_nodes to commonmark strings.
+
+static inline void outc(cmark_renderer *renderer,
+                        cmark_escaping escape,
+                        int32_t c,
+                        unsigned char nextc)
+{
+	bool needs_escaping = false;
+	needs_escaping =
+	    escape != LITERAL &&
+	    ((escape == NORMAL &&
+	      (c == '*' || c == '_' || c == '[' || c == ']' || c == '#' ||
+	       c == '<' || c == '>' || c == '\\' || c == '`' || c == '!' ||
+	       (c == '&' && isalpha(nextc)) ||
+	       (c == '!' && nextc == '[') ||
+	       (renderer->begin_line &&
+	        (c == '-' || c == '+' || c == '=')) ||
+	       ((c == '.' || c == ')') &&
+	        isdigit(renderer->buffer->ptr[renderer->buffer->size - 1])))) ||
+	     (escape == URL &&
+	      (c == '`' || c == '<' || c == '>' || isspace(c) ||
+	       c == '\\' || c == ')' || c == '(')) ||
+	     (escape == TITLE &&
+	      (c == '`' || c == '<' || c == '>' || c == '"' ||
+	       c == '\\')));
+
+	if (needs_escaping) {
+		if (isspace(c)) {
+			// use percent encoding for spaces
+			cmark_strbuf_printf(renderer->buffer, "%%%2x", c);
+			renderer->column += 3;
+		} else {
+			cmark_render_ascii(renderer, "\\");
+			cmark_render_code_point(renderer, c);
+		}
+	} else {
+		cmark_render_code_point(renderer, c);
+	}
+}
+
+static int
+longest_backtick_sequence(const char *code)
+{
+	int longest = 0;
+	int current = 0;
+	size_t i = 0;
+	size_t code_len = safe_strlen(code);
+	while (i <= code_len) {
+		if (code[i] == '`') {
+			current++;
+		} else {
+			if (current > longest) {
+				longest = current;
+			}
+			current = 0;
+		}
+		i++;
+	}
+	return longest;
+}
+
+static int
+shortest_unused_backtick_sequence(const char *code)
+{
+	int32_t used = 1;
+	int current = 0;
+	size_t i = 0;
+	size_t code_len = safe_strlen(code);
+	while (i <= code_len) {
+		if (code[i] == '`') {
+			current++;
+		} else {
+			if (current) {
+				used |= (1 << current);
+			}
+			current = 0;
+		}
+		i++;
+	}
+	// return number of first bit that is 0:
+	i = 0;
+	while (used & 1) {
+		used = used >> 1;
+		i++;
+	}
+	return i;
+}
+
+static bool
+is_autolink(cmark_node *node)
+{
+	cmark_chunk *title;
+	cmark_chunk *url;
+	cmark_node *link_text;
+	char *realurl;
+	int realurllen;
+
+	if (node->type != CMARK_NODE_LINK) {
+		return false;
+	}
+
+	url = &node->as.link.url;
+	if (url->len == 0 || scan_scheme(url, 0) == 0) {
+		return false;
+	}
+
+	title = &node->as.link.title;
+	// if it has a title, we can't treat it as an autolink:
+	if (title->len > 0) {
+		return false;
+	}
+
+	link_text = node->first_child;
+	cmark_consolidate_text_nodes(link_text);
+	realurl = (char*)url->data;
+	realurllen = url->len;
+	if (strncmp(realurl, "mailto:", 7) == 0) {
+		realurl += 7;
+		realurllen -= 7;
+	}
+	return (realurllen == link_text->as.literal.len &&
+	        strncmp(realurl,
+	                (char*)link_text->as.literal.data,
+	                link_text->as.literal.len) == 0);
+}
+
+// if node is a block node, returns node.
+// otherwise returns first block-level node that is an ancestor of node.
+static cmark_node*
+get_containing_block(cmark_node *node)
+{
+	while (node &&
+	       (node->type < CMARK_NODE_FIRST_BLOCK ||
+	        node->type > CMARK_NODE_LAST_BLOCK)) {
+		node = node->parent;
+	}
+	return node;
+}
+
+static int
+S_render_node(cmark_renderer *renderer,
+              cmark_node *node,
+              cmark_event_type ev_type,
+              int options)
+{
+	cmark_node *tmp;
+	int list_number;
+	cmark_delim_type list_delim;
+	int numticks;
+	int i;
+	bool entering = (ev_type == CMARK_EVENT_ENTER);
+	const char *info, *code, *title;
+	size_t info_len, code_len;
+	cmark_strbuf listmarker = GH_BUF_INIT;
+	char *emph_delim;
+	bufsize_t marker_width;
+
+	// Don't adjust tight list status til we've started the list.
+	// Otherwise we loose the blank line between a paragraph and
+	// a following list.
+	if (!(node->type == CMARK_NODE_ITEM && node->prev == NULL &&
+	      entering)) {
+		tmp = get_containing_block(node);
+		renderer->in_tight_list_item =
+		    (tmp->type == CMARK_NODE_ITEM &&
+		     cmark_node_get_list_tight(tmp->parent)) ||
+		    (tmp &&
+		     tmp->parent &&
+		     tmp->parent->type == CMARK_NODE_ITEM &&
+		     cmark_node_get_list_tight(tmp->parent->parent));
+	}
+
+	switch (node->type) {
+	case CMARK_NODE_DOCUMENT:
+		break;
+
+	case CMARK_NODE_BLOCK_QUOTE:
+		if (entering) {
+			LIT("> ");
+			cmark_strbuf_puts(renderer->prefix, "> ");
+		} else {
+			cmark_strbuf_truncate(renderer->prefix,
+			                      renderer->prefix->size - 2);
+			BLANKLINE();
+		}
+		break;
+
+	case CMARK_NODE_LIST:
+		if (!entering && node->next &&
+		    (node->next->type == CMARK_NODE_CODE_BLOCK ||
+		     node->next->type == CMARK_NODE_LIST)) {
+			// this ensures 2 blank lines after list,
+			// if before code block or list:
+			LIT("\n");
+		}
+		break;
+
+	case CMARK_NODE_ITEM:
+		if (cmark_node_get_list_type(node->parent) ==
+		    CMARK_BULLET_LIST) {
+			marker_width = 2;
+		} else {
+			list_number = cmark_node_get_list_start(node->parent);
+			list_delim = cmark_node_get_list_delim(node->parent);
+			tmp = node;
+			while (tmp->prev) {
+				tmp = tmp->prev;
+				list_number += 1;
+			}
+			// we ensure a width of at least 4 so
+			// we get nice transition from single digits
+			// to double
+			cmark_strbuf_printf(&listmarker,
+			                    "%d%s%s", list_number,
+			                    list_delim == CMARK_PAREN_DELIM ?
+			                    ")" : ".",
+			                    list_number < 10 ? "  " : " ");
+			marker_width = listmarker.size;
+		}
+		if (entering) {
+			if (cmark_node_get_list_type(node->parent) ==
+			    CMARK_BULLET_LIST) {
+				LIT("* ");
+				cmark_strbuf_puts(renderer->prefix, "  ");
+			} else {
+				LIT((char *)listmarker.ptr);
+				for (i = marker_width; i--;) {
+					cmark_strbuf_putc(renderer->prefix, ' ');
+				}
+			}
+		} else {
+			cmark_strbuf_truncate(renderer->prefix,
+			                      renderer->prefix->size -
+			                      marker_width);
+			CR();
+		}
+		cmark_strbuf_free(&listmarker);
+		break;
+
+	case CMARK_NODE_HEADER:
+		if (entering) {
+			for (int i = cmark_node_get_header_level(node); i > 0; i--) {
+				LIT("#");
+			}
+			LIT(" ");
+			renderer->no_wrap = true;
+		} else {
+			renderer->no_wrap = false;
+			BLANKLINE();
+		}
+		break;
+
+	case CMARK_NODE_CODE_BLOCK:
+		BLANKLINE();
+		info = cmark_node_get_fence_info(node);
+		info_len = safe_strlen(info);
+		code = cmark_node_get_literal(node);
+		code_len = safe_strlen(code);
+		// use indented form if no info, and code doesn't
+		// begin or end with a blank line, and code isn't
+		// first thing in a list item
+		if (info_len == 0 &&
+		    (code_len > 2 &&
+		     !isspace(code[0]) &&
+		     !(isspace(code[code_len - 1]) &&
+		       isspace(code[code_len - 2]))) &&
+		    !(node->prev == NULL && node->parent &&
+		      node->parent->type == CMARK_NODE_ITEM)) {
+			LIT("    ");
+			cmark_strbuf_puts(renderer->prefix, "    ");
+			OUT(cmark_node_get_literal(node), false, LITERAL);
+			cmark_strbuf_truncate(renderer->prefix,
+			                      renderer->prefix->size - 4);
+		} else {
+			numticks = longest_backtick_sequence(code) + 1;
+			if (numticks < 3) {
+				numticks = 3;
+			}
+			for (i = 0; i < numticks; i++) {
+				LIT("`");
+			}
+			LIT(" ");
+			OUT(info, false, LITERAL);
+			CR();
+			OUT(cmark_node_get_literal(node), false, LITERAL);
+			CR();
+			for (i = 0; i < numticks; i++) {
+				LIT("`");
+			}
+		}
+		BLANKLINE();
+		break;
+
+	case CMARK_NODE_HTML:
+		BLANKLINE();
+		OUT(cmark_node_get_literal(node), false, LITERAL);
+		BLANKLINE();
+		break;
+
+	case CMARK_NODE_HRULE:
+		BLANKLINE();
+		LIT("-----");
+		BLANKLINE();
+		break;
+
+	case CMARK_NODE_PARAGRAPH:
+		if (!entering) {
+			BLANKLINE();
+		}
+		break;
+
+	case CMARK_NODE_TEXT:
+		OUT(cmark_node_get_literal(node), true, NORMAL);
+		break;
+
+	case CMARK_NODE_LINEBREAK:
+		if (!(CMARK_OPT_HARDBREAKS & options)) {
+			LIT("\\");
+		}
+		CR();
+		break;
+
+	case CMARK_NODE_SOFTBREAK:
+		if (renderer->width == 0 &&
+		    !(CMARK_OPT_HARDBREAKS & options)) {
+			CR();
+		} else {
+			OUT(" ", true, LITERAL);
+		}
+		break;
+
+	case CMARK_NODE_CODE:
+		code = cmark_node_get_literal(node);
+		code_len = safe_strlen(code);
+		numticks = shortest_unused_backtick_sequence(code);
+		for (i = 0; i < numticks; i++) {
+			LIT("`");
+		}
+		if (code_len == 0 || code[0] == '`') {
+			LIT(" ");
+		}
+		OUT(cmark_node_get_literal(node), true, LITERAL);
+		if (code_len == 0 || code[code_len - 1] == '`') {
+			LIT(" ");
+		}
+		for (i = 0; i < numticks; i++) {
+			LIT("`");
+		}
+		break;
+
+	case CMARK_NODE_INLINE_HTML:
+		OUT(cmark_node_get_literal(node), false, LITERAL);
+		break;
+
+	case CMARK_NODE_STRONG:
+		if (entering) {
+			LIT("**");
+		} else {
+			LIT("**");
+		}
+		break;
+
+	case CMARK_NODE_EMPH:
+		// If we have EMPH(EMPH(x)), we need to use *_x_*
+		// because **x** is STRONG(x):
+		if (node->parent && node->parent->type == CMARK_NODE_EMPH &&
+		    node->next == NULL && node->prev == NULL) {
+			emph_delim = "_";
+		} else {
+			emph_delim = "*";
+		}
+		if (entering) {
+			LIT(emph_delim);
+		} else {
+			LIT(emph_delim);
+		}
+		break;
+
+	case CMARK_NODE_LINK:
+		if (is_autolink(node)) {
+			if (entering) {
+				LIT("<");
+				if (strncmp(cmark_node_get_url(node),
+				            "mailto:", 7) == 0) {
+					LIT((char *)cmark_node_get_url(node) + 7);
+				} else {
+					LIT((char *)cmark_node_get_url(node));
+				}
+				LIT(">");
+				// return signal to skip contents of node...
+				return 0;
+			}
+		} else {
+			if (entering) {
+				LIT("[");
+			} else {
+				LIT("](");
+				OUT(cmark_node_get_url(node), false, URL);
+				title = cmark_node_get_title(node);
+				if (safe_strlen(title) > 0) {
+					LIT(" \"");
+					OUT(title, false, TITLE);
+					LIT("\"");
+				}
+				LIT(")");
+			}
+		}
+		break;
+
+	case CMARK_NODE_IMAGE:
+		if (entering) {
+			LIT("![");
+		} else {
+			LIT("](");
+			OUT(cmark_node_get_url(node), false, URL);
+			title = cmark_node_get_title(node);
+			if (safe_strlen(title) > 0) {
+				OUT(" \"", true, LITERAL);
+				OUT(title, false, TITLE);
+				LIT("\"");
+			}
+			LIT(")");
+		}
+		break;
+
+	default:
+		assert(false);
+		break;
+	}
+
+	return 1;
+}
+
+char *cmark_render_commonmark(cmark_node *root, int options, int width)
+{
+	if (options & CMARK_OPT_HARDBREAKS) {
+		// disable breaking on width, since it has
+		// a different meaning with OPT_HARDBREAKS
+		width = 0;
+	}
+	return cmark_render(root, options, width, outc, S_render_node);
+}

http://git-wip-us.apache.org/repos/asf/lucy-clownfish/blob/89c7b809/compiler/modules/CommonMark/src/config.h
----------------------------------------------------------------------
diff --git a/compiler/modules/CommonMark/src/config.h b/compiler/modules/CommonMark/src/config.h
index 7c6b476..e387e69 100644
--- a/compiler/modules/CommonMark/src/config.h
+++ b/compiler/modules/CommonMark/src/config.h
@@ -14,4 +14,8 @@ typedef char bool;
   #define va_copy(dest, src) ((dest) = (src))
 #endif
 
+#ifdef CHY_HAS_C99_SNPRINTF
+  #define HAVE_C99_SNPRINTF
+#endif
+
 #define inline CHY_INLINE

http://git-wip-us.apache.org/repos/asf/lucy-clownfish/blob/89c7b809/compiler/modules/CommonMark/src/config.h.in
----------------------------------------------------------------------
diff --git a/compiler/modules/CommonMark/src/config.h.in b/compiler/modules/CommonMark/src/config.h.in
deleted file mode 100644
index c1e9597..0000000
--- a/compiler/modules/CommonMark/src/config.h.in
+++ /dev/null
@@ -1,23 +0,0 @@
-#cmakedefine HAVE_STDBOOL_H
-
-#ifdef HAVE_STDBOOL_H
-  #include <stdbool.h>
-#elif !defined(__cplusplus)
-  typedef char bool;
-#endif
-
-#cmakedefine HAVE___BUILTIN_EXPECT
-
-#cmakedefine HAVE___ATTRIBUTE__
-
-#ifdef HAVE___ATTRIBUTE__
-  #define CMARK_ATTRIBUTE(list) __attribute__ (list)
-#else
-  #define CMARK_ATTRIBUTE(list)
-#endif
-
-#cmakedefine HAVE_VA_COPY
-
-#ifndef HAVE_VA_COPY
-  #define va_copy(dest, src) ((dest) = (src))
-#endif

http://git-wip-us.apache.org/repos/asf/lucy-clownfish/blob/89c7b809/compiler/modules/CommonMark/src/debug.h
----------------------------------------------------------------------
diff --git a/compiler/modules/CommonMark/src/debug.h b/compiler/modules/CommonMark/src/debug.h
deleted file mode 100644
index fd2ef62..0000000
--- a/compiler/modules/CommonMark/src/debug.h
+++ /dev/null
@@ -1,36 +0,0 @@
-#ifndef CMARK_DEBUG_H
-#define CMARK_DEBUG_H
-#include <stdio.h>
-#include <errno.h>
-#include <string.h>
-
-#ifdef NDEBUG
-#define debug(M, ...)
-#else
-#define debug(M, ...) \
-  fprintf(stderr, "DEBUG %s:%d: " M "\n", __FILE__, __LINE__, ##__VA_ARGS__)
-#endif
-
-#define clean_errno() (errno == 0 ? "None" : strerror(errno))
-
-#define log_err(M, ...) \
-  fprintf(stderr, "[ERROR] (%s:%d: errno: %s) " M "\n", __FILE__, __LINE__, \
-           clean_errno(), ##__VA_ARGS__)
-
-#define log_warn(M, ...) \
-  fprintf(stderr, "[WARN] (%s:%d: errno: %s) " M "\n", __FILE__, __LINE__, \
-           clean_errno(), ##__VA_ARGS__)
-
-#define log_info(M, ...) fprintf(stderr, "[INFO] (%s:%d) " M "\n", __FILE__, \
-            __LINE__, ##__VA_ARGS__)
-
-#define check(A, M, ...) \
-  if(!(A)) { log_err(M, ##__VA_ARGS__); errno=0; goto error; }
-
-#define sentinel(M, ...) \
-   { log_err(M, ##__VA_ARGS__); errno=0; goto error; }
-
-#define check_debug(A, M, ...) \
-  if(!(A)) { debug(M, ##__VA_ARGS__); errno=0; goto error; }
-
-#endif


[15/20] lucy-clownfish git commit: Directory structure for HTML documentation

Posted by nw...@apache.org.
Directory structure for HTML documentation

Use a hierachical directory structure derived from class name.


Project: http://git-wip-us.apache.org/repos/asf/lucy-clownfish/repo
Commit: http://git-wip-us.apache.org/repos/asf/lucy-clownfish/commit/ea9281ee
Tree: http://git-wip-us.apache.org/repos/asf/lucy-clownfish/tree/ea9281ee
Diff: http://git-wip-us.apache.org/repos/asf/lucy-clownfish/diff/ea9281ee

Branch: refs/heads/master
Commit: ea9281eee0383c7e0aaa07bba54046c4c849576f
Parents: ef14427
Author: Nick Wellnhofer <we...@aevum.de>
Authored: Sat Jul 25 20:49:30 2015 +0200
Committer: Nick Wellnhofer <we...@aevum.de>
Committed: Thu Aug 6 18:19:19 2015 +0200

----------------------------------------------------------------------
 compiler/src/CFCCHtml.c | 115 +++++++++++++++++++++++++++++++++++--------
 1 file changed, 95 insertions(+), 20 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/lucy-clownfish/blob/ea9281ee/compiler/src/CFCCHtml.c
----------------------------------------------------------------------
diff --git a/compiler/src/CFCCHtml.c b/compiler/src/CFCCHtml.c
index 0697754..02cc34e 100644
--- a/compiler/src/CFCCHtml.c
+++ b/compiler/src/CFCCHtml.c
@@ -159,6 +159,15 @@ S_convert_uri(CFCClass *klass, cmark_node *link);
 static char*
 S_type_to_html(CFCClass *klass, CFCType *type);
 
+static char*
+S_struct_sym_to_url(const char *struct_sym, CFCClass *base);
+
+static char*
+S_class_to_url(CFCClass *klass, CFCClass *base);
+
+static char*
+S_relative_url(const char *url, CFCClass *base);
+
 CFCCHtml*
 CFCCHtml_new(CFCHierarchy *hierarchy, const char *header, const char *footer) {
     CFCCHtml *self = (CFCCHtml*)CFCBase_allocate(&CFCCHTML_META);
@@ -246,23 +255,37 @@ CFCCHtml_write_html_docs(CFCCHtml *self) {
             continue;
         }
 
-        const char *full_struct_sym = CFCClass_full_struct_sym(klass);
-        filenames[num_docs] = CFCUtil_sprintf("%s.html", full_struct_sym);
+        const char *class_name = CFCClass_get_name(klass);
+        char *path = CFCUtil_global_replace(class_name, "::", CHY_DIR_SEP);
+        filenames[num_docs] = CFCUtil_sprintf("%s.html", path);
         html_docs[num_docs] = CFCCHtml_create_html_doc(self, klass);
         ++num_docs;
-    }
 
-    if (!CFCUtil_is_dir(doc_path)) {
-        CFCUtil_make_path(doc_path);
-        if (!CFCUtil_is_dir(doc_path)) {
-            CFCUtil_die("Can't make path %s", doc_path);
-        }
+        FREEMEM(path);
     }
 
     for (size_t i = 0; i < num_docs; ++i) {
         char *filename = filenames[i];
         char *path     = CFCUtil_sprintf("%s" CHY_DIR_SEP "%s", doc_path,
                                          filename);
+
+        char *dir  = CFCUtil_strdup(path);
+        for (size_t j = strlen(dir); j--;) {
+            if (dir[j] == CHY_DIR_SEP_CHAR) {
+                do {
+                    dir[j] = '\0';
+                } while (j-- && dir[j] == CHY_DIR_SEP_CHAR);
+                break;
+            }
+        }
+
+        if (dir[0] != '\0' && !CFCUtil_is_dir(dir)) {
+            CFCUtil_make_path(dir);
+            if (!CFCUtil_is_dir(dir)) {
+                CFCUtil_die("Can't make path %s", dir);
+            }
+        }
+
         char *html_doc = html_docs[i];
         CFCUtil_write_if_changed(path, html_doc, strlen(html_doc));
         FREEMEM(html_doc);
@@ -290,11 +313,12 @@ CFCCHtml_create_index_doc(CFCCHtml *self, CFCParcel *parcel,
             continue;
         }
 
-        const char *struct_sym = CFCClass_full_struct_sym(klass);
         const char *class_name = CFCClass_get_name(klass);
+        char *url = S_class_to_url(klass, NULL);
         class_list
-            = CFCUtil_cat(class_list, "<li><a href=\"", struct_sym, ".html\">",
+            = CFCUtil_cat(class_list, "<li><a href=\"", url, "\">",
                           class_name, "</a></li>\n", NULL);
+        FREEMEM(url);
     }
 
     if (class_list[0] == '\0') {
@@ -370,6 +394,7 @@ CFCCHtml_create_html_body(CFCClass *klass) {
     char *inheritance = S_html_create_inheritance(klass);
 
     char *index_filename = S_index_filename(parcel);
+    char *index_url      = S_relative_url(index_filename, klass);
 
     // Put it all together.
     const char pattern[] =
@@ -403,12 +428,13 @@ CFCCHtml_create_html_body(CFCClass *klass) {
         "%s"
         "%s";
     char *html_body
-        = CFCUtil_sprintf(pattern, class_name, index_filename,
+        = CFCUtil_sprintf(pattern, class_name, index_url,
                           parcel_name, PREFIX, class_var, prefix, struct_sym,
                           prefix, class_nickname, include_h, name, synopsis,
                           description, functions_html, methods_html,
                           inheritance);
 
+    FREEMEM(index_url);
     FREEMEM(index_filename);
     FREEMEM(name);
     FREEMEM(synopsis);
@@ -748,9 +774,10 @@ S_html_create_inheritance(CFCClass *klass) {
                          NULL);
     while (ancestor) {
         const char *ancestor_name = CFCClass_get_name(ancestor);
-        const char *ancestor_sym  = CFCClass_full_struct_sym(ancestor);
-        result = CFCUtil_cat(result, " is a <a href=\"", ancestor_sym,
-                             ".html\">", ancestor_name, "</a>", NULL);
+        char *ancestor_url = S_class_to_url(ancestor, klass);
+        result = CFCUtil_cat(result, " is a <a href=\"", ancestor_url, "\">",
+                             ancestor_name, "</a>", NULL);
+        FREEMEM(ancestor_url);
         ancestor = CFCClass_get_parent(ancestor);
     }
     result = CFCUtil_cat(result, ".</p>\n", NULL);
@@ -803,7 +830,7 @@ S_convert_uri(CFCClass *klass, cmark_node *link) {
     switch (type) {
         case CFC_URI_CLASS: {
             const char *struct_sym = CFCUri_full_struct_sym(uri_obj);
-            new_uri = CFCUtil_sprintf("%s.html", struct_sym);
+            new_uri = S_struct_sym_to_url(struct_sym, klass);
             break;
         }
 
@@ -811,7 +838,9 @@ S_convert_uri(CFCClass *klass, cmark_node *link) {
         case CFC_URI_METHOD: {
             const char *struct_sym = CFCUri_full_struct_sym(uri_obj);
             const char *func_sym   = CFCUri_get_func_sym(uri_obj);
-            new_uri = CFCUtil_sprintf("%s.html#func_%s", struct_sym, func_sym);
+            char *url = S_struct_sym_to_url(struct_sym, klass);
+            new_uri = CFCUtil_sprintf("%s#func_%s", url, func_sym);
+            FREEMEM(url);
             break;
         }
     }
@@ -866,13 +895,13 @@ S_type_to_html(CFCClass *klass, CFCType *type) {
                                          prefix, type_c + offset);
             }
             else {
+                char *url = S_struct_sym_to_url(specifier, klass);
                 const char *pattern =
                     "<span class=\"prefix\">%s</span>"
-                    "<a href=\"%s.html\">"
-                    "%s"
-                    "</a>";
-                retval = CFCUtil_sprintf(pattern, prefix, specifier,
+                    "<a href=\"%s\">%s</a>";
+                retval = CFCUtil_sprintf(pattern, prefix, url,
                                          type_c + offset);
+                FREEMEM(url);
             }
 
             FREEMEM(prefix);
@@ -883,3 +912,49 @@ S_type_to_html(CFCClass *klass, CFCType *type) {
     return CFCUtil_strdup(type_c);
 }
 
+// Return a relative URL to the class with full struct sym `struct_sym`.
+static char*
+S_struct_sym_to_url(const char *struct_sym, CFCClass *base) {
+    if (!struct_sym) { return CFCUtil_strdup("not_found.html"); }
+
+    CFCClass *klass = CFCClass_fetch_by_struct_sym(struct_sym);
+
+    return S_class_to_url(klass, base);
+}
+
+// Return a relative URL to a class.
+static char*
+S_class_to_url(CFCClass *klass, CFCClass *base) {
+    if (!klass) { return CFCUtil_strdup("not_found.html"); }
+
+    const char *class_name = CFCClass_get_name(klass);
+    char *path    = CFCUtil_global_replace(class_name, "::", CHY_DIR_SEP);
+    char *url     = CFCUtil_sprintf("%s.html", path);
+    char *rel_url = S_relative_url(url, base);
+
+    FREEMEM(url);
+    FREEMEM(path);
+    return rel_url;
+}
+
+static char*
+S_relative_url(const char *url, CFCClass *base) {
+    if (base == NULL) { return CFCUtil_strdup(url); }
+
+    // Create path back to root
+    char *prefix = CFCUtil_strdup("");
+    const char *base_name = CFCClass_get_name(base);
+
+    for (size_t i = 0; base_name[i]; i++) {
+        if (base_name[i] == ':' && base_name[i+1] == ':') {
+            prefix = CFCUtil_cat(prefix, "../", NULL);
+            i++;
+        }
+    }
+
+    char *rel_url = CFCUtil_sprintf("%s%s", prefix, url);
+
+    FREEMEM(prefix);
+    return rel_url;
+}
+


[16/20] lucy-clownfish git commit: Simplify URI handling

Posted by nw...@apache.org.
Simplify URI handling


Project: http://git-wip-us.apache.org/repos/asf/lucy-clownfish/repo
Commit: http://git-wip-us.apache.org/repos/asf/lucy-clownfish/commit/37504e4c
Tree: http://git-wip-us.apache.org/repos/asf/lucy-clownfish/tree/37504e4c
Diff: http://git-wip-us.apache.org/repos/asf/lucy-clownfish/diff/37504e4c

Branch: refs/heads/master
Commit: 37504e4cb19bc94fc801ef511a621d475022a813
Parents: 7973bf5
Author: Nick Wellnhofer <we...@aevum.de>
Authored: Sun Jul 26 18:29:53 2015 +0200
Committer: Nick Wellnhofer <we...@aevum.de>
Committed: Thu Aug 6 18:19:19 2015 +0200

----------------------------------------------------------------------
 compiler/src/CFCC.c       |  90 +++-----------
 compiler/src/CFCC.h       |   2 +-
 compiler/src/CFCCHtml.c   |  98 +++++++--------
 compiler/src/CFCCMan.c    |   2 +-
 compiler/src/CFCPerlPod.c |  98 ++++++---------
 compiler/src/CFCUri.c     | 276 +++++++++++++++++++++++------------------
 compiler/src/CFCUri.h     |  21 ++--
 7 files changed, 274 insertions(+), 313 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/lucy-clownfish/blob/37504e4c/compiler/src/CFCC.c
----------------------------------------------------------------------
diff --git a/compiler/src/CFCC.c b/compiler/src/CFCC.c
index aa1e267..6fba122 100644
--- a/compiler/src/CFCC.c
+++ b/compiler/src/CFCC.c
@@ -172,89 +172,35 @@ CFCC_write_hostdefs(CFCC *self) {
 }
 
 char*
-CFCC_link_text(CFCUri *uri_obj, CFCClass *klass) {
+CFCC_link_text(CFCUri *uri_obj) {
     char *link_text = NULL;
     int   type      = CFCUri_get_type(uri_obj);
 
     switch (type) {
-        case CFC_URI_CLASS: {
-            const char *full_struct_sym = CFCUri_full_struct_sym(uri_obj);
-            CFCClass *uri_class = full_struct_sym
-                ? CFCClass_fetch_by_struct_sym(full_struct_sym)
-                : NULL;
-
-            if (uri_class) {
-                if (klass
-                    && strcmp(CFCClass_get_prefix(uri_class),
-                              CFCClass_get_prefix(klass)) == 0
-                ) {
-                    // Same parcel.
-                    const char *struct_sym = CFCUri_get_struct_sym(uri_obj);
-                    link_text = CFCUtil_strdup(struct_sym);
-                }
-                else {
-                    // Other parcel.
-                    const char *class_name = CFCClass_get_name(uri_class);
-                    link_text = CFCUtil_strdup(class_name);
-                }
-
-                break;
-            }
-
-            const char *struct_sym = CFCUri_get_struct_sym(uri_obj);
-            CFCDocument *doc = CFCDocument_fetch(struct_sym);
-
-            if (doc) {
-                const char *name = CFCDocument_get_name(doc);
-                link_text = CFCUtil_strdup(name);
-                break;
-            }
+        case CFC_URI_NULL:
+            link_text = CFCUtil_strdup("NULL");
+            break;
 
-            CFCUtil_warn("Can't resolve Clownfish URI '%s'", struct_sym);
+        case CFC_URI_CLASS: {
+            CFCClass *klass = CFCUri_get_class(uri_obj);
+            const char *src = CFCClass_included(klass)
+                              ? CFCClass_get_name(klass)
+                              : CFCClass_get_struct_sym(klass);
+            link_text = CFCUtil_strdup(src);
             break;
         }
 
         case CFC_URI_FUNCTION:
         case CFC_URI_METHOD: {
-#if 1
-            const char *func_sym = CFCUri_get_func_sym(uri_obj);
-            link_text = CFCUtil_sprintf("%s()", func_sym);
-#else
-            // Full function sym.
-            const char *full_struct_sym = CFCUri_full_struct_sym(uri_obj);
-            const char *func_sym        = CFCUri_get_func_sym(uri_obj);
-
-            if (strcmp(full_struct_sym,
-                       CFCClass_full_struct_sym(klass)) == 0
-            ) {
-                // Same class.
-                link_text = CFCUtil_sprintf("%s()", func_sym);
-            }
-            else {
-                CFCClass *uri_class
-                    = CFCClass_fetch_by_struct_sym(full_struct_sym);
-
-                if (!uri_class) {
-                    CFCUtil_warn("URI class not found: %s", full_struct_sym);
-                    link_text = CFCUtil_sprintf("%s()", func_sym);
-                }
-                else {
-                    const char *prefix   = CFCUri_get_prefix(uri_obj);
-                    const char *nickname = CFCClass_get_nickname(uri_class);
+            const char *name = CFCUri_get_callable_name(uri_obj);
+            link_text = CFCUtil_sprintf("%s()", name);
+            break;
+        }
 
-                    if (strcmp(prefix, CFCClass_get_prefix(klass)) == 0) {
-                        // Same parcel.
-                        link_text = CFCUtil_sprintf("%s_%s()", nickname,
-                                                    func_sym);
-                    }
-                    else {
-                        // Other parcel.
-                        link_text = CFCUtil_sprintf("%s%s_%s()", prefix,
-                                                    nickname, func_sym);
-                    }
-                }
-            }
-#endif
+        case CFC_URI_DOCUMENT: {
+            CFCDocument *doc = CFCUri_get_document(uri_obj);
+            const char *name = CFCDocument_get_name(doc);
+            link_text = CFCUtil_strdup(name);
             break;
         }
     }

http://git-wip-us.apache.org/repos/asf/lucy-clownfish/blob/37504e4c/compiler/src/CFCC.h
----------------------------------------------------------------------
diff --git a/compiler/src/CFCC.h b/compiler/src/CFCC.h
index b8c6c73..8b98461 100644
--- a/compiler/src/CFCC.h
+++ b/compiler/src/CFCC.h
@@ -62,7 +62,7 @@ void
 CFCC_write_man_pages(CFCC *self);
 
 char*
-CFCC_link_text(struct CFCUri *uri_obj, struct CFCClass *klass);
+CFCC_link_text(struct CFCUri *uri_obj);
 
 #ifdef __cplusplus
 }

http://git-wip-us.apache.org/repos/asf/lucy-clownfish/blob/37504e4c/compiler/src/CFCCHtml.c
----------------------------------------------------------------------
diff --git a/compiler/src/CFCCHtml.c b/compiler/src/CFCCHtml.c
index aa240b0..52740f5 100644
--- a/compiler/src/CFCCHtml.c
+++ b/compiler/src/CFCCHtml.c
@@ -171,8 +171,7 @@ static char*
 S_type_to_html(CFCClass *klass, CFCType *type);
 
 static char*
-S_cfc_uri_to_url(CFCUri *uri_obj, const char *uri_string, CFCClass *base,
-                 int dir_level);
+S_cfc_uri_to_url(CFCUri *uri_obj, CFCClass *base, int dir_level);
 
 static char*
 S_struct_sym_to_url(const char *struct_sym, CFCClass *base, int dir_level);
@@ -181,6 +180,9 @@ static char*
 S_class_to_url(CFCClass *klass, CFCClass *base, int dir_level);
 
 static char*
+S_document_to_url(CFCDocument *doc, CFCClass *base, int dir_level);
+
+static char*
 S_relative_url(const char *url, CFCClass *base, int dir_level);
 
 CFCCHtml*
@@ -1007,39 +1009,21 @@ S_transform_code_block(cmark_node *code_block, int found_matching_code_block) {
 }
 
 static void
-S_transform_link(cmark_node *link, CFCClass *klass, int dir_level) {
+S_transform_link(cmark_node *link, CFCClass *doc_class, int dir_level) {
     const char *uri_string = cmark_node_get_url(link);
     if (!uri_string || !CFCUri_is_clownfish_uri(uri_string)) {
         return;
     }
 
-    char   *new_uri = NULL;
-    CFCUri *uri_obj = CFCUri_new(uri_string, klass);
-    int     type    = CFCUri_get_type(uri_obj);
-
-    switch (type) {
-        case CFC_URI_CLASS: {
-            new_uri = S_cfc_uri_to_url(uri_obj, uri_string, klass, dir_level);
-            break;
-        }
-
-        case CFC_URI_FUNCTION:
-        case CFC_URI_METHOD: {
-            const char *func_sym = CFCUri_get_func_sym(uri_obj);
-            char *url = S_cfc_uri_to_url(uri_obj, uri_string, klass,
-                                         dir_level);
-            new_uri = CFCUtil_sprintf("%s#func_%s", url, func_sym);
-            FREEMEM(url);
-            break;
-        }
-    }
+    CFCUri *uri_obj = CFCUri_new(uri_string, doc_class);
+    char   *url     = S_cfc_uri_to_url(uri_obj, doc_class, dir_level);
 
-    if (new_uri) {
-        cmark_node_set_url(link, new_uri);
+    if (url) {
+        cmark_node_set_url(link, url);
 
         if (!cmark_node_first_child(link)) {
             // Empty link text.
-            char *link_text = CFCC_link_text(uri_obj, klass);
+            char *link_text = CFCC_link_text(uri_obj);
 
             if (link_text) {
                 cmark_node *text_node = cmark_node_new(CMARK_NODE_TEXT);
@@ -1061,7 +1045,7 @@ S_transform_link(cmark_node *link, CFCClass *klass, int dir_level) {
     }
 
     CFCBase_decref((CFCBase*)uri_obj);
-    FREEMEM(new_uri);
+    FREEMEM(url);
 }
 
 static char*
@@ -1103,34 +1087,35 @@ S_type_to_html(CFCClass *klass, CFCType *type) {
 
 // Return a relative URL for a CFCUri object.
 static char*
-S_cfc_uri_to_url(CFCUri *uri_obj, const char *uri_string, CFCClass *base,
-                 int dir_level) {
-    const char *full_struct_sym = CFCUri_full_struct_sym(uri_obj);
-    CFCClass *klass = full_struct_sym
-                      ? CFCClass_fetch_by_struct_sym(full_struct_sym)
-                      : NULL;
-
-    if (klass) {
-        return S_struct_sym_to_url(full_struct_sym, base, dir_level);
-    }
+S_cfc_uri_to_url(CFCUri *uri_obj, CFCClass *doc_class, int dir_level) {
+    char *url = NULL;
+    int   type    = CFCUri_get_type(uri_obj);
 
-    const char *struct_sym = CFCUri_get_struct_sym(uri_obj);
-    CFCDocument *doc = CFCDocument_fetch(struct_sym);
+    switch (type) {
+        case CFC_URI_CLASS: {
+            CFCClass *klass = CFCUri_get_class(uri_obj);
+            url = S_class_to_url(klass, doc_class, dir_level);
+            break;
+        }
 
-    if (doc) {
-        const char *path_part = CFCDocument_get_path_part(doc);
-        char *slashy  = CFCUtil_global_replace(path_part, CHY_DIR_SEP, "/");
-        char *url     = CFCUtil_sprintf("%s.html", slashy);
-        char *rel_url = S_relative_url(url, base, dir_level);
+        case CFC_URI_FUNCTION:
+        case CFC_URI_METHOD: {
+            CFCClass *klass = CFCUri_get_class(uri_obj);
+            const char *name = CFCUri_get_callable_name(uri_obj);
+            char *class_url = S_class_to_url(klass, doc_class, dir_level);
+            url = CFCUtil_sprintf("%s#func_%s", class_url, name);
+            FREEMEM(class_url);
+            break;
+        }
 
-        FREEMEM(url);
-        FREEMEM(slashy);
-        return rel_url;
+        case CFC_URI_DOCUMENT: {
+            CFCDocument *doc = CFCUri_get_document(uri_obj);
+            url = S_document_to_url(doc, doc_class, dir_level);
+            break;
+        }
     }
 
-    CFCUtil_warn("No class or document found for URI '%s'",
-                 uri_string);
-    return CFCUtil_strdup("not_found.html");
+    return url;
 }
 
 // Return a relative URL to the class with full struct sym `struct_sym`.
@@ -1158,6 +1143,19 @@ S_class_to_url(CFCClass *klass, CFCClass *base, int dir_level) {
     return rel_url;
 }
 
+// Return a relative URL to a document.
+static char*
+S_document_to_url(CFCDocument *doc, CFCClass *base, int dir_level) {
+    const char *path_part = CFCDocument_get_path_part(doc);
+    char *slashy  = CFCUtil_global_replace(path_part, CHY_DIR_SEP, "/");
+    char *url     = CFCUtil_sprintf("%s.html", slashy);
+    char *rel_url = S_relative_url(url, base, dir_level);
+
+    FREEMEM(url);
+    FREEMEM(slashy);
+    return rel_url;
+}
+
 static char*
 S_relative_url(const char *url, CFCClass *base, int dir_level) {
     if (base) {

http://git-wip-us.apache.org/repos/asf/lucy-clownfish/blob/37504e4c/compiler/src/CFCCMan.c
----------------------------------------------------------------------
diff --git a/compiler/src/CFCCMan.c b/compiler/src/CFCCMan.c
index 6089ca3..d6ba04d 100644
--- a/compiler/src/CFCCMan.c
+++ b/compiler/src/CFCCMan.c
@@ -597,7 +597,7 @@ S_nodes_to_man(CFCClass *klass, cmark_node *node, int needs_indent) {
                     ) {
                         // Empty link text.
                         CFCUri *uri_obj = CFCUri_new(url, klass);
-                        char *link_text = CFCC_link_text(uri_obj, klass);
+                        char *link_text = CFCC_link_text(uri_obj);
                         if (link_text) {
                             result = CFCUtil_cat(result, link_text, NULL);
                             FREEMEM(link_text);

http://git-wip-us.apache.org/repos/asf/lucy-clownfish/blob/37504e4c/compiler/src/CFCPerlPod.c
----------------------------------------------------------------------
diff --git a/compiler/src/CFCPerlPod.c b/compiler/src/CFCPerlPod.c
index fa221e4..ffa0f04 100644
--- a/compiler/src/CFCPerlPod.c
+++ b/compiler/src/CFCPerlPod.c
@@ -558,10 +558,10 @@ S_pod_escape(const char *content) {
 }
 
 static char*
-S_convert_link(cmark_node *link, CFCClass *klass, int header_level) {
+S_convert_link(cmark_node *link, CFCClass *doc_class, int header_level) {
     cmark_node *child = cmark_node_first_child(link);
     const char *uri   = cmark_node_get_url(link);
-    char       *text  = S_nodes_to_pod(child, klass, header_level);
+    char       *text  = S_nodes_to_pod(child, doc_class, header_level);
     char       *retval;
 
     if (!CFCUri_is_clownfish_uri(uri)) {
@@ -572,7 +572,7 @@ S_convert_link(cmark_node *link, CFCClass *klass, int header_level) {
 
     char   *new_uri  = NULL;
     char   *new_text = NULL;
-    CFCUri *uri_obj  = CFCUri_new(uri, klass);
+    CFCUri *uri_obj  = CFCUri_new(uri, doc_class);
     int     type     = CFCUri_get_type(uri_obj);
 
     switch (type) {
@@ -582,52 +582,18 @@ S_convert_link(cmark_node *link, CFCClass *klass, int header_level) {
             break;
 
         case CFC_URI_CLASS: {
-            const char *full_struct_sym = CFCUri_full_struct_sym(uri_obj);
-            CFCClass *uri_class
-                = full_struct_sym
-                ? CFCClass_fetch_by_struct_sym(full_struct_sym)
-                : NULL;
-
-            if (uri_class) {
-                if (uri_class != klass) {
-                    const char *class_name = CFCClass_get_name(uri_class);
-                    new_uri = CFCUtil_strdup(class_name);
-                }
-            }
-            else {
-                const char *doc_name = CFCUri_get_struct_sym(uri_obj);
-                CFCDocument *doc = CFCDocument_fetch(doc_name);
+            CFCClass *klass = CFCUri_get_class(uri_obj);
 
-                if (!doc) {
-                    CFCUtil_warn("No class or document found for URI '%s'",
-                                 uri);
-                }
-                else {
-                    const char *path_part = CFCDocument_get_path_part(doc);
-                    new_uri = CFCUtil_global_replace(path_part, CHY_DIR_SEP,
-                                                     "::");
-                }
-            }
-
-            if (text[0] != '\0') {
-                // Keep text.
-                break;
+            if (klass != doc_class) {
+                const char *class_name = CFCClass_get_name(klass);
+                new_uri = CFCUtil_strdup(class_name);
             }
 
-            if (!uri_class
-                || !klass
-                || strcmp(CFCUri_get_prefix(uri_obj),
-                          CFCClass_get_prefix(klass)) == 0
-            ) {
-                // Same parcel.
-                const char *struct_sym = CFCUri_get_struct_sym(uri_obj);
-                new_text = CFCUtil_strdup(struct_sym);
-            }
-            else {
-                // Other parcel.
-                const char *class_name
-                    = CFCClass_get_name(uri_class);
-                new_text = CFCUtil_strdup(class_name);
+            if (text[0] == '\0') {
+                const char *src = CFCClass_included(klass)
+                                  ? CFCClass_get_name(klass)
+                                  : CFCClass_get_struct_sym(klass);
+                new_text = CFCUtil_strdup(src);
             }
 
             break;
@@ -635,35 +601,45 @@ S_convert_link(cmark_node *link, CFCClass *klass, int header_level) {
 
         case CFC_URI_FUNCTION:
         case CFC_URI_METHOD: {
-            const char *full_struct_sym = CFCUri_full_struct_sym(uri_obj);
-            const char *func_sym        = CFCUri_get_func_sym(uri_obj);
+            CFCClass   *klass = CFCUri_get_class(uri_obj);
+            const char *name  = CFCUri_get_callable_name(uri_obj);
 
             // Convert "Err_get_error" to "Clownfish->error".
-            if (strcmp(full_struct_sym, "cfish_Err") == 0
-                && strcmp(func_sym, "get_error") == 0
+            if (strcmp(CFCClass_full_struct_sym(klass), "cfish_Err") == 0
+                && strcmp(name, "get_error") == 0
             ) {
                 new_text = CFCUtil_strdup("Clownfish->error");
                 break;
             }
 
-            CFCClass *uri_class
-                = CFCClass_fetch_by_struct_sym(full_struct_sym);
-
             // TODO: Link to relevant POD section. This isn't easy because
             // the section headers for functions also contain a description
             // of the parameters.
 
-            if (!uri_class) {
-                CFCUtil_warn("URI class not found: %s", full_struct_sym);
-            }
-            else if (uri_class != klass) {
-                const char *class_name = CFCClass_get_name(uri_class);
+            if (klass != doc_class) {
+                const char *class_name = CFCClass_get_name(klass);
                 new_uri = CFCUtil_strdup(class_name);
             }
 
-            new_text = CFCUtil_sprintf("%s()", func_sym);
-            for (size_t i = 0; new_text[i] != '\0'; ++i) {
-                new_text[i] = tolower(new_text[i]);
+            if (text[0] == '\0') {
+                new_text = CFCUtil_sprintf("%s()", name);
+                for (size_t i = 0; new_text[i] != '\0'; ++i) {
+                    new_text[i] = tolower(new_text[i]);
+                }
+            }
+
+            break;
+        }
+
+        case CFC_URI_DOCUMENT: {
+            CFCDocument *doc = CFCUri_get_document(uri_obj);
+
+            const char *path_part = CFCDocument_get_path_part(doc);
+            new_uri = CFCUtil_global_replace(path_part, CHY_DIR_SEP, "::");
+
+            if (text[0] == '\0') {
+                const char *name = CFCDocument_get_name(doc);
+                new_text = CFCUtil_strdup(name);
             }
 
             break;

http://git-wip-us.apache.org/repos/asf/lucy-clownfish/blob/37504e4c/compiler/src/CFCUri.c
----------------------------------------------------------------------
diff --git a/compiler/src/CFCUri.c b/compiler/src/CFCUri.c
index 4799d6a..fc6e8e8 100644
--- a/compiler/src/CFCUri.c
+++ b/compiler/src/CFCUri.c
@@ -22,15 +22,17 @@
 #include "CFCBase.h"
 #include "CFCUri.h"
 #include "CFCClass.h"
+#include "CFCDocument.h"
 #include "CFCUtil.h"
 
 struct CFCUri {
-    CFCBase base;
-    int   type;
-    char *prefix;
-    char *struct_sym;
-    char *full_struct_sym;
-    char *func_sym;
+    CFCBase      base;
+    char        *string;
+    CFCClass    *doc_class;
+    int          type;
+    CFCClass    *klass;
+    CFCDocument *document;
+    char        *callable;
 };
 
 static const CFCMeta CFCURI_META = {
@@ -40,10 +42,14 @@ static const CFCMeta CFCURI_META = {
 };
 
 static void
-S_parse_uri(CFCUri *self, const char *str, CFCClass *klass);
+S_parse(CFCUri *self);
 
-static char**
-S_split(const char *str, char c, size_t *num_parts_ptr);
+static void
+S_resolve(CFCUri *self, const char *prefix, const char *struct_sym,
+          const char *callable);
+
+static char*
+S_next_component(char **iter);
 
 int
 CFCUri_is_clownfish_uri(const char *uri) {
@@ -51,176 +57,210 @@ CFCUri_is_clownfish_uri(const char *uri) {
 }
 
 CFCUri*
-CFCUri_new(const char *uri, CFCClass *klass) {
+CFCUri_new(const char *uri, CFCClass *doc_class) {
     CFCUri *self = (CFCUri*)CFCBase_allocate(&CFCURI_META);
-    return CFCUri_init(self, uri, klass);
+    return CFCUri_init(self, uri, doc_class);
 }
 
 CFCUri*
-CFCUri_init(CFCUri *self, const char *uri, CFCClass *klass) {
+CFCUri_init(CFCUri *self, const char *uri, CFCClass *doc_class) {
     CFCUTIL_NULL_CHECK(uri);
 
     if (strncmp(uri, "cfish:", 6) != 0) {
         CFCUtil_die("Invalid clownfish URI: %s", uri);
     }
 
-    if (strcmp(uri + 6, "@null") == 0) {
-        self->type = CFC_URI_NULL;
-    }
-    else {
-        S_parse_uri(self, uri, klass);
-    }
-
-    if (self->prefix && self->struct_sym) {
-        self->full_struct_sym
-            = CFCUtil_sprintf("%s%s", self->prefix, self->struct_sym);
-
-        if (getenv("CFC_CHECK_LINKS")) {
-            CFCClass *klass
-                = CFCClass_fetch_by_struct_sym(self->full_struct_sym);
-
-            if (!klass) {
-                CFCUtil_warn("No class found for URI: %s", uri);
-            }
-            else if (self->type == CFC_URI_FUNCTION) {
-                if (!CFCClass_function(klass, self->func_sym)) {
-                    const char *class_name = CFCClass_get_name(klass);
-                    CFCUtil_warn("No function found for URI %s in %s", uri,
-                                 class_name);
-                }
-            }
-            else if (self->type == CFC_URI_METHOD) {
-                if (!CFCClass_method(klass, self->func_sym)) {
-                    const char *class_name = CFCClass_get_name(klass);
-                    CFCUtil_warn("No method found for URI %s in %s", uri,
-                                 class_name);
-                }
-            }
-        }
-    }
+    self->string    = CFCUtil_strdup(uri);
+    self->doc_class = (CFCClass*)CFCBase_incref((CFCBase*)doc_class);
 
     return self;
 }
 
 void
 CFCUri_destroy(CFCUri *self) {
-    FREEMEM(self->prefix);
-    FREEMEM(self->struct_sym);
-    FREEMEM(self->full_struct_sym);
-    FREEMEM(self->func_sym);
+    FREEMEM(self->string);
+    FREEMEM(self->callable);
+    CFCBase_decref((CFCBase*)self->doc_class);
+    CFCBase_decref((CFCBase*)self->klass);
+    CFCBase_decref((CFCBase*)self->document);
     CFCBase_destroy((CFCBase*)self);
 }
 
 static void
-S_parse_uri(CFCUri *self, const char *uri, CFCClass *klass) {
-    size_t num_components = 0;
-    char **components = S_split(uri + 6, '.', &num_components);
-    size_t i = 0;
+S_parse(CFCUri *self) {
+    const char *uri_part = self->string + sizeof("cfish:") - 1;
 
-    self->type = CFC_URI_PARCEL;
+    if (strcmp(uri_part, "@null") == 0) {
+        self->type = CFC_URI_NULL;
+        return;
+    }
 
-    if (islower(components[i][0])) {
+    const char *parcel     = NULL;
+    const char *struct_sym = NULL;
+    const char *callable   = NULL;
+
+    char       *buf  = CFCUtil_strdup(uri_part);
+    char       *iter = buf;
+    const char *component = S_next_component(&iter);
+
+    if (islower(component[0])) {
         // Parcel
-        self->prefix = CFCUtil_sprintf("%s_", components[i]);
-        ++i;
-    }
-    else if (klass) {
-        self->prefix = CFCUtil_strdup(CFCClass_get_prefix(klass));
+        parcel = component;
+        component = S_next_component(&iter);
     }
 
-    if (i < num_components) {
-        self->type = CFC_URI_CLASS;
-
-        if (isupper(components[i][0])) {
+    if (component) {
+        if (isupper(component[0])) {
             // Class
-            self->struct_sym = components[i];
-            components[i] = NULL;
+            struct_sym = component;
         }
-        else if (i == 0 && components[i][0] == '\0') {
-            if (!klass) {
-                CFCUtil_die("Class needed to complete URI: %s", uri);
-            }
-            self->struct_sym = CFCUtil_strdup(CFCClass_get_struct_sym(klass));
+        else if (component == buf && component[0] == '\0' && iter) {
+            // "cfish:.Method" style URL.
+            ;
         }
         else {
-            CFCUtil_die("Invalid clownfish URI: %s", uri);
+            CFCUtil_die("Invalid component in Clownfish URI: %s",
+                        self->string);
         }
 
-        ++i;
+        component = S_next_component(&iter);
+    }
+
+    if (component) {
+        callable = component;
+        component = S_next_component(&iter);
+    }
+
+    if (component) {
+        CFCUtil_die("Trailing components in Clownfish URI: %s", self->string);
     }
 
-    if (i < num_components) {
-        if (isupper(components[i][0])) {
-            self->type = CFC_URI_METHOD;
+    S_resolve(self, parcel, struct_sym, callable);
+
+    FREEMEM(buf);
+}
+
+static void
+S_resolve(CFCUri *self, const char *parcel, const char *struct_sym,
+          const char *callable) {
+
+    // Try to find a CFCClass.
+    if (struct_sym || callable) {
+        CFCClass *doc_class = self->doc_class;
+        CFCClass *klass     = NULL;
+
+        if (parcel) {
+            char *full_struct_sym = CFCUtil_sprintf("%s_%s", parcel, struct_sym);
+            klass = CFCClass_fetch_by_struct_sym(full_struct_sym);
+            FREEMEM(full_struct_sym);
         }
-        else if (islower(components[i][0])) {
-            self->type = CFC_URI_FUNCTION;
+        else if (struct_sym && doc_class) {
+            const char *prefix = CFCClass_get_prefix(doc_class);
+            char *full_struct_sym = CFCUtil_sprintf("%s%s", prefix, struct_sym);
+            klass = CFCClass_fetch_by_struct_sym(full_struct_sym);
+            FREEMEM(full_struct_sym);
         }
         else {
-            CFCUtil_die("Invalid clownfish URI: %s", uri);
+            klass = doc_class;
         }
 
-        self->func_sym = components[i];
-        components[i] = NULL;
-        ++i;
-    }
+        if (klass) {
+            self->type  = CFC_URI_CLASS;
+            self->klass = klass;
+            CFCBase_incref((CFCBase*)klass);
 
-    if (i != num_components) {
-        CFCUtil_die("Invalid clownfish URI: %s", uri);
+            if (callable) {
+                if (islower(callable[0])) {
+                    if (!CFCClass_function(klass, callable)) {
+                        CFCUtil_warn("Unknown function '%s' in Clownfish URI: %s",
+                                     callable, self->string);
+                    }
+
+                    self->type     = CFC_URI_FUNCTION;
+                    self->callable = CFCUtil_strdup(callable);
+                }
+                else {
+                    if (!CFCClass_method(klass, callable)) {
+                        CFCUtil_warn("Unknown method '%s' in Clownfish URI: %s",
+                                     callable, self->string);
+                    }
+
+                    self->type     = CFC_URI_METHOD;
+                    self->callable = CFCUtil_strdup(callable);
+                }
+            }
+        }
     }
 
-    CFCUtil_free_string_array(components);
-}
+    // Try to find a CFCDocument.
+    if (self->type == 0 && !parcel && struct_sym && !callable) {
+        CFCDocument *doc = CFCDocument_fetch(struct_sym);
 
-static char**
-S_split(const char *str, char c, size_t *num_parts_ptr) {
-    const char *ptr;
-    int num_parts = 1;
+        if (doc) {
+            self->type     = CFC_URI_DOCUMENT;
+            self->document = doc;
+            CFCBase_incref((CFCBase*)doc);
+        }
+    }
 
-    for (ptr = str; *ptr != '\0'; ++ptr) {
-        if (*ptr == c) { ++num_parts; }
+    if (self->type == 0) {
+        CFCUtil_die("Couldn't resolve Clownfish URI: %s", self->string);
     }
+}
 
-    char **parts = (char**)MALLOCATE((num_parts + 1) * sizeof(char*));
-    const char *start = str;
-    size_t i = 0;
+static char*
+S_next_component(char **iter) {
+    char *component = *iter;
 
-    for (ptr = str; *ptr != '\0'; ++ptr) {
-        if (*ptr == c) {
-            parts[i++] = CFCUtil_strndup(start, ptr - start);
-            start = ptr + 1;
+    if (!component) { return NULL; }
+
+    for (char *ptr = component; *ptr != '\0'; ptr++) {
+        if (*ptr == '.') {
+            *ptr  = '\0';
+            *iter = ptr + 1;
+            return component;
         }
     }
-    parts[i++] = CFCUtil_strndup(start, ptr - start);
-    parts[i]   = NULL;
 
-    *num_parts_ptr = num_parts;
+    *iter = NULL;
+    return component;
+}
 
-    return parts;
+const char*
+CFCUri_get_string(CFCUri *self) {
+    return self->string;
 }
 
 int
 CFCUri_get_type(CFCUri *self) {
+    if (self->type == 0) { S_parse(self); }
     return self->type;
 }
 
-const char*
-CFCUri_get_prefix(CFCUri *self) {
-    return self->prefix;
-}
-
-const char*
-CFCUri_get_struct_sym(CFCUri *self) {
-    return self->struct_sym;
+CFCClass*
+CFCUri_get_class(CFCUri *self) {
+    if (self->type == 0) { S_parse(self); }
+    if (self->klass == NULL) {
+        CFCUtil_die("Not a class URI");
+    }
+    return self->klass;
 }
 
-const char*
-CFCUri_full_struct_sym(CFCUri *self) {
-    return self->full_struct_sym;
+CFCDocument*
+CFCUri_get_document(CFCUri *self) {
+    if (self->type == 0) { S_parse(self); }
+    if (self->document == NULL) {
+        CFCUtil_die("Not a document URI");
+    }
+    return self->document;
 }
 
 const char*
-CFCUri_get_func_sym(CFCUri *self) {
-    return self->func_sym;
+CFCUri_get_callable_name(CFCUri *self) {
+    if (self->type == 0) { S_parse(self); }
+    if (self->callable == NULL) {
+        CFCUtil_die("Not a callable URI");
+    }
+    return self->callable;
 }
 

http://git-wip-us.apache.org/repos/asf/lucy-clownfish/blob/37504e4c/compiler/src/CFCUri.h
----------------------------------------------------------------------
diff --git a/compiler/src/CFCUri.h b/compiler/src/CFCUri.h
index 004fc3c..9e22d4e 100644
--- a/compiler/src/CFCUri.h
+++ b/compiler/src/CFCUri.h
@@ -21,14 +21,15 @@
 extern "C" {
 #endif
 
-#define CFC_URI_PARCEL      1
+#define CFC_URI_NULL        1
 #define CFC_URI_CLASS       2
 #define CFC_URI_FUNCTION    3
 #define CFC_URI_METHOD      4
-#define CFC_URI_NULL        5
+#define CFC_URI_DOCUMENT    5
 
 typedef struct CFCUri CFCUri;
 struct CFCClass;
+struct CFCDocument;
 
 int
 CFCUri_is_clownfish_uri(const char *uri);
@@ -42,20 +43,20 @@ CFCUri_init(CFCUri *self, const char *uri, struct CFCClass *klass);
 void
 CFCUri_destroy(CFCUri *self);
 
+const char*
+CFCUri_get_string(CFCUri *self);
+
 int
 CFCUri_get_type(CFCUri *self);
 
-const char*
-CFCUri_get_prefix(CFCUri *self);
-
-const char*
-CFCUri_get_struct_sym(CFCUri *self);
+struct CFCClass*
+CFCUri_get_class(CFCUri *self);
 
-const char*
-CFCUri_full_struct_sym(CFCUri *self);
+struct CFCDocument*
+CFCUri_get_document(CFCUri *self);
 
 const char*
-CFCUri_get_func_sym(CFCUri *self);
+CFCUri_get_callable_name(CFCUri *self);
 
 #ifdef __cplusplus
 }


[17/20] lucy-clownfish git commit: Create HTML docs for standalone documentation

Posted by nw...@apache.org.
Create HTML docs for standalone documentation


Project: http://git-wip-us.apache.org/repos/asf/lucy-clownfish/repo
Commit: http://git-wip-us.apache.org/repos/asf/lucy-clownfish/commit/d11a489f
Tree: http://git-wip-us.apache.org/repos/asf/lucy-clownfish/tree/d11a489f
Diff: http://git-wip-us.apache.org/repos/asf/lucy-clownfish/diff/d11a489f

Branch: refs/heads/master
Commit: d11a489f30e3f09bb1e85715353b53baaf39a67d
Parents: ea9281e
Author: Nick Wellnhofer <we...@aevum.de>
Authored: Sun Jul 26 00:58:47 2015 +0200
Committer: Nick Wellnhofer <we...@aevum.de>
Committed: Thu Aug 6 18:19:19 2015 +0200

----------------------------------------------------------------------
 compiler/src/CFCC.c               |  41 ++--
 compiler/src/CFCCHtml.c           | 390 ++++++++++++++++++++++++---------
 compiler/src/CFCCHtml.h           |   9 +-
 compiler/src/CFCTestDocuComment.c |  29 ++-
 4 files changed, 334 insertions(+), 135 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/lucy-clownfish/blob/d11a489f/compiler/src/CFCC.c
----------------------------------------------------------------------
diff --git a/compiler/src/CFCC.c b/compiler/src/CFCC.c
index ad7f882..aa1e267 100644
--- a/compiler/src/CFCC.c
+++ b/compiler/src/CFCC.c
@@ -25,6 +25,7 @@
 #include "CFCCHtml.h"
 #include "CFCCMan.h"
 #include "CFCClass.h"
+#include "CFCDocument.h"
 #include "CFCHierarchy.h"
 #include "CFCMethod.h"
 #include "CFCUri.h"
@@ -177,27 +178,39 @@ CFCC_link_text(CFCUri *uri_obj, CFCClass *klass) {
 
     switch (type) {
         case CFC_URI_CLASS: {
-            if (strcmp(CFCUri_get_prefix(uri_obj),
-                       CFCClass_get_prefix(klass)) == 0
-            ) {
-                // Same parcel.
-                const char *struct_sym = CFCUri_get_struct_sym(uri_obj);
-                link_text = CFCUtil_strdup(struct_sym);
-            }
-            else {
-                // Other parcel.
-                const char *full_struct_sym = CFCUri_full_struct_sym(uri_obj);
-                CFCClass *uri_class
-                    = CFCClass_fetch_by_struct_sym(full_struct_sym);
-                if (!uri_class) {
-                    CFCUtil_warn("URI class not found: %s", full_struct_sym);
+            const char *full_struct_sym = CFCUri_full_struct_sym(uri_obj);
+            CFCClass *uri_class = full_struct_sym
+                ? CFCClass_fetch_by_struct_sym(full_struct_sym)
+                : NULL;
+
+            if (uri_class) {
+                if (klass
+                    && strcmp(CFCClass_get_prefix(uri_class),
+                              CFCClass_get_prefix(klass)) == 0
+                ) {
+                    // Same parcel.
+                    const char *struct_sym = CFCUri_get_struct_sym(uri_obj);
+                    link_text = CFCUtil_strdup(struct_sym);
                 }
                 else {
+                    // Other parcel.
                     const char *class_name = CFCClass_get_name(uri_class);
                     link_text = CFCUtil_strdup(class_name);
                 }
+
+                break;
+            }
+
+            const char *struct_sym = CFCUri_get_struct_sym(uri_obj);
+            CFCDocument *doc = CFCDocument_fetch(struct_sym);
+
+            if (doc) {
+                const char *name = CFCDocument_get_name(doc);
+                link_text = CFCUtil_strdup(name);
+                break;
             }
 
+            CFCUtil_warn("Can't resolve Clownfish URI '%s'", struct_sym);
             break;
         }
 

http://git-wip-us.apache.org/repos/asf/lucy-clownfish/blob/d11a489f/compiler/src/CFCCHtml.c
----------------------------------------------------------------------
diff --git a/compiler/src/CFCCHtml.c b/compiler/src/CFCCHtml.c
index 02cc34e..3c953fe 100644
--- a/compiler/src/CFCCHtml.c
+++ b/compiler/src/CFCCHtml.c
@@ -28,6 +28,7 @@
 #include "CFCC.h"
 #include "CFCClass.h"
 #include "CFCDocuComment.h"
+#include "CFCDocument.h"
 #include "CFCFunction.h"
 #include "CFCHierarchy.h"
 #include "CFCMethod.h"
@@ -52,6 +53,7 @@ struct CFCCHtml {
     char *doc_path;
     char *header;
     char *footer;
+    char *index_filename;
 };
 
 static const CFCMeta CFCCHTML_META = {
@@ -113,11 +115,17 @@ static const char footer_template[] =
     "</html>\n"
     "{autogen_footer}";
 
+char*
+S_create_index_doc(CFCCHtml *self, CFCClass **classes, CFCDocument **docs);
+
+char*
+S_create_standalone_doc(CFCCHtml *self, CFCDocument *doc);
+
 static int
 S_compare_class_name(const void *va, const void *vb);
 
-static char*
-S_index_filename(CFCParcel *parcel);
+static int
+S_compare_doc_path(const void *va, const void *vb);
 
 static char*
 S_html_create_name(CFCClass *klass);
@@ -148,25 +156,29 @@ static char*
 S_html_create_inheritance(CFCClass *klass);
 
 static char*
-S_md_to_html(CFCClass *klass, const char *md);
+S_md_to_html(const char *md, CFCClass *klass, int dir_level);
 
 static void
-S_convert_uris(CFCClass *klass, cmark_node *node);
+S_convert_uris(cmark_node *node, CFCClass *klass, int dir_level);
 
 static void
-S_convert_uri(CFCClass *klass, cmark_node *link);
+S_convert_uri(cmark_node *link, CFCClass *klass, int dir_level);
 
 static char*
 S_type_to_html(CFCClass *klass, CFCType *type);
 
 static char*
-S_struct_sym_to_url(const char *struct_sym, CFCClass *base);
+S_cfc_uri_to_url(CFCUri *uri_obj, const char *uri_string, CFCClass *base,
+                 int dir_level);
 
 static char*
-S_class_to_url(CFCClass *klass, CFCClass *base);
+S_struct_sym_to_url(const char *struct_sym, CFCClass *base, int dir_level);
 
 static char*
-S_relative_url(const char *url, CFCClass *base);
+S_class_to_url(CFCClass *klass, CFCClass *base, int dir_level);
+
+static char*
+S_relative_url(const char *url, CFCClass *base, int dir_level);
 
 CFCCHtml*
 CFCCHtml_new(CFCHierarchy *hierarchy, const char *header, const char *footer) {
@@ -206,29 +218,36 @@ CFCCHtml_destroy(CFCCHtml *self) {
     FREEMEM(self->doc_path);
     FREEMEM(self->header);
     FREEMEM(self->footer);
+    FREEMEM(self->index_filename);
     CFCBase_destroy((CFCBase*)self);
 }
 
 void
 CFCCHtml_write_html_docs(CFCCHtml *self) {
-    CFCHierarchy  *hierarchy = self->hierarchy;
-    CFCClass     **ordered   = CFCHierarchy_ordered_classes(hierarchy);
-    CFCParcel    **parcels   = CFCParcel_all_parcels();
-    const char    *doc_path  = self->doc_path;
-
-    size_t num_parcels = 0;
-    for (size_t i = 0; parcels[i] != NULL; i++) {
-        ++num_parcels;
-    }
+    CFCHierarchy  *hierarchy    = self->hierarchy;
+    CFCClass     **ordered      = CFCHierarchy_ordered_classes(hierarchy);
+    CFCDocument  **doc_registry = CFCDocument_get_registry();
+    const char    *doc_path     = self->doc_path;
 
     size_t num_classes = 0;
     for (size_t i = 0; ordered[i] != NULL; i++) {
         ++num_classes;
     }
 
+    size_t num_md_docs = 0;
+    for (size_t i = 0; doc_registry[i] != NULL; i++) {
+        ++num_md_docs;
+    }
+
+    // Clone doc registry.
+    size_t bytes = (num_md_docs + 1) * sizeof(CFCDocument*);
+    CFCDocument **md_docs = (CFCDocument**)MALLOCATE(bytes);
+    memcpy(md_docs, doc_registry, bytes);
+
     qsort(ordered, num_classes, sizeof(*ordered), S_compare_class_name);
+    qsort(md_docs, num_md_docs, sizeof(*md_docs), S_compare_doc_path);
 
-    size_t   max_docs  = num_classes + num_parcels;
+    size_t   max_docs  = 1 + num_classes + num_md_docs;
     char   **filenames = (char**)CALLOCATE(max_docs, sizeof(char*));
     char   **html_docs = (char**)CALLOCATE(max_docs, sizeof(char*));
     size_t   num_docs  = 0;
@@ -237,16 +256,11 @@ CFCCHtml_write_html_docs(CFCCHtml *self) {
     // while generating the pages, we leak memory but don't clutter up the file
     // system.
 
-    for (size_t i = 0; parcels[i] != NULL; ++i) {
-        CFCParcel *parcel = parcels[i];
-        if (CFCParcel_included(parcel)) { continue; }
-
-        char *html = CFCCHtml_create_index_doc(self, parcel, ordered);
-        if (html != NULL) {
-            filenames[num_docs] = S_index_filename(parcel);
-            html_docs[num_docs] = html;
-            ++num_docs;
-        }
+    char *index_doc = S_create_index_doc(self, ordered, md_docs);
+    if (index_doc != NULL) {
+        filenames[num_docs] = CFCUtil_strdup(self->index_filename);
+        html_docs[num_docs] = index_doc;
+        num_docs++;
     }
 
     for (size_t i = 0; ordered[i] != NULL; i++) {
@@ -264,11 +278,23 @@ CFCCHtml_write_html_docs(CFCCHtml *self) {
         FREEMEM(path);
     }
 
+    for (size_t i = 0; md_docs[i] != NULL; i++) {
+        CFCDocument *md_doc = md_docs[i];
+        const char *path = CFCDocument_get_path_part(md_doc);
+        filenames[num_docs] = CFCUtil_sprintf("%s.html", path);
+        html_docs[num_docs] = S_create_standalone_doc(self, md_doc);
+        ++num_docs;
+    }
+
+    // Write out docs.
+
     for (size_t i = 0; i < num_docs; ++i) {
         char *filename = filenames[i];
         char *path     = CFCUtil_sprintf("%s" CHY_DIR_SEP "%s", doc_path,
                                          filename);
 
+        // Make path.
+
         char *dir  = CFCUtil_strdup(path);
         for (size_t j = strlen(dir); j--;) {
             if (dir[j] == CHY_DIR_SEP_CHAR) {
@@ -299,51 +325,165 @@ CFCCHtml_write_html_docs(CFCCHtml *self) {
 }
 
 char*
-CFCCHtml_create_index_doc(CFCCHtml *self, CFCParcel *parcel,
-                          CFCClass **classes) {
-    const char *prefix      = CFCParcel_get_prefix(parcel);
-    const char *parcel_name = CFCParcel_get_name(parcel);
-    char *class_list = CFCUtil_strdup("");
-
-    for (size_t i = 0; classes[i] != NULL; i++) {
-        CFCClass *klass = classes[i];
-        if (strcmp(CFCClass_get_prefix(klass), prefix) != 0
-            || !CFCClass_public(klass)
-        ) {
-            continue;
-        }
+S_create_index_doc(CFCCHtml *self, CFCClass **classes, CFCDocument **docs) {
+    CFCParcel **parcels = CFCParcel_all_parcels();
 
-        const char *class_name = CFCClass_get_name(klass);
-        char *url = S_class_to_url(klass, NULL);
-        class_list
-            = CFCUtil_cat(class_list, "<li><a href=\"", url, "\">",
-                          class_name, "</a></li>\n", NULL);
+    // Compile standalone document list.
+
+    char *doc_list = CFCUtil_strdup("");
+
+    for (size_t i = 0; docs[i] != NULL; i++) {
+        CFCDocument *doc = docs[i];
+
+        const char *path_part = CFCDocument_get_path_part(doc);
+        char *url  = CFCUtil_global_replace(path_part, CHY_DIR_SEP, "/");
+        char *name = CFCUtil_global_replace(path_part, CHY_DIR_SEP, "::"); 
+        doc_list
+            = CFCUtil_cat(doc_list, "<li><a href=\"", url, ".html\">",
+                          name, "</a></li>\n", NULL);
+        FREEMEM(name);
         FREEMEM(url);
     }
 
-    if (class_list[0] == '\0') {
+    if (doc_list[0] != '\0') {
+        const char *pattern =
+            "<h2>Documentation</h2>\n"
+            "<ul>\n"
+            "%s"
+            "</ul>\n";
+        char *contents = doc_list;
+        doc_list = CFCUtil_sprintf(pattern, contents);
+        FREEMEM(contents);
+    }
+
+    // Compile class lists per parcel.
+
+    char *class_lists    = CFCUtil_strdup("");
+    char *parcel_names   = CFCUtil_strdup("");
+    char *filename = CFCUtil_strdup("");
+
+    for (size_t i = 0; parcels[i]; i++) {
+        CFCParcel *parcel = parcels[i];
+        if (CFCParcel_included(parcel)) { continue; }
+
+        const char *prefix      = CFCParcel_get_prefix(parcel);
+        const char *parcel_name = CFCParcel_get_name(parcel);
+
+        char *class_list = CFCUtil_strdup("");
+
+        for (size_t i = 0; classes[i] != NULL; i++) {
+            CFCClass *klass = classes[i];
+            if (strcmp(CFCClass_get_prefix(klass), prefix) != 0
+                || !CFCClass_public(klass)
+            ) {
+                continue;
+            }
+
+            const char *class_name = CFCClass_get_name(klass);
+            char *url = S_class_to_url(klass, NULL, 0);
+            class_list
+                = CFCUtil_cat(class_list, "<li><a href=\"", url, "\">",
+                              class_name, "</a></li>\n", NULL);
+            FREEMEM(url);
+        }
+
+        if (class_list[0] != '\0') {
+            const char *pattern =
+                "<h2>Classes in parcel %s</h2>\n"
+                "<ul>\n"
+                "%s"
+                "</ul>\n";
+            char *html = CFCUtil_sprintf(pattern, parcel_name, class_list);
+            class_lists = CFCUtil_cat(class_lists, html, NULL);
+            FREEMEM(html);
+
+            const char *parcel_name = CFCParcel_get_name(parcel);
+            const char *sep = parcel_names[0] == '\0' ? "" : ", ";
+            parcel_names = CFCUtil_cat(parcel_names, sep, parcel_name, NULL);
+
+            const char *parcel_prefix = CFCParcel_get_prefix(parcel);
+            filename = CFCUtil_cat(filename, parcel_prefix, NULL);
+        }
+
         FREEMEM(class_list);
-        return NULL;
     }
 
-    char *title
-        = CFCUtil_sprintf("%s " UTF8_NDASH " C API Index", parcel_name);
+    // Create doc.
+
+    char *title  = CFCUtil_sprintf("%s " UTF8_NDASH " C API Index",
+                                   parcel_names);
     char *header = CFCUtil_global_replace(self->header, "{title}", title);
 
     const char pattern[] =
         "%s"
         "<h1>%s</h1>\n"
-        "<ul>\n"
         "%s"
-        "</ul>\n"
+        "%s"
         "%s";
-    char *html_doc
-        = CFCUtil_sprintf(pattern, header, title, class_list, self->footer);
+    char *doc
+        = CFCUtil_sprintf(pattern, header, title, doc_list, class_lists,
+                          self->footer);
+
+    // Create filename
+
+    if (filename[0] == '\0') {
+        for (size_t i = 0; parcels[i]; i++) {
+            CFCParcel *parcel = parcels[i];
+            if (CFCParcel_included(parcel)) { continue; }
+            const char *prefix = CFCParcel_get_prefix(parcel);
+            filename = CFCUtil_cat(filename, prefix, NULL);
+        }
+    }
+
+    char *retval = NULL;
+
+    if (filename[0] != '\0') {
+        // Removing trailing underscore.
+        size_t filename_len = strlen(filename);
+        filename[filename_len-1] = '\0';
+
+        // Add .html extension.
+        char *base = filename;
+        filename = CFCUtil_sprintf("%s.html", base);
+        FREEMEM(base);
+
+        retval = doc;
+        doc    = NULL;
+
+        FREEMEM(self->index_filename);
+        self->index_filename = filename;
+        filename             = NULL;
+    }
 
+    FREEMEM(doc);
     FREEMEM(header);
     FREEMEM(title);
-    FREEMEM(class_list);
+    FREEMEM(filename);
+    FREEMEM(parcel_names);
+    FREEMEM(class_lists);
+    FREEMEM(doc_list);
+
+    return retval;
+}
+
+char*
+S_create_standalone_doc(CFCCHtml *self, CFCDocument *doc) {
+    const char *path = CFCDocument_get_path_part(doc);
+    char *title  = CFCUtil_global_replace(path, CHY_DIR_SEP, "::");
+    char *header = CFCUtil_global_replace(self->header, "{title}", title);
 
+    const char *md = CFCDocument_get_contents(doc);
+    int dir_level = 0;
+    for (size_t i = 0; path[i]; i++) {
+        if (path[i] == CHY_DIR_SEP_CHAR) { ++dir_level; }
+    }
+    char *body = S_md_to_html(md, NULL, dir_level);
+
+    char *html_doc = CFCUtil_sprintf("%s%s%s", header, body, self->footer);
+
+    FREEMEM(body);
+    FREEMEM(header);
+    FREEMEM(title);
     return html_doc;
 }
 
@@ -353,7 +493,7 @@ CFCCHtml_create_html_doc(CFCCHtml *self, CFCClass *klass) {
     char *title
         = CFCUtil_sprintf("%s " UTF8_NDASH " C API Documentation", class_name);
     char *header = CFCUtil_global_replace(self->header, "{title}", title);
-    char *body = CFCCHtml_create_html_body(klass);
+    char *body = CFCCHtml_create_html_body(self, klass);
 
     char *html_doc = CFCUtil_sprintf("%s%s%s", header, body, self->footer);
 
@@ -364,7 +504,20 @@ CFCCHtml_create_html_doc(CFCCHtml *self, CFCClass *klass) {
 }
 
 char*
-CFCCHtml_create_html_body(CFCClass *klass) {
+CFCCHtml_create_html_body(CFCCHtml *self, CFCClass *klass) {
+    if (self->index_filename == NULL) {
+        // Create index filename by creating index doc.
+        CFCClass    **ordered = CFCHierarchy_ordered_classes(self->hierarchy);
+        CFCDocument **docs    = CFCDocument_get_registry();
+        char *index_doc = S_create_index_doc(self, ordered, docs);
+        FREEMEM(index_doc);
+        FREEMEM(ordered);
+
+        if (self->index_filename == NULL) {
+            CFCUtil_die("Empty hierarchy");
+        }
+    }
+
     CFCParcel  *parcel         = CFCClass_get_parcel(klass);
     const char *parcel_name    = CFCParcel_get_name(parcel);
     const char *prefix         = CFCClass_get_prefix(klass);
@@ -393,8 +546,7 @@ CFCCHtml_create_html_body(CFCClass *klass) {
     // Build an INHERITANCE section describing class ancestry.
     char *inheritance = S_html_create_inheritance(klass);
 
-    char *index_filename = S_index_filename(parcel);
-    char *index_url      = S_relative_url(index_filename, klass);
+    char *index_url = S_relative_url(self->index_filename, klass, 0);
 
     // Put it all together.
     const char pattern[] =
@@ -435,7 +587,6 @@ CFCCHtml_create_html_body(CFCClass *klass) {
                           inheritance);
 
     FREEMEM(index_url);
-    FREEMEM(index_filename);
     FREEMEM(name);
     FREEMEM(synopsis);
     FREEMEM(description);
@@ -454,15 +605,12 @@ S_compare_class_name(const void *va, const void *vb) {
     return strcmp(a, b);
 }
 
-static char*
-S_index_filename(CFCParcel *parcel) {
-    char *nickname = CFCUtil_strdup(CFCParcel_get_nickname(parcel));
-    for (size_t i = 0; nickname[i]; ++i) {
-        nickname[i] = tolower(nickname[i]);
-    }
-    char *filename = CFCUtil_sprintf("%s.html", nickname);
-    FREEMEM(nickname);
-    return filename;
+static int
+S_compare_doc_path(const void *va, const void *vb) {
+    const char *a = CFCDocument_get_path_part(*(CFCDocument**)va);
+    const char *b = CFCDocument_get_path_part(*(CFCDocument**)vb);
+
+    return strcmp(a, b);
 }
 
 static char*
@@ -478,7 +626,7 @@ S_html_create_name(CFCClass *klass) {
         }
     }
 
-    char *html = S_md_to_html(klass, md);
+    char *html = S_md_to_html(md, klass, 0);
 
     const char *format =
         "<h2>Name</h2>\n"
@@ -504,7 +652,7 @@ S_html_create_description(CFCClass *klass) {
     if (docucom) {
         const char *raw_desc = CFCDocuComment_get_long(docucom);
         if (raw_desc && raw_desc[0] != '\0') {
-            desc = S_md_to_html(klass, raw_desc);
+            desc = S_md_to_html(raw_desc, klass, 0);
         }
     }
 
@@ -675,7 +823,7 @@ S_html_create_func(CFCClass *klass, CFCFunction *func, const char *prefix,
     if (docucomment) {
         // Description
         const char *raw_desc = CFCDocuComment_get_description(docucomment);
-        char *desc = S_md_to_html(klass, raw_desc);
+        char *desc = S_md_to_html(raw_desc, klass, 0);
         result = CFCUtil_cat(result, desc, NULL);
         FREEMEM(desc);
 
@@ -687,7 +835,7 @@ S_html_create_func(CFCClass *klass, CFCFunction *func, const char *prefix,
         if (param_names[0]) {
             result = CFCUtil_cat(result, "<dl>\n", NULL);
             for (size_t i = 0; param_names[i] != NULL; i++) {
-                char *doc = S_md_to_html(klass, param_docs[i]);
+                char *doc = S_md_to_html(param_docs[i], klass, 0);
                 result = CFCUtil_cat(result, "<dt>", param_names[i],
                                      "</dt>\n<dd>", doc, "</dd>\n",
                                      NULL);
@@ -700,7 +848,7 @@ S_html_create_func(CFCClass *klass, CFCFunction *func, const char *prefix,
         const char *retval_doc = CFCDocuComment_get_retval(docucomment);
         if (retval_doc && strlen(retval_doc)) {
             char *md = CFCUtil_sprintf("**Returns:** %s", retval_doc);
-            char *html = S_md_to_html(klass, md);
+            char *html = S_md_to_html(md, klass, 0);
             result = CFCUtil_cat(result, html, NULL);
             FREEMEM(html);
             FREEMEM(md);
@@ -774,7 +922,7 @@ S_html_create_inheritance(CFCClass *klass) {
                          NULL);
     while (ancestor) {
         const char *ancestor_name = CFCClass_get_name(ancestor);
-        char *ancestor_url = S_class_to_url(ancestor, klass);
+        char *ancestor_url = S_class_to_url(ancestor, klass, 0);
         result = CFCUtil_cat(result, " is a <a href=\"", ancestor_url, "\">",
                              ancestor_name, "</a>", NULL);
         FREEMEM(ancestor_url);
@@ -786,12 +934,12 @@ S_html_create_inheritance(CFCClass *klass) {
 }
 
 static char*
-S_md_to_html(CFCClass *klass, const char *md) {
+S_md_to_html(const char *md, CFCClass *klass, int dir_level) {
     int options = CMARK_OPT_SMART
                   | CMARK_OPT_VALIDATE_UTF8
                   | CMARK_OPT_SAFE;
     cmark_node *doc = cmark_parse_document(md, strlen(md), options);
-    S_convert_uris(klass, doc);
+    S_convert_uris(doc, klass, dir_level);
     char *html = cmark_render_html(doc, CMARK_OPT_DEFAULT);
     cmark_node_free(doc);
 
@@ -799,7 +947,7 @@ S_md_to_html(CFCClass *klass, const char *md) {
 }
 
 static void
-S_convert_uris(CFCClass *klass, cmark_node *node) {
+S_convert_uris(cmark_node *node, CFCClass *klass, int dir_level) {
     cmark_iter *iter = cmark_iter_new(node);
     cmark_event_type ev_type;
 
@@ -809,7 +957,7 @@ S_convert_uris(CFCClass *klass, cmark_node *node) {
         if (ev_type == CMARK_EVENT_EXIT
             && cmark_node_get_type(cur) == NODE_LINK
         ) {
-            S_convert_uri(klass, cur);
+            S_convert_uri(cur, klass, dir_level);
         }
     }
 
@@ -817,28 +965,27 @@ S_convert_uris(CFCClass *klass, cmark_node *node) {
 }
 
 static void
-S_convert_uri(CFCClass *klass, cmark_node *link) {
-    const char *uri = cmark_node_get_url(link);
-    if (!uri || !CFCUri_is_clownfish_uri(uri)) {
+S_convert_uri(cmark_node *link, CFCClass *klass, int dir_level) {
+    const char *uri_string = cmark_node_get_url(link);
+    if (!uri_string || !CFCUri_is_clownfish_uri(uri_string)) {
         return;
     }
 
     char   *new_uri = NULL;
-    CFCUri *uri_obj = CFCUri_new(uri, klass);
+    CFCUri *uri_obj = CFCUri_new(uri_string, klass);
     int     type    = CFCUri_get_type(uri_obj);
 
     switch (type) {
         case CFC_URI_CLASS: {
-            const char *struct_sym = CFCUri_full_struct_sym(uri_obj);
-            new_uri = S_struct_sym_to_url(struct_sym, klass);
+            new_uri = S_cfc_uri_to_url(uri_obj, uri_string, klass, dir_level);
             break;
         }
 
         case CFC_URI_FUNCTION:
         case CFC_URI_METHOD: {
-            const char *struct_sym = CFCUri_full_struct_sym(uri_obj);
-            const char *func_sym   = CFCUri_get_func_sym(uri_obj);
-            char *url = S_struct_sym_to_url(struct_sym, klass);
+            const char *func_sym = CFCUri_get_func_sym(uri_obj);
+            char *url = S_cfc_uri_to_url(uri_obj, uri_string, klass,
+                                         dir_level);
             new_uri = CFCUtil_sprintf("%s#func_%s", url, func_sym);
             FREEMEM(url);
             break;
@@ -895,7 +1042,7 @@ S_type_to_html(CFCClass *klass, CFCType *type) {
                                          prefix, type_c + offset);
             }
             else {
-                char *url = S_struct_sym_to_url(specifier, klass);
+                char *url = S_struct_sym_to_url(specifier, klass, 0);
                 const char *pattern =
                     "<span class=\"prefix\">%s</span>"
                     "<a href=\"%s\">%s</a>";
@@ -912,25 +1059,57 @@ S_type_to_html(CFCClass *klass, CFCType *type) {
     return CFCUtil_strdup(type_c);
 }
 
+// Return a relative URL for a CFCUri object.
+static char*
+S_cfc_uri_to_url(CFCUri *uri_obj, const char *uri_string, CFCClass *base,
+                 int dir_level) {
+    const char *full_struct_sym = CFCUri_full_struct_sym(uri_obj);
+    CFCClass *klass = full_struct_sym
+                      ? CFCClass_fetch_by_struct_sym(full_struct_sym)
+                      : NULL;
+
+    if (klass) {
+        return S_struct_sym_to_url(full_struct_sym, base, dir_level);
+    }
+
+    const char *struct_sym = CFCUri_get_struct_sym(uri_obj);
+    CFCDocument *doc = CFCDocument_fetch(struct_sym);
+
+    if (doc) {
+        const char *path_part = CFCDocument_get_path_part(doc);
+        char *slashy  = CFCUtil_global_replace(path_part, CHY_DIR_SEP, "/");
+        char *url     = CFCUtil_sprintf("%s.html", slashy);
+        char *rel_url = S_relative_url(url, base, dir_level);
+
+        FREEMEM(url);
+        FREEMEM(slashy);
+        return rel_url;
+    }
+
+    CFCUtil_warn("No class or document found for URI '%s'",
+                 uri_string);
+    return CFCUtil_strdup("not_found.html");
+}
+
 // Return a relative URL to the class with full struct sym `struct_sym`.
 static char*
-S_struct_sym_to_url(const char *struct_sym, CFCClass *base) {
+S_struct_sym_to_url(const char *struct_sym, CFCClass *base, int dir_level) {
     if (!struct_sym) { return CFCUtil_strdup("not_found.html"); }
 
     CFCClass *klass = CFCClass_fetch_by_struct_sym(struct_sym);
 
-    return S_class_to_url(klass, base);
+    return S_class_to_url(klass, base, dir_level);
 }
 
 // Return a relative URL to a class.
 static char*
-S_class_to_url(CFCClass *klass, CFCClass *base) {
+S_class_to_url(CFCClass *klass, CFCClass *base, int dir_level) {
     if (!klass) { return CFCUtil_strdup("not_found.html"); }
 
     const char *class_name = CFCClass_get_name(klass);
     char *path    = CFCUtil_global_replace(class_name, "::", CHY_DIR_SEP);
     char *url     = CFCUtil_sprintf("%s.html", path);
-    char *rel_url = S_relative_url(url, base);
+    char *rel_url = S_relative_url(url, base, dir_level);
 
     FREEMEM(url);
     FREEMEM(path);
@@ -938,19 +1117,24 @@ S_class_to_url(CFCClass *klass, CFCClass *base) {
 }
 
 static char*
-S_relative_url(const char *url, CFCClass *base) {
-    if (base == NULL) { return CFCUtil_strdup(url); }
+S_relative_url(const char *url, CFCClass *base, int dir_level) {
+    if (base) {
+        const char *base_name = CFCClass_get_name(base);
+        for (size_t i = 0; base_name[i]; i++) {
+            if (base_name[i] == ':' && base_name[i+1] == ':') {
+                dir_level++;
+                i++;
+            }
+        }
+    }
 
     // Create path back to root
-    char *prefix = CFCUtil_strdup("");
-    const char *base_name = CFCClass_get_name(base);
-
-    for (size_t i = 0; base_name[i]; i++) {
-        if (base_name[i] == ':' && base_name[i+1] == ':') {
-            prefix = CFCUtil_cat(prefix, "../", NULL);
-            i++;
-        }
+    size_t bytes = dir_level * 3;
+    char *prefix = (char*)MALLOCATE(bytes + 1);
+    for (size_t i = 0; i < bytes; i += 3) {
+        memcpy(prefix + i, "../", 3);
     }
+    prefix[bytes] = '\0';
 
     char *rel_url = CFCUtil_sprintf("%s%s", prefix, url);
 

http://git-wip-us.apache.org/repos/asf/lucy-clownfish/blob/d11a489f/compiler/src/CFCCHtml.h
----------------------------------------------------------------------
diff --git a/compiler/src/CFCCHtml.h b/compiler/src/CFCCHtml.h
index 41f46fc..3e095d5 100644
--- a/compiler/src/CFCCHtml.h
+++ b/compiler/src/CFCCHtml.h
@@ -51,20 +51,13 @@ CFCCHtml_destroy(CFCCHtml *self);
 void
 CFCCHtml_write_html_docs(CFCCHtml *self);
 
-/** Return the index document of the HTML documentation for `parcel`
- * or NULL if there aren't any public classes in the parcel.
- */
-char*
-CFCCHtml_create_index_doc(CFCCHtml *self, struct CFCParcel *parcel,
-                          struct CFCClass **classes);
-
 /** Return the HTML documentation for the class.
  */
 char*
 CFCCHtml_create_html_doc(CFCCHtml *self, struct CFCClass *klass);
 
 char*
-CFCCHtml_create_html_body(struct CFCClass *klass);
+CFCCHtml_create_html_body(CFCCHtml *self, struct CFCClass *klass);
 
 #ifdef __cplusplus
 }

http://git-wip-us.apache.org/repos/asf/lucy-clownfish/blob/d11a489f/compiler/src/CFCTestDocuComment.c
----------------------------------------------------------------------
diff --git a/compiler/src/CFCTestDocuComment.c b/compiler/src/CFCTestDocuComment.c
index 99bcc95..2baf6c9 100644
--- a/compiler/src/CFCTestDocuComment.c
+++ b/compiler/src/CFCTestDocuComment.c
@@ -20,6 +20,7 @@
 #include "CFCCHtml.h"
 #include "CFCCMan.h"
 #include "CFCClass.h"
+#include "CFCHierarchy.h"
 #include "CFCParcel.h"
 #include "CFCParser.h"
 #include "CFCPerlClass.h"
@@ -118,7 +119,10 @@ S_test_parser(CFCTest *test) {
 
 static void
 S_test_generator(CFCTest *test) {
+    CFCHierarchy *hierarchy = CFCHierarchy_new("autogen");
     CFCParcel *parcel = CFCParcel_new("Neato", NULL, NULL, NULL);
+    CFCParcel_register(parcel);
+
     CFCDocuComment *docu = CFCDocuComment_parse(
         "/** Test documentation generator.\n"
         " * \n"
@@ -182,29 +186,30 @@ S_test_generator(CFCTest *test) {
         "Paragraph after list\n";
     STR_EQ(test, man_page, expected_man, "create man page");
 
-    char *html = CFCCHtml_create_html_body(klass);
+    CFCCHtml *chtml = CFCCHtml_new(hierarchy, "", "");
+    char *html = CFCCHtml_create_html_body(chtml, klass);
     const char *expected_html =
         "<h1>Neato::Object</h1>\n"
         "<table>\n"
         "<tr>\n"
         "<td class=\"label\">parcel</td>\n"
-        "<td><a href=\"neato.html\">Neato</a></td>\n"
+        "<td><a href=\"../neato.html\">Neato</a></td>\n"
         "</tr>\n"
         "<tr>\n"
-        "<td class=\"label\">class name</td>\n"
-        "<td>Neato::Object</td>\n"
+        "<td class=\"label\">class variable</td>\n"
+        "<td><code><span class=\"prefix\">NEATO_</span>OBJECT</code></td>\n"
         "</tr>\n"
         "<tr>\n"
-        "<td class=\"label\">class nickname</td>\n"
-        "<td>Object</td>\n"
+        "<td class=\"label\">struct symbol</td>\n"
+        "<td><code><span class=\"prefix\">neato_</span>Object</code></td>\n"
         "</tr>\n"
         "<tr>\n"
-        "<td class=\"label\">class variable</td>\n"
-        "<td><code>NEATO_OBJECT</code></td>\n"
+        "<td class=\"label\">class nickname</td>\n"
+        "<td><code><span class=\"prefix\">neato_</span>Object</code></td>\n"
         "</tr>\n"
         "<tr>\n"
-        "<td class=\"label\">struct symbol</td>\n"
-        "<td><code>neato_Object</code></td>\n"
+        "<td class=\"label\">header file</td>\n"
+        "<td><code>class.h</code></td>\n"
         "</tr>\n"
         "</table>\n"
         "<h2>Name</h2>\n"
@@ -286,10 +291,14 @@ S_test_generator(CFCTest *test) {
     CFCBase_decref((CFCBase*)perl_pod);
     CFCBase_decref((CFCBase*)perl_class);
     FREEMEM(html);
+    CFCBase_decref((CFCBase*)chtml);
     FREEMEM(man_page);
     CFCBase_decref((CFCBase*)klass);
     CFCBase_decref((CFCBase*)docu);
     CFCBase_decref((CFCBase*)parcel);
+    CFCBase_decref((CFCBase*)hierarchy);
+
+    CFCParcel_reap_singletons();
 }
 
 static void


[13/20] lucy-clownfish git commit: Show header file of a class in HTML docs

Posted by nw...@apache.org.
Show header file of a class in HTML docs


Project: http://git-wip-us.apache.org/repos/asf/lucy-clownfish/repo
Commit: http://git-wip-us.apache.org/repos/asf/lucy-clownfish/commit/6c9b0edd
Tree: http://git-wip-us.apache.org/repos/asf/lucy-clownfish/tree/6c9b0edd
Diff: http://git-wip-us.apache.org/repos/asf/lucy-clownfish/diff/6c9b0edd

Branch: refs/heads/master
Commit: 6c9b0edd6468133ce2fa3331c2f38978d508f024
Parents: 3518fa0
Author: Nick Wellnhofer <we...@aevum.de>
Authored: Sat Jul 25 19:08:07 2015 +0200
Committer: Nick Wellnhofer <we...@aevum.de>
Committed: Thu Aug 6 18:19:19 2015 +0200

----------------------------------------------------------------------
 compiler/src/CFCCHtml.c | 7 ++++++-
 1 file changed, 6 insertions(+), 1 deletion(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/lucy-clownfish/blob/6c9b0edd/compiler/src/CFCCHtml.c
----------------------------------------------------------------------
diff --git a/compiler/src/CFCCHtml.c b/compiler/src/CFCCHtml.c
index 95fb27f..e320ad9 100644
--- a/compiler/src/CFCCHtml.c
+++ b/compiler/src/CFCCHtml.c
@@ -347,6 +347,7 @@ CFCCHtml_create_html_body(CFCClass *klass) {
     const char *class_nickname = CFCClass_get_nickname(klass);
     const char *class_var      = CFCClass_full_class_var(klass);
     const char *struct_sym     = CFCClass_full_struct_sym(klass);
+    const char *include_h      = CFCClass_include_h(klass);
 
     // Create NAME.
     char *name = S_html_create_name(klass);
@@ -392,6 +393,10 @@ CFCCHtml_create_html_body(CFCClass *klass) {
         "<td class=\"label\">struct symbol</td>\n"
         "<td><code>%s</code></td>\n"
         "</tr>\n"
+        "<tr>\n"
+        "<td class=\"label\">header file</td>\n"
+        "<td><code>%s</code></td>\n"
+        "</tr>\n"
         "</table>\n"
         "%s"
         "%s"
@@ -402,7 +407,7 @@ CFCCHtml_create_html_body(CFCClass *klass) {
     char *html_body
         = CFCUtil_sprintf(pattern, class_name, index_filename,
                           parcel_name, class_name, class_nickname, class_var,
-                          struct_sym, name, synopsis, description,
+                          struct_sym, include_h, name, synopsis, description,
                           functions_html, methods_html, inheritance);
 
     FREEMEM(index_filename);


[08/20] lucy-clownfish git commit: Upgrade libcmark to 0.21.0

Posted by nw...@apache.org.
http://git-wip-us.apache.org/repos/asf/lucy-clownfish/blob/89c7b809/compiler/modules/CommonMark/src/houdini.h
----------------------------------------------------------------------
diff --git a/compiler/modules/CommonMark/src/houdini.h b/compiler/modules/CommonMark/src/houdini.h
index 9f00f6d..b926cf3 100644
--- a/compiler/modules/CommonMark/src/houdini.h
+++ b/compiler/modules/CommonMark/src/houdini.h
@@ -31,19 +31,12 @@ extern "C" {
 #define HOUDINI_ESCAPED_SIZE(x) (((x) * 12) / 10)
 #define HOUDINI_UNESCAPED_SIZE(x) (x)
 
-extern size_t houdini_unescape_ent(cmark_strbuf *ob, const uint8_t *src, size_t size);
-extern int houdini_escape_html(cmark_strbuf *ob, const uint8_t *src, size_t size);
-extern int houdini_escape_html0(cmark_strbuf *ob, const uint8_t *src, size_t size, int secure);
-extern int houdini_unescape_html(cmark_strbuf *ob, const uint8_t *src, size_t size);
-extern void houdini_unescape_html_f(cmark_strbuf *ob, const uint8_t *src, size_t size);
-extern int houdini_escape_xml(cmark_strbuf *ob, const uint8_t *src, size_t size);
-extern int houdini_escape_uri(cmark_strbuf *ob, const uint8_t *src, size_t size);
-extern int houdini_escape_url(cmark_strbuf *ob, const uint8_t *src, size_t size);
-extern int houdini_escape_href(cmark_strbuf *ob, const uint8_t *src, size_t size);
-extern int houdini_unescape_uri(cmark_strbuf *ob, const uint8_t *src, size_t size);
-extern int houdini_unescape_url(cmark_strbuf *ob, const uint8_t *src, size_t size);
-extern int houdini_escape_js(cmark_strbuf *ob, const uint8_t *src, size_t size);
-extern int houdini_unescape_js(cmark_strbuf *ob, const uint8_t *src, size_t size);
+extern bufsize_t houdini_unescape_ent(cmark_strbuf *ob, const uint8_t *src, bufsize_t size);
+extern int houdini_escape_html(cmark_strbuf *ob, const uint8_t *src, bufsize_t size);
+extern int houdini_escape_html0(cmark_strbuf *ob, const uint8_t *src, bufsize_t size, int secure);
+extern int houdini_unescape_html(cmark_strbuf *ob, const uint8_t *src, bufsize_t size);
+extern void houdini_unescape_html_f(cmark_strbuf *ob, const uint8_t *src, bufsize_t size);
+extern int houdini_escape_href(cmark_strbuf *ob, const uint8_t *src, bufsize_t size);
 
 #ifdef __cplusplus
 }

http://git-wip-us.apache.org/repos/asf/lucy-clownfish/blob/89c7b809/compiler/modules/CommonMark/src/houdini_href_e.c
----------------------------------------------------------------------
diff --git a/compiler/modules/CommonMark/src/houdini_href_e.c b/compiler/modules/CommonMark/src/houdini_href_e.c
index 7527780..7fb958a 100644
--- a/compiler/modules/CommonMark/src/houdini_href_e.c
+++ b/compiler/modules/CommonMark/src/houdini_href_e.c
@@ -49,10 +49,10 @@ static const char HREF_SAFE[] = {
 };
 
 int
-houdini_escape_href(cmark_strbuf *ob, const uint8_t *src, size_t size)
+houdini_escape_href(cmark_strbuf *ob, const uint8_t *src, bufsize_t size)
 {
 	static const uint8_t hex_chars[] = "0123456789ABCDEF";
-	size_t  i = 0, org;
+	bufsize_t i = 0, org;
 	uint8_t hex_str[3];
 
 	hex_str[0] = '%';

http://git-wip-us.apache.org/repos/asf/lucy-clownfish/blob/89c7b809/compiler/modules/CommonMark/src/houdini_html_e.c
----------------------------------------------------------------------
diff --git a/compiler/modules/CommonMark/src/houdini_html_e.c b/compiler/modules/CommonMark/src/houdini_html_e.c
index 1a4c3e1..7f4b91f 100644
--- a/compiler/modules/CommonMark/src/houdini_html_e.c
+++ b/compiler/modules/CommonMark/src/houdini_html_e.c
@@ -45,9 +45,9 @@ static const char *HTML_ESCAPES[] = {
 };
 
 int
-houdini_escape_html0(cmark_strbuf *ob, const uint8_t *src, size_t size, int secure)
+houdini_escape_html0(cmark_strbuf *ob, const uint8_t *src, bufsize_t size, int secure)
 {
-	size_t  i = 0, org, esc = 0;
+	bufsize_t i = 0, org, esc = 0;
 
 	while (i < size) {
 		org = i;
@@ -75,7 +75,7 @@ houdini_escape_html0(cmark_strbuf *ob, const uint8_t *src, size_t size, int secu
 }
 
 int
-houdini_escape_html(cmark_strbuf *ob, const uint8_t *src, size_t size)
+houdini_escape_html(cmark_strbuf *ob, const uint8_t *src, bufsize_t size)
 {
 	return houdini_escape_html0(ob, src, size, 1);
 }

http://git-wip-us.apache.org/repos/asf/lucy-clownfish/blob/89c7b809/compiler/modules/CommonMark/src/houdini_html_u.c
----------------------------------------------------------------------
diff --git a/compiler/modules/CommonMark/src/houdini_html_u.c b/compiler/modules/CommonMark/src/houdini_html_u.c
index ecd7faa..002357d 100644
--- a/compiler/modules/CommonMark/src/houdini_html_u.c
+++ b/compiler/modules/CommonMark/src/houdini_html_u.c
@@ -5,58 +5,98 @@
 #include "buffer.h"
 #include "houdini.h"
 #include "utf8.h"
-#include "html_unescape.h"
+#include "entities.inc"
 
-size_t
-houdini_unescape_ent(cmark_strbuf *ob, const uint8_t *src, size_t size)
+/* Binary tree lookup code for entities added by JGM */
+
+static unsigned char *
+S_lookup(int i, int low, int hi, const unsigned char *s, int len)
 {
-	size_t i = 0;
+	int j;
+	int cmp = strncmp((char *)s, (char *)cmark_entities[i].entity, len);
+	if (cmp == 0 && cmark_entities[i].entity[len] == 0) {
+		return (unsigned char *)cmark_entities[i].bytes;
+	} else if (cmp < 0 && i > low) {
+		j = i - ((i - low) / 2);
+		if (j == i) j -= 1;
+		return S_lookup(j, low, i - 1, s, len);
+	} else if (cmp > 0 && i < hi) {
+		j = i + ((hi - i) / 2);
+		if (j == i) j += 1;
+		return S_lookup(j, i + 1, hi, s, len);
+	} else {
+		return NULL;
+	}
+}
 
-	if (size > 3 && src[0] == '#') {
-		int codepoint = 0;
+static unsigned char *
+S_lookup_entity(const unsigned char *s, int len)
+{
+	return S_lookup(CMARK_NUM_ENTITIES / 2, 0, CMARK_NUM_ENTITIES - 1, s, len);
+}
+
+bufsize_t
+houdini_unescape_ent(cmark_strbuf *ob, const uint8_t *src, bufsize_t size)
+{
+	bufsize_t i = 0;
+
+	if (size >= 3 && src[0] == '#') {
+		int codepoint  = 0;
+		int num_digits = 0;
 
 		if (_isdigit(src[1])) {
 			for (i = 1; i < size && _isdigit(src[i]); ++i) {
-				int cp = (codepoint * 10) + (src[i] - '0');
+				codepoint = (codepoint * 10) + (src[i] - '0');
 
-				if (cp < codepoint)
-					return 0;
-
-				codepoint = cp;
+				if (codepoint >= 0x110000) {
+					// Keep counting digits but
+					// avoid integer overflow.
+					codepoint = 0x110000;
+				}
 			}
+
+			num_digits = i - 1;
 		}
 
 		else if (src[1] == 'x' || src[1] == 'X') {
 			for (i = 2; i < size && _isxdigit(src[i]); ++i) {
-				int cp = (codepoint * 16) + ((src[i] | 32) % 39 - 9);
-
-				if (cp < codepoint)
-					return 0;
+				codepoint = (codepoint * 16) + ((src[i] | 32) % 39 - 9);
 
-				codepoint = cp;
+				if (codepoint >= 0x110000) {
+					// Keep counting digits but
+					// avoid integer overflow.
+					codepoint = 0x110000;
+				}
 			}
+
+			num_digits = i - 2;
 		}
 
-		if (i < size && src[i] == ';' && codepoint) {
+		if (num_digits >= 1 && num_digits <= 8 &&
+		    i < size && src[i] == ';') {
+			if (codepoint == 0 ||
+			    (codepoint >= 0xD800 && codepoint < 0xE000) ||
+			    codepoint >= 0x110000) {
+				codepoint = 0xFFFD;
+			}
 			utf8proc_encode_char(codepoint, ob);
 			return i + 1;
 		}
 	}
 
 	else {
-		if (size > MAX_WORD_LENGTH)
-			size = MAX_WORD_LENGTH;
+		if (size > CMARK_ENTITY_MAX_LENGTH)
+			size = CMARK_ENTITY_MAX_LENGTH;
 
-		for (i = MIN_WORD_LENGTH; i < size; ++i) {
+		for (i = CMARK_ENTITY_MIN_LENGTH; i < size; ++i) {
 			if (src[i] == ' ')
 				break;
 
 			if (src[i] == ';') {
-				const struct html_ent *entity = find_entity((char *)src, i);
+				const unsigned char *entity = S_lookup_entity(src, i);
 
 				if (entity != NULL) {
-					size_t len = strnlen((const char *)entity->utf8, 4);
-					cmark_strbuf_put(ob, entity->utf8, len);
+					cmark_strbuf_puts(ob, (const char *)entity);
 					return i + 1;
 				}
 
@@ -69,9 +109,9 @@ houdini_unescape_ent(cmark_strbuf *ob, const uint8_t *src, size_t size)
 }
 
 int
-houdini_unescape_html(cmark_strbuf *ob, const uint8_t *src, size_t size)
+houdini_unescape_html(cmark_strbuf *ob, const uint8_t *src, bufsize_t size)
 {
-	size_t  i = 0, org, ent;
+	bufsize_t i = 0, org, ent;
 
 	while (i < size) {
 		org = i;
@@ -106,7 +146,7 @@ houdini_unescape_html(cmark_strbuf *ob, const uint8_t *src, size_t size)
 	return 1;
 }
 
-void houdini_unescape_html_f(cmark_strbuf *ob, const uint8_t *src, size_t size)
+void houdini_unescape_html_f(cmark_strbuf *ob, const uint8_t *src, bufsize_t size)
 {
 	if (!houdini_unescape_html(ob, src, size))
 		cmark_strbuf_put(ob, src, size);

http://git-wip-us.apache.org/repos/asf/lucy-clownfish/blob/89c7b809/compiler/modules/CommonMark/src/html.c
----------------------------------------------------------------------
diff --git a/compiler/modules/CommonMark/src/html.c b/compiler/modules/CommonMark/src/html.c
index abc3e83..c6bbea6 100644
--- a/compiler/modules/CommonMark/src/html.c
+++ b/compiler/modules/CommonMark/src/html.c
@@ -2,29 +2,19 @@
 #include <stdio.h>
 #include <string.h>
 #include <assert.h>
-
+#include "cmark_ctype.h"
 #include "config.h"
 #include "cmark.h"
 #include "node.h"
 #include "buffer.h"
 #include "houdini.h"
+#include "scanners.h"
 
 // Functions to convert cmark_nodes to HTML strings.
 
-static void escape_html(cmark_strbuf *dest, const unsigned char *source, int length)
-{
-	if (length < 0)
-		length = strlen((char *)source);
-
-	houdini_escape_html0(dest, source, (size_t)length, 0);
-}
-
-static void escape_href(cmark_strbuf *dest, const unsigned char *source, int length)
+static void escape_html(cmark_strbuf *dest, const unsigned char *source, bufsize_t length)
 {
-	if (length < 0)
-		length = strlen((char *)source);
-
-	houdini_escape_href(dest, source, (size_t)length);
+	houdini_escape_html0(dest, source, length, 0);
 }
 
 static inline void cr(cmark_strbuf *html)
@@ -39,7 +29,7 @@ struct render_state {
 };
 
 static void
-S_render_sourcepos(cmark_node *node, cmark_strbuf *html, long options)
+S_render_sourcepos(cmark_node *node, cmark_strbuf *html, int options)
 {
 	if (CMARK_OPT_SOURCEPOS & options) {
 		cmark_strbuf_printf(html, " data-sourcepos=\"%d:%d-%d:%d\"",
@@ -52,7 +42,7 @@ S_render_sourcepos(cmark_node *node, cmark_strbuf *html, long options)
 
 static int
 S_render_node(cmark_node *node, cmark_event_type ev_type,
-              struct render_state *state, long options)
+              struct render_state *state, int options)
 {
 	cmark_node *parent;
 	cmark_node *grandparent;
@@ -165,9 +155,9 @@ S_render_node(cmark_node *node, cmark_event_type ev_type,
 			S_render_sourcepos(node, html, options);
 			cmark_strbuf_puts(html, "><code>");
 		} else {
-			int first_tag = 0;
+			bufsize_t first_tag = 0;
 			while (first_tag < node->as.code.info.len &&
-			       node->as.code.info.data[first_tag] != ' ') {
+			       !cmark_isspace(node->as.code.info.data[first_tag])) {
 				first_tag += 1;
 			}
 
@@ -185,7 +175,13 @@ S_render_node(cmark_node *node, cmark_event_type ev_type,
 
 	case CMARK_NODE_HTML:
 		cr(html);
-		cmark_strbuf_put(html, node->as.literal.data, node->as.literal.len);
+		if (options & CMARK_OPT_SAFE) {
+			cmark_strbuf_puts(html, "<!-- raw HTML omitted -->");
+		} else {
+			cmark_strbuf_put(html, node->as.literal.data,
+			                 node->as.literal.len);
+		}
+		cr(html);
 		break;
 
 	case CMARK_NODE_HRULE:
@@ -217,8 +213,7 @@ S_render_node(cmark_node *node, cmark_event_type ev_type,
 		break;
 
 	case CMARK_NODE_TEXT:
-		escape_html(html, node->as.literal.data,
-		            node->as.literal.len);
+		escape_html(html, node->as.literal.data, node->as.literal.len);
 		break;
 
 	case CMARK_NODE_LINEBREAK:
@@ -240,7 +235,12 @@ S_render_node(cmark_node *node, cmark_event_type ev_type,
 		break;
 
 	case CMARK_NODE_INLINE_HTML:
-		cmark_strbuf_put(html, node->as.literal.data, node->as.literal.len);
+		if (options & CMARK_OPT_SAFE) {
+			cmark_strbuf_puts(html, "<!-- raw HTML omitted -->");
+		} else {
+			cmark_strbuf_put(html, node->as.literal.data,
+			                 node->as.literal.len);
+		}
 		break;
 
 	case CMARK_NODE_STRONG:
@@ -262,14 +262,19 @@ S_render_node(cmark_node *node, cmark_event_type ev_type,
 	case CMARK_NODE_LINK:
 		if (entering) {
 			cmark_strbuf_puts(html, "<a href=\"");
-			if (node->as.link.url)
-				escape_href(html, node->as.link.url, -1);
+			if (!((options & CMARK_OPT_SAFE) &&
+			      scan_dangerous_url(&node->as.link.url, 0))) {
+				houdini_escape_href(html,
+				                    node->as.link.url.data,
+				                    node->as.link.url.len);
 
-			if (node->as.link.title) {
+			}
+			if (node->as.link.title.len) {
 				cmark_strbuf_puts(html, "\" title=\"");
-				escape_html(html, node->as.link.title, -1);
+				escape_html(html,
+				            node->as.link.title.data,
+				            node->as.link.title.len);
 			}
-
 			cmark_strbuf_puts(html, "\">");
 		} else {
 			cmark_strbuf_puts(html, "</a>");
@@ -279,15 +284,20 @@ S_render_node(cmark_node *node, cmark_event_type ev_type,
 	case CMARK_NODE_IMAGE:
 		if (entering) {
 			cmark_strbuf_puts(html, "<img src=\"");
-			if (node->as.link.url)
-				escape_href(html, node->as.link.url, -1);
+			if (!((options & CMARK_OPT_SAFE) &&
+			      scan_dangerous_url(&node->as.link.url, 0))) {
+				houdini_escape_href(html,
+				                    node->as.link.url.data,
+				                    node->as.link.url.len);
 
+			}
 			cmark_strbuf_puts(html, "\" alt=\"");
 			state->plain = node;
 		} else {
-			if (node->as.link.title) {
+			if (node->as.link.title.len) {
 				cmark_strbuf_puts(html, "\" title=\"");
-				escape_html(html, node->as.link.title, -1);
+				escape_html(html, node->as.link.title.data,
+				            node->as.link.title.len);
 			}
 
 			cmark_strbuf_puts(html, "\" />");
@@ -303,7 +313,7 @@ S_render_node(cmark_node *node, cmark_event_type ev_type,
 	return 1;
 }
 
-char *cmark_render_html(cmark_node *root, long options)
+char *cmark_render_html(cmark_node *root, int options)
 {
 	char *result;
 	cmark_strbuf html = GH_BUF_INIT;
@@ -319,6 +329,5 @@ char *cmark_render_html(cmark_node *root, long options)
 	result = (char *)cmark_strbuf_detach(&html);
 
 	cmark_iter_free(iter);
-	cmark_strbuf_free(&html);
 	return result;
 }

http://git-wip-us.apache.org/repos/asf/lucy-clownfish/blob/89c7b809/compiler/modules/CommonMark/src/html_unescape.gperf
----------------------------------------------------------------------
diff --git a/compiler/modules/CommonMark/src/html_unescape.gperf b/compiler/modules/CommonMark/src/html_unescape.gperf
deleted file mode 100644
index 74173a6..0000000
--- a/compiler/modules/CommonMark/src/html_unescape.gperf
+++ /dev/null
@@ -1,2130 +0,0 @@
-struct html_ent {
-	int entity;
-	unsigned char utf8[4];
-};
-%%
-"Aacute", {195, 129, 0}
-"aacute", {195, 161, 0}
-"Abreve", {196, 130, 0}
-"abreve", {196, 131, 0}
-"ac", {226, 136, 190, 0}
-"acd", {226, 136, 191, 0}
-"acE", {226, 136, 190, 0}
-"Acirc", {195, 130, 0}
-"acirc", {195, 162, 0}
-"acute", {194, 180, 0}
-"Acy", {208, 144, 0}
-"acy", {208, 176, 0}
-"AElig", {195, 134, 0}
-"aelig", {195, 166, 0}
-"af", {226, 129, 161, 0}
-"Afr", {240, 157, 148, 132}
-"afr", {240, 157, 148, 158}
-"Agrave", {195, 128, 0}
-"agrave", {195, 160, 0}
-"alefsym", {226, 132, 181, 0}
-"aleph", {226, 132, 181, 0}
-"Alpha", {206, 145, 0}
-"alpha", {206, 177, 0}
-"Amacr", {196, 128, 0}
-"amacr", {196, 129, 0}
-"amalg", {226, 168, 191, 0}
-"amp", {38, 0}
-"AMP", {38, 0}
-"andand", {226, 169, 149, 0}
-"And", {226, 169, 147, 0}
-"and", {226, 136, 167, 0}
-"andd", {226, 169, 156, 0}
-"andslope", {226, 169, 152, 0}
-"andv", {226, 169, 154, 0}
-"ang", {226, 136, 160, 0}
-"ange", {226, 166, 164, 0}
-"angle", {226, 136, 160, 0}
-"angmsdaa", {226, 166, 168, 0}
-"angmsdab", {226, 166, 169, 0}
-"angmsdac", {226, 166, 170, 0}
-"angmsdad", {226, 166, 171, 0}
-"angmsdae", {226, 166, 172, 0}
-"angmsdaf", {226, 166, 173, 0}
-"angmsdag", {226, 166, 174, 0}
-"angmsdah", {226, 166, 175, 0}
-"angmsd", {226, 136, 161, 0}
-"angrt", {226, 136, 159, 0}
-"angrtvb", {226, 138, 190, 0}
-"angrtvbd", {226, 166, 157, 0}
-"angsph", {226, 136, 162, 0}
-"angst", {195, 133, 0}
-"angzarr", {226, 141, 188, 0}
-"Aogon", {196, 132, 0}
-"aogon", {196, 133, 0}
-"Aopf", {240, 157, 148, 184}
-"aopf", {240, 157, 149, 146}
-"apacir", {226, 169, 175, 0}
-"ap", {226, 137, 136, 0}
-"apE", {226, 169, 176, 0}
-"ape", {226, 137, 138, 0}
-"apid", {226, 137, 139, 0}
-"apos", {39, 0}
-"ApplyFunction", {226, 129, 161, 0}
-"approx", {226, 137, 136, 0}
-"approxeq", {226, 137, 138, 0}
-"Aring", {195, 133, 0}
-"aring", {195, 165, 0}
-"Ascr", {240, 157, 146, 156}
-"ascr", {240, 157, 146, 182}
-"Assign", {226, 137, 148, 0}
-"ast", {42, 0}
-"asymp", {226, 137, 136, 0}
-"asympeq", {226, 137, 141, 0}
-"Atilde", {195, 131, 0}
-"atilde", {195, 163, 0}
-"Auml", {195, 132, 0}
-"auml", {195, 164, 0}
-"awconint", {226, 136, 179, 0}
-"awint", {226, 168, 145, 0}
-"backcong", {226, 137, 140, 0}
-"backepsilon", {207, 182, 0}
-"backprime", {226, 128, 181, 0}
-"backsim", {226, 136, 189, 0}
-"backsimeq", {226, 139, 141, 0}
-"Backslash", {226, 136, 150, 0}
-"Barv", {226, 171, 167, 0}
-"barvee", {226, 138, 189, 0}
-"barwed", {226, 140, 133, 0}
-"Barwed", {226, 140, 134, 0}
-"barwedge", {226, 140, 133, 0}
-"bbrk", {226, 142, 181, 0}
-"bbrktbrk", {226, 142, 182, 0}
-"bcong", {226, 137, 140, 0}
-"Bcy", {208, 145, 0}
-"bcy", {208, 177, 0}
-"bdquo", {226, 128, 158, 0}
-"becaus", {226, 136, 181, 0}
-"because", {226, 136, 181, 0}
-"Because", {226, 136, 181, 0}
-"bemptyv", {226, 166, 176, 0}
-"bepsi", {207, 182, 0}
-"bernou", {226, 132, 172, 0}
-"Bernoullis", {226, 132, 172, 0}
-"Beta", {206, 146, 0}
-"beta", {206, 178, 0}
-"beth", {226, 132, 182, 0}
-"between", {226, 137, 172, 0}
-"Bfr", {240, 157, 148, 133}
-"bfr", {240, 157, 148, 159}
-"bigcap", {226, 139, 130, 0}
-"bigcirc", {226, 151, 175, 0}
-"bigcup", {226, 139, 131, 0}
-"bigodot", {226, 168, 128, 0}
-"bigoplus", {226, 168, 129, 0}
-"bigotimes", {226, 168, 130, 0}
-"bigsqcup", {226, 168, 134, 0}
-"bigstar", {226, 152, 133, 0}
-"bigtriangledown", {226, 150, 189, 0}
-"bigtriangleup", {226, 150, 179, 0}
-"biguplus", {226, 168, 132, 0}
-"bigvee", {226, 139, 129, 0}
-"bigwedge", {226, 139, 128, 0}
-"bkarow", {226, 164, 141, 0}
-"blacklozenge", {226, 167, 171, 0}
-"blacksquare", {226, 150, 170, 0}
-"blacktriangle", {226, 150, 180, 0}
-"blacktriangledown", {226, 150, 190, 0}
-"blacktriangleleft", {226, 151, 130, 0}
-"blacktriangleright", {226, 150, 184, 0}
-"blank", {226, 144, 163, 0}
-"blk12", {226, 150, 146, 0}
-"blk14", {226, 150, 145, 0}
-"blk34", {226, 150, 147, 0}
-"block", {226, 150, 136, 0}
-"bne", {61, 0}
-"bnequiv", {226, 137, 161, 0}
-"bNot", {226, 171, 173, 0}
-"bnot", {226, 140, 144, 0}
-"Bopf", {240, 157, 148, 185}
-"bopf", {240, 157, 149, 147}
-"bot", {226, 138, 165, 0}
-"bottom", {226, 138, 165, 0}
-"bowtie", {226, 139, 136, 0}
-"boxbox", {226, 167, 137, 0}
-"boxdl", {226, 148, 144, 0}
-"boxdL", {226, 149, 149, 0}
-"boxDl", {226, 149, 150, 0}
-"boxDL", {226, 149, 151, 0}
-"boxdr", {226, 148, 140, 0}
-"boxdR", {226, 149, 146, 0}
-"boxDr", {226, 149, 147, 0}
-"boxDR", {226, 149, 148, 0}
-"boxh", {226, 148, 128, 0}
-"boxH", {226, 149, 144, 0}
-"boxhd", {226, 148, 172, 0}
-"boxHd", {226, 149, 164, 0}
-"boxhD", {226, 149, 165, 0}
-"boxHD", {226, 149, 166, 0}
-"boxhu", {226, 148, 180, 0}
-"boxHu", {226, 149, 167, 0}
-"boxhU", {226, 149, 168, 0}
-"boxHU", {226, 149, 169, 0}
-"boxminus", {226, 138, 159, 0}
-"boxplus", {226, 138, 158, 0}
-"boxtimes", {226, 138, 160, 0}
-"boxul", {226, 148, 152, 0}
-"boxuL", {226, 149, 155, 0}
-"boxUl", {226, 149, 156, 0}
-"boxUL", {226, 149, 157, 0}
-"boxur", {226, 148, 148, 0}
-"boxuR", {226, 149, 152, 0}
-"boxUr", {226, 149, 153, 0}
-"boxUR", {226, 149, 154, 0}
-"boxv", {226, 148, 130, 0}
-"boxV", {226, 149, 145, 0}
-"boxvh", {226, 148, 188, 0}
-"boxvH", {226, 149, 170, 0}
-"boxVh", {226, 149, 171, 0}
-"boxVH", {226, 149, 172, 0}
-"boxvl", {226, 148, 164, 0}
-"boxvL", {226, 149, 161, 0}
-"boxVl", {226, 149, 162, 0}
-"boxVL", {226, 149, 163, 0}
-"boxvr", {226, 148, 156, 0}
-"boxvR", {226, 149, 158, 0}
-"boxVr", {226, 149, 159, 0}
-"boxVR", {226, 149, 160, 0}
-"bprime", {226, 128, 181, 0}
-"breve", {203, 152, 0}
-"Breve", {203, 152, 0}
-"brvbar", {194, 166, 0}
-"bscr", {240, 157, 146, 183}
-"Bscr", {226, 132, 172, 0}
-"bsemi", {226, 129, 143, 0}
-"bsim", {226, 136, 189, 0}
-"bsime", {226, 139, 141, 0}
-"bsolb", {226, 167, 133, 0}
-"bsol", {92, 0}
-"bsolhsub", {226, 159, 136, 0}
-"bull", {226, 128, 162, 0}
-"bullet", {226, 128, 162, 0}
-"bump", {226, 137, 142, 0}
-"bumpE", {226, 170, 174, 0}
-"bumpe", {226, 137, 143, 0}
-"Bumpeq", {226, 137, 142, 0}
-"bumpeq", {226, 137, 143, 0}
-"Cacute", {196, 134, 0}
-"cacute", {196, 135, 0}
-"capand", {226, 169, 132, 0}
-"capbrcup", {226, 169, 137, 0}
-"capcap", {226, 169, 139, 0}
-"cap", {226, 136, 169, 0}
-"Cap", {226, 139, 146, 0}
-"capcup", {226, 169, 135, 0}
-"capdot", {226, 169, 128, 0}
-"CapitalDifferentialD", {226, 133, 133, 0}
-"caps", {226, 136, 169, 0}
-"caret", {226, 129, 129, 0}
-"caron", {203, 135, 0}
-"Cayleys", {226, 132, 173, 0}
-"ccaps", {226, 169, 141, 0}
-"Ccaron", {196, 140, 0}
-"ccaron", {196, 141, 0}
-"Ccedil", {195, 135, 0}
-"ccedil", {195, 167, 0}
-"Ccirc", {196, 136, 0}
-"ccirc", {196, 137, 0}
-"Cconint", {226, 136, 176, 0}
-"ccups", {226, 169, 140, 0}
-"ccupssm", {226, 169, 144, 0}
-"Cdot", {196, 138, 0}
-"cdot", {196, 139, 0}
-"cedil", {194, 184, 0}
-"Cedilla", {194, 184, 0}
-"cemptyv", {226, 166, 178, 0}
-"cent", {194, 162, 0}
-"centerdot", {194, 183, 0}
-"CenterDot", {194, 183, 0}
-"cfr", {240, 157, 148, 160}
-"Cfr", {226, 132, 173, 0}
-"CHcy", {208, 167, 0}
-"chcy", {209, 135, 0}
-"check", {226, 156, 147, 0}
-"checkmark", {226, 156, 147, 0}
-"Chi", {206, 167, 0}
-"chi", {207, 135, 0}
-"circ", {203, 134, 0}
-"circeq", {226, 137, 151, 0}
-"circlearrowleft", {226, 134, 186, 0}
-"circlearrowright", {226, 134, 187, 0}
-"circledast", {226, 138, 155, 0}
-"circledcirc", {226, 138, 154, 0}
-"circleddash", {226, 138, 157, 0}
-"CircleDot", {226, 138, 153, 0}
-"circledR", {194, 174, 0}
-"circledS", {226, 147, 136, 0}
-"CircleMinus", {226, 138, 150, 0}
-"CirclePlus", {226, 138, 149, 0}
-"CircleTimes", {226, 138, 151, 0}
-"cir", {226, 151, 139, 0}
-"cirE", {226, 167, 131, 0}
-"cire", {226, 137, 151, 0}
-"cirfnint", {226, 168, 144, 0}
-"cirmid", {226, 171, 175, 0}
-"cirscir", {226, 167, 130, 0}
-"ClockwiseContourIntegral", {226, 136, 178, 0}
-"CloseCurlyDoubleQuote", {226, 128, 157, 0}
-"CloseCurlyQuote", {226, 128, 153, 0}
-"clubs", {226, 153, 163, 0}
-"clubsuit", {226, 153, 163, 0}
-"colon", {58, 0}
-"Colon", {226, 136, 183, 0}
-"Colone", {226, 169, 180, 0}
-"colone", {226, 137, 148, 0}
-"coloneq", {226, 137, 148, 0}
-"comma", {44, 0}
-"commat", {64, 0}
-"comp", {226, 136, 129, 0}
-"compfn", {226, 136, 152, 0}
-"complement", {226, 136, 129, 0}
-"complexes", {226, 132, 130, 0}
-"cong", {226, 137, 133, 0}
-"congdot", {226, 169, 173, 0}
-"Congruent", {226, 137, 161, 0}
-"conint", {226, 136, 174, 0}
-"Conint", {226, 136, 175, 0}
-"ContourIntegral", {226, 136, 174, 0}
-"copf", {240, 157, 149, 148}
-"Copf", {226, 132, 130, 0}
-"coprod", {226, 136, 144, 0}
-"Coproduct", {226, 136, 144, 0}
-"copy", {194, 169, 0}
-"COPY", {194, 169, 0}
-"copysr", {226, 132, 151, 0}
-"CounterClockwiseContourIntegral", {226, 136, 179, 0}
-"crarr", {226, 134, 181, 0}
-"cross", {226, 156, 151, 0}
-"Cross", {226, 168, 175, 0}
-"Cscr", {240, 157, 146, 158}
-"cscr", {240, 157, 146, 184}
-"csub", {226, 171, 143, 0}
-"csube", {226, 171, 145, 0}
-"csup", {226, 171, 144, 0}
-"csupe", {226, 171, 146, 0}
-"ctdot", {226, 139, 175, 0}
-"cudarrl", {226, 164, 184, 0}
-"cudarrr", {226, 164, 181, 0}
-"cuepr", {226, 139, 158, 0}
-"cuesc", {226, 139, 159, 0}
-"cularr", {226, 134, 182, 0}
-"cularrp", {226, 164, 189, 0}
-"cupbrcap", {226, 169, 136, 0}
-"cupcap", {226, 169, 134, 0}
-"CupCap", {226, 137, 141, 0}
-"cup", {226, 136, 170, 0}
-"Cup", {226, 139, 147, 0}
-"cupcup", {226, 169, 138, 0}
-"cupdot", {226, 138, 141, 0}
-"cupor", {226, 169, 133, 0}
-"cups", {226, 136, 170, 0}
-"curarr", {226, 134, 183, 0}
-"curarrm", {226, 164, 188, 0}
-"curlyeqprec", {226, 139, 158, 0}
-"curlyeqsucc", {226, 139, 159, 0}
-"curlyvee", {226, 139, 142, 0}
-"curlywedge", {226, 139, 143, 0}
-"curren", {194, 164, 0}
-"curvearrowleft", {226, 134, 182, 0}
-"curvearrowright", {226, 134, 183, 0}
-"cuvee", {226, 139, 142, 0}
-"cuwed", {226, 139, 143, 0}
-"cwconint", {226, 136, 178, 0}
-"cwint", {226, 136, 177, 0}
-"cylcty", {226, 140, 173, 0}
-"dagger", {226, 128, 160, 0}
-"Dagger", {226, 128, 161, 0}
-"daleth", {226, 132, 184, 0}
-"darr", {226, 134, 147, 0}
-"Darr", {226, 134, 161, 0}
-"dArr", {226, 135, 147, 0}
-"dash", {226, 128, 144, 0}
-"Dashv", {226, 171, 164, 0}
-"dashv", {226, 138, 163, 0}
-"dbkarow", {226, 164, 143, 0}
-"dblac", {203, 157, 0}
-"Dcaron", {196, 142, 0}
-"dcaron", {196, 143, 0}
-"Dcy", {208, 148, 0}
-"dcy", {208, 180, 0}
-"ddagger", {226, 128, 161, 0}
-"ddarr", {226, 135, 138, 0}
-"DD", {226, 133, 133, 0}
-"dd", {226, 133, 134, 0}
-"DDotrahd", {226, 164, 145, 0}
-"ddotseq", {226, 169, 183, 0}
-"deg", {194, 176, 0}
-"Del", {226, 136, 135, 0}
-"Delta", {206, 148, 0}
-"delta", {206, 180, 0}
-"demptyv", {226, 166, 177, 0}
-"dfisht", {226, 165, 191, 0}
-"Dfr", {240, 157, 148, 135}
-"dfr", {240, 157, 148, 161}
-"dHar", {226, 165, 165, 0}
-"dharl", {226, 135, 131, 0}
-"dharr", {226, 135, 130, 0}
-"DiacriticalAcute", {194, 180, 0}
-"DiacriticalDot", {203, 153, 0}
-"DiacriticalDoubleAcute", {203, 157, 0}
-"DiacriticalGrave", {96, 0}
-"DiacriticalTilde", {203, 156, 0}
-"diam", {226, 139, 132, 0}
-"diamond", {226, 139, 132, 0}
-"Diamond", {226, 139, 132, 0}
-"diamondsuit", {226, 153, 166, 0}
-"diams", {226, 153, 166, 0}
-"die", {194, 168, 0}
-"DifferentialD", {226, 133, 134, 0}
-"digamma", {207, 157, 0}
-"disin", {226, 139, 178, 0}
-"div", {195, 183, 0}
-"divide", {195, 183, 0}
-"divideontimes", {226, 139, 135, 0}
-"divonx", {226, 139, 135, 0}
-"DJcy", {208, 130, 0}
-"djcy", {209, 146, 0}
-"dlcorn", {226, 140, 158, 0}
-"dlcrop", {226, 140, 141, 0}
-"dollar", {36, 0}
-"Dopf", {240, 157, 148, 187}
-"dopf", {240, 157, 149, 149}
-"Dot", {194, 168, 0}
-"dot", {203, 153, 0}
-"DotDot", {226, 131, 156, 0}
-"doteq", {226, 137, 144, 0}
-"doteqdot", {226, 137, 145, 0}
-"DotEqual", {226, 137, 144, 0}
-"dotminus", {226, 136, 184, 0}
-"dotplus", {226, 136, 148, 0}
-"dotsquare", {226, 138, 161, 0}
-"doublebarwedge", {226, 140, 134, 0}
-"DoubleContourIntegral", {226, 136, 175, 0}
-"DoubleDot", {194, 168, 0}
-"DoubleDownArrow", {226, 135, 147, 0}
-"DoubleLeftArrow", {226, 135, 144, 0}
-"DoubleLeftRightArrow", {226, 135, 148, 0}
-"DoubleLeftTee", {226, 171, 164, 0}
-"DoubleLongLeftArrow", {226, 159, 184, 0}
-"DoubleLongLeftRightArrow", {226, 159, 186, 0}
-"DoubleLongRightArrow", {226, 159, 185, 0}
-"DoubleRightArrow", {226, 135, 146, 0}
-"DoubleRightTee", {226, 138, 168, 0}
-"DoubleUpArrow", {226, 135, 145, 0}
-"DoubleUpDownArrow", {226, 135, 149, 0}
-"DoubleVerticalBar", {226, 136, 165, 0}
-"DownArrowBar", {226, 164, 147, 0}
-"downarrow", {226, 134, 147, 0}
-"DownArrow", {226, 134, 147, 0}
-"Downarrow", {226, 135, 147, 0}
-"DownArrowUpArrow", {226, 135, 181, 0}
-"DownBreve", {204, 145, 0}
-"downdownarrows", {226, 135, 138, 0}
-"downharpoonleft", {226, 135, 131, 0}
-"downharpoonright", {226, 135, 130, 0}
-"DownLeftRightVector", {226, 165, 144, 0}
-"DownLeftTeeVector", {226, 165, 158, 0}
-"DownLeftVectorBar", {226, 165, 150, 0}
-"DownLeftVector", {226, 134, 189, 0}
-"DownRightTeeVector", {226, 165, 159, 0}
-"DownRightVectorBar", {226, 165, 151, 0}
-"DownRightVector", {226, 135, 129, 0}
-"DownTeeArrow", {226, 134, 167, 0}
-"DownTee", {226, 138, 164, 0}
-"drbkarow", {226, 164, 144, 0}
-"drcorn", {226, 140, 159, 0}
-"drcrop", {226, 140, 140, 0}
-"Dscr", {240, 157, 146, 159}
-"dscr", {240, 157, 146, 185}
-"DScy", {208, 133, 0}
-"dscy", {209, 149, 0}
-"dsol", {226, 167, 182, 0}
-"Dstrok", {196, 144, 0}
-"dstrok", {196, 145, 0}
-"dtdot", {226, 139, 177, 0}
-"dtri", {226, 150, 191, 0}
-"dtrif", {226, 150, 190, 0}
-"duarr", {226, 135, 181, 0}
-"duhar", {226, 165, 175, 0}
-"dwangle", {226, 166, 166, 0}
-"DZcy", {208, 143, 0}
-"dzcy", {209, 159, 0}
-"dzigrarr", {226, 159, 191, 0}
-"Eacute", {195, 137, 0}
-"eacute", {195, 169, 0}
-"easter", {226, 169, 174, 0}
-"Ecaron", {196, 154, 0}
-"ecaron", {196, 155, 0}
-"Ecirc", {195, 138, 0}
-"ecirc", {195, 170, 0}
-"ecir", {226, 137, 150, 0}
-"ecolon", {226, 137, 149, 0}
-"Ecy", {208, 173, 0}
-"ecy", {209, 141, 0}
-"eDDot", {226, 169, 183, 0}
-"Edot", {196, 150, 0}
-"edot", {196, 151, 0}
-"eDot", {226, 137, 145, 0}
-"ee", {226, 133, 135, 0}
-"efDot", {226, 137, 146, 0}
-"Efr", {240, 157, 148, 136}
-"efr", {240, 157, 148, 162}
-"eg", {226, 170, 154, 0}
-"Egrave", {195, 136, 0}
-"egrave", {195, 168, 0}
-"egs", {226, 170, 150, 0}
-"egsdot", {226, 170, 152, 0}
-"el", {226, 170, 153, 0}
-"Element", {226, 136, 136, 0}
-"elinters", {226, 143, 167, 0}
-"ell", {226, 132, 147, 0}
-"els", {226, 170, 149, 0}
-"elsdot", {226, 170, 151, 0}
-"Emacr", {196, 146, 0}
-"emacr", {196, 147, 0}
-"empty", {226, 136, 133, 0}
-"emptyset", {226, 136, 133, 0}
-"EmptySmallSquare", {226, 151, 187, 0}
-"emptyv", {226, 136, 133, 0}
-"EmptyVerySmallSquare", {226, 150, 171, 0}
-"emsp13", {226, 128, 132, 0}
-"emsp14", {226, 128, 133, 0}
-"emsp", {226, 128, 131, 0}
-"ENG", {197, 138, 0}
-"eng", {197, 139, 0}
-"ensp", {226, 128, 130, 0}
-"Eogon", {196, 152, 0}
-"eogon", {196, 153, 0}
-"Eopf", {240, 157, 148, 188}
-"eopf", {240, 157, 149, 150}
-"epar", {226, 139, 149, 0}
-"eparsl", {226, 167, 163, 0}
-"eplus", {226, 169, 177, 0}
-"epsi", {206, 181, 0}
-"Epsilon", {206, 149, 0}
-"epsilon", {206, 181, 0}
-"epsiv", {207, 181, 0}
-"eqcirc", {226, 137, 150, 0}
-"eqcolon", {226, 137, 149, 0}
-"eqsim", {226, 137, 130, 0}
-"eqslantgtr", {226, 170, 150, 0}
-"eqslantless", {226, 170, 149, 0}
-"Equal", {226, 169, 181, 0}
-"equals", {61, 0}
-"EqualTilde", {226, 137, 130, 0}
-"equest", {226, 137, 159, 0}
-"Equilibrium", {226, 135, 140, 0}
-"equiv", {226, 137, 161, 0}
-"equivDD", {226, 169, 184, 0}
-"eqvparsl", {226, 167, 165, 0}
-"erarr", {226, 165, 177, 0}
-"erDot", {226, 137, 147, 0}
-"escr", {226, 132, 175, 0}
-"Escr", {226, 132, 176, 0}
-"esdot", {226, 137, 144, 0}
-"Esim", {226, 169, 179, 0}
-"esim", {226, 137, 130, 0}
-"Eta", {206, 151, 0}
-"eta", {206, 183, 0}
-"ETH", {195, 144, 0}
-"eth", {195, 176, 0}
-"Euml", {195, 139, 0}
-"euml", {195, 171, 0}
-"euro", {226, 130, 172, 0}
-"excl", {33, 0}
-"exist", {226, 136, 131, 0}
-"Exists", {226, 136, 131, 0}
-"expectation", {226, 132, 176, 0}
-"exponentiale", {226, 133, 135, 0}
-"ExponentialE", {226, 133, 135, 0}
-"fallingdotseq", {226, 137, 146, 0}
-"Fcy", {208, 164, 0}
-"fcy", {209, 132, 0}
-"female", {226, 153, 128, 0}
-"ffilig", {239, 172, 131, 0}
-"fflig", {239, 172, 128, 0}
-"ffllig", {239, 172, 132, 0}
-"Ffr", {240, 157, 148, 137}
-"ffr", {240, 157, 148, 163}
-"filig", {239, 172, 129, 0}
-"FilledSmallSquare", {226, 151, 188, 0}
-"FilledVerySmallSquare", {226, 150, 170, 0}
-"fjlig", {102, 0}
-"flat", {226, 153, 173, 0}
-"fllig", {239, 172, 130, 0}
-"fltns", {226, 150, 177, 0}
-"fnof", {198, 146, 0}
-"Fopf", {240, 157, 148, 189}
-"fopf", {240, 157, 149, 151}
-"forall", {226, 136, 128, 0}
-"ForAll", {226, 136, 128, 0}
-"fork", {226, 139, 148, 0}
-"forkv", {226, 171, 153, 0}
-"Fouriertrf", {226, 132, 177, 0}
-"fpartint", {226, 168, 141, 0}
-"frac12", {194, 189, 0}
-"frac13", {226, 133, 147, 0}
-"frac14", {194, 188, 0}
-"frac15", {226, 133, 149, 0}
-"frac16", {226, 133, 153, 0}
-"frac18", {226, 133, 155, 0}
-"frac23", {226, 133, 148, 0}
-"frac25", {226, 133, 150, 0}
-"frac34", {194, 190, 0}
-"frac35", {226, 133, 151, 0}
-"frac38", {226, 133, 156, 0}
-"frac45", {226, 133, 152, 0}
-"frac56", {226, 133, 154, 0}
-"frac58", {226, 133, 157, 0}
-"frac78", {226, 133, 158, 0}
-"frasl", {226, 129, 132, 0}
-"frown", {226, 140, 162, 0}
-"fscr", {240, 157, 146, 187}
-"Fscr", {226, 132, 177, 0}
-"gacute", {199, 181, 0}
-"Gamma", {206, 147, 0}
-"gamma", {206, 179, 0}
-"Gammad", {207, 156, 0}
-"gammad", {207, 157, 0}
-"gap", {226, 170, 134, 0}
-"Gbreve", {196, 158, 0}
-"gbreve", {196, 159, 0}
-"Gcedil", {196, 162, 0}
-"Gcirc", {196, 156, 0}
-"gcirc", {196, 157, 0}
-"Gcy", {208, 147, 0}
-"gcy", {208, 179, 0}
-"Gdot", {196, 160, 0}
-"gdot", {196, 161, 0}
-"ge", {226, 137, 165, 0}
-"gE", {226, 137, 167, 0}
-"gEl", {226, 170, 140, 0}
-"gel", {226, 139, 155, 0}
-"geq", {226, 137, 165, 0}
-"geqq", {226, 137, 167, 0}
-"geqslant", {226, 169, 190, 0}
-"gescc", {226, 170, 169, 0}
-"ges", {226, 169, 190, 0}
-"gesdot", {226, 170, 128, 0}
-"gesdoto", {226, 170, 130, 0}
-"gesdotol", {226, 170, 132, 0}
-"gesl", {226, 139, 155, 0}
-"gesles", {226, 170, 148, 0}
-"Gfr", {240, 157, 148, 138}
-"gfr", {240, 157, 148, 164}
-"gg", {226, 137, 171, 0}
-"Gg", {226, 139, 153, 0}
-"ggg", {226, 139, 153, 0}
-"gimel", {226, 132, 183, 0}
-"GJcy", {208, 131, 0}
-"gjcy", {209, 147, 0}
-"gla", {226, 170, 165, 0}
-"gl", {226, 137, 183, 0}
-"glE", {226, 170, 146, 0}
-"glj", {226, 170, 164, 0}
-"gnap", {226, 170, 138, 0}
-"gnapprox", {226, 170, 138, 0}
-"gne", {226, 170, 136, 0}
-"gnE", {226, 137, 169, 0}
-"gneq", {226, 170, 136, 0}
-"gneqq", {226, 137, 169, 0}
-"gnsim", {226, 139, 167, 0}
-"Gopf", {240, 157, 148, 190}
-"gopf", {240, 157, 149, 152}
-"grave", {96, 0}
-"GreaterEqual", {226, 137, 165, 0}
-"GreaterEqualLess", {226, 139, 155, 0}
-"GreaterFullEqual", {226, 137, 167, 0}
-"GreaterGreater", {226, 170, 162, 0}
-"GreaterLess", {226, 137, 183, 0}
-"GreaterSlantEqual", {226, 169, 190, 0}
-"GreaterTilde", {226, 137, 179, 0}
-"Gscr", {240, 157, 146, 162}
-"gscr", {226, 132, 138, 0}
-"gsim", {226, 137, 179, 0}
-"gsime", {226, 170, 142, 0}
-"gsiml", {226, 170, 144, 0}
-"gtcc", {226, 170, 167, 0}
-"gtcir", {226, 169, 186, 0}
-"gt", {62, 0}
-"GT", {62, 0}
-"Gt", {226, 137, 171, 0}
-"gtdot", {226, 139, 151, 0}
-"gtlPar", {226, 166, 149, 0}
-"gtquest", {226, 169, 188, 0}
-"gtrapprox", {226, 170, 134, 0}
-"gtrarr", {226, 165, 184, 0}
-"gtrdot", {226, 139, 151, 0}
-"gtreqless", {226, 139, 155, 0}
-"gtreqqless", {226, 170, 140, 0}
-"gtrless", {226, 137, 183, 0}
-"gtrsim", {226, 137, 179, 0}
-"gvertneqq", {226, 137, 169, 0}
-"gvnE", {226, 137, 169, 0}
-"Hacek", {203, 135, 0}
-"hairsp", {226, 128, 138, 0}
-"half", {194, 189, 0}
-"hamilt", {226, 132, 139, 0}
-"HARDcy", {208, 170, 0}
-"hardcy", {209, 138, 0}
-"harrcir", {226, 165, 136, 0}
-"harr", {226, 134, 148, 0}
-"hArr", {226, 135, 148, 0}
-"harrw", {226, 134, 173, 0}
-"Hat", {94, 0}
-"hbar", {226, 132, 143, 0}
-"Hcirc", {196, 164, 0}
-"hcirc", {196, 165, 0}
-"hearts", {226, 153, 165, 0}
-"heartsuit", {226, 153, 165, 0}
-"hellip", {226, 128, 166, 0}
-"hercon", {226, 138, 185, 0}
-"hfr", {240, 157, 148, 165}
-"Hfr", {226, 132, 140, 0}
-"HilbertSpace", {226, 132, 139, 0}
-"hksearow", {226, 164, 165, 0}
-"hkswarow", {226, 164, 166, 0}
-"hoarr", {226, 135, 191, 0}
-"homtht", {226, 136, 187, 0}
-"hookleftarrow", {226, 134, 169, 0}
-"hookrightarrow", {226, 134, 170, 0}
-"hopf", {240, 157, 149, 153}
-"Hopf", {226, 132, 141, 0}
-"horbar", {226, 128, 149, 0}
-"HorizontalLine", {226, 148, 128, 0}
-"hscr", {240, 157, 146, 189}
-"Hscr", {226, 132, 139, 0}
-"hslash", {226, 132, 143, 0}
-"Hstrok", {196, 166, 0}
-"hstrok", {196, 167, 0}
-"HumpDownHump", {226, 137, 142, 0}
-"HumpEqual", {226, 137, 143, 0}
-"hybull", {226, 129, 131, 0}
-"hyphen", {226, 128, 144, 0}
-"Iacute", {195, 141, 0}
-"iacute", {195, 173, 0}
-"ic", {226, 129, 163, 0}
-"Icirc", {195, 142, 0}
-"icirc", {195, 174, 0}
-"Icy", {208, 152, 0}
-"icy", {208, 184, 0}
-"Idot", {196, 176, 0}
-"IEcy", {208, 149, 0}
-"iecy", {208, 181, 0}
-"iexcl", {194, 161, 0}
-"iff", {226, 135, 148, 0}
-"ifr", {240, 157, 148, 166}
-"Ifr", {226, 132, 145, 0}
-"Igrave", {195, 140, 0}
-"igrave", {195, 172, 0}
-"ii", {226, 133, 136, 0}
-"iiiint", {226, 168, 140, 0}
-"iiint", {226, 136, 173, 0}
-"iinfin", {226, 167, 156, 0}
-"iiota", {226, 132, 169, 0}
-"IJlig", {196, 178, 0}
-"ijlig", {196, 179, 0}
-"Imacr", {196, 170, 0}
-"imacr", {196, 171, 0}
-"image", {226, 132, 145, 0}
-"ImaginaryI", {226, 133, 136, 0}
-"imagline", {226, 132, 144, 0}
-"imagpart", {226, 132, 145, 0}
-"imath", {196, 177, 0}
-"Im", {226, 132, 145, 0}
-"imof", {226, 138, 183, 0}
-"imped", {198, 181, 0}
-"Implies", {226, 135, 146, 0}
-"incare", {226, 132, 133, 0}
-"in", {226, 136, 136, 0}
-"infin", {226, 136, 158, 0}
-"infintie", {226, 167, 157, 0}
-"inodot", {196, 177, 0}
-"intcal", {226, 138, 186, 0}
-"int", {226, 136, 171, 0}
-"Int", {226, 136, 172, 0}
-"integers", {226, 132, 164, 0}
-"Integral", {226, 136, 171, 0}
-"intercal", {226, 138, 186, 0}
-"Intersection", {226, 139, 130, 0}
-"intlarhk", {226, 168, 151, 0}
-"intprod", {226, 168, 188, 0}
-"InvisibleComma", {226, 129, 163, 0}
-"InvisibleTimes", {226, 129, 162, 0}
-"IOcy", {208, 129, 0}
-"iocy", {209, 145, 0}
-"Iogon", {196, 174, 0}
-"iogon", {196, 175, 0}
-"Iopf", {240, 157, 149, 128}
-"iopf", {240, 157, 149, 154}
-"Iota", {206, 153, 0}
-"iota", {206, 185, 0}
-"iprod", {226, 168, 188, 0}
-"iquest", {194, 191, 0}
-"iscr", {240, 157, 146, 190}
-"Iscr", {226, 132, 144, 0}
-"isin", {226, 136, 136, 0}
-"isindot", {226, 139, 181, 0}
-"isinE", {226, 139, 185, 0}
-"isins", {226, 139, 180, 0}
-"isinsv", {226, 139, 179, 0}
-"isinv", {226, 136, 136, 0}
-"it", {226, 129, 162, 0}
-"Itilde", {196, 168, 0}
-"itilde", {196, 169, 0}
-"Iukcy", {208, 134, 0}
-"iukcy", {209, 150, 0}
-"Iuml", {195, 143, 0}
-"iuml", {195, 175, 0}
-"Jcirc", {196, 180, 0}
-"jcirc", {196, 181, 0}
-"Jcy", {208, 153, 0}
-"jcy", {208, 185, 0}
-"Jfr", {240, 157, 148, 141}
-"jfr", {240, 157, 148, 167}
-"jmath", {200, 183, 0}
-"Jopf", {240, 157, 149, 129}
-"jopf", {240, 157, 149, 155}
-"Jscr", {240, 157, 146, 165}
-"jscr", {240, 157, 146, 191}
-"Jsercy", {208, 136, 0}
-"jsercy", {209, 152, 0}
-"Jukcy", {208, 132, 0}
-"jukcy", {209, 148, 0}
-"Kappa", {206, 154, 0}
-"kappa", {206, 186, 0}
-"kappav", {207, 176, 0}
-"Kcedil", {196, 182, 0}
-"kcedil", {196, 183, 0}
-"Kcy", {208, 154, 0}
-"kcy", {208, 186, 0}
-"Kfr", {240, 157, 148, 142}
-"kfr", {240, 157, 148, 168}
-"kgreen", {196, 184, 0}
-"KHcy", {208, 165, 0}
-"khcy", {209, 133, 0}
-"KJcy", {208, 140, 0}
-"kjcy", {209, 156, 0}
-"Kopf", {240, 157, 149, 130}
-"kopf", {240, 157, 149, 156}
-"Kscr", {240, 157, 146, 166}
-"kscr", {240, 157, 147, 128}
-"lAarr", {226, 135, 154, 0}
-"Lacute", {196, 185, 0}
-"lacute", {196, 186, 0}
-"laemptyv", {226, 166, 180, 0}
-"lagran", {226, 132, 146, 0}
-"Lambda", {206, 155, 0}
-"lambda", {206, 187, 0}
-"lang", {226, 159, 168, 0}
-"Lang", {226, 159, 170, 0}
-"langd", {226, 166, 145, 0}
-"langle", {226, 159, 168, 0}
-"lap", {226, 170, 133, 0}
-"Laplacetrf", {226, 132, 146, 0}
-"laquo", {194, 171, 0}
-"larrb", {226, 135, 164, 0}
-"larrbfs", {226, 164, 159, 0}
-"larr", {226, 134, 144, 0}
-"Larr", {226, 134, 158, 0}
-"lArr", {226, 135, 144, 0}
-"larrfs", {226, 164, 157, 0}
-"larrhk", {226, 134, 169, 0}
-"larrlp", {226, 134, 171, 0}
-"larrpl", {226, 164, 185, 0}
-"larrsim", {226, 165, 179, 0}
-"larrtl", {226, 134, 162, 0}
-"latail", {226, 164, 153, 0}
-"lAtail", {226, 164, 155, 0}
-"lat", {226, 170, 171, 0}
-"late", {226, 170, 173, 0}
-"lates", {226, 170, 173, 0}
-"lbarr", {226, 164, 140, 0}
-"lBarr", {226, 164, 142, 0}
-"lbbrk", {226, 157, 178, 0}
-"lbrace", {123, 0}
-"lbrack", {91, 0}
-"lbrke", {226, 166, 139, 0}
-"lbrksld", {226, 166, 143, 0}
-"lbrkslu", {226, 166, 141, 0}
-"Lcaron", {196, 189, 0}
-"lcaron", {196, 190, 0}
-"Lcedil", {196, 187, 0}
-"lcedil", {196, 188, 0}
-"lceil", {226, 140, 136, 0}
-"lcub", {123, 0}
-"Lcy", {208, 155, 0}
-"lcy", {208, 187, 0}
-"ldca", {226, 164, 182, 0}
-"ldquo", {226, 128, 156, 0}
-"ldquor", {226, 128, 158, 0}
-"ldrdhar", {226, 165, 167, 0}
-"ldrushar", {226, 165, 139, 0}
-"ldsh", {226, 134, 178, 0}
-"le", {226, 137, 164, 0}
-"lE", {226, 137, 166, 0}
-"LeftAngleBracket", {226, 159, 168, 0}
-"LeftArrowBar", {226, 135, 164, 0}
-"leftarrow", {226, 134, 144, 0}
-"LeftArrow", {226, 134, 144, 0}
-"Leftarrow", {226, 135, 144, 0}
-"LeftArrowRightArrow", {226, 135, 134, 0}
-"leftarrowtail", {226, 134, 162, 0}
-"LeftCeiling", {226, 140, 136, 0}
-"LeftDoubleBracket", {226, 159, 166, 0}
-"LeftDownTeeVector", {226, 165, 161, 0}
-"LeftDownVectorBar", {226, 165, 153, 0}
-"LeftDownVector", {226, 135, 131, 0}
-"LeftFloor", {226, 140, 138, 0}
-"leftharpoondown", {226, 134, 189, 0}
-"leftharpoonup", {226, 134, 188, 0}
-"leftleftarrows", {226, 135, 135, 0}
-"leftrightarrow", {226, 134, 148, 0}
-"LeftRightArrow", {226, 134, 148, 0}
-"Leftrightarrow", {226, 135, 148, 0}
-"leftrightarrows", {226, 135, 134, 0}
-"leftrightharpoons", {226, 135, 139, 0}
-"leftrightsquigarrow", {226, 134, 173, 0}
-"LeftRightVector", {226, 165, 142, 0}
-"LeftTeeArrow", {226, 134, 164, 0}
-"LeftTee", {226, 138, 163, 0}
-"LeftTeeVector", {226, 165, 154, 0}
-"leftthreetimes", {226, 139, 139, 0}
-"LeftTriangleBar", {226, 167, 143, 0}
-"LeftTriangle", {226, 138, 178, 0}
-"LeftTriangleEqual", {226, 138, 180, 0}
-"LeftUpDownVector", {226, 165, 145, 0}
-"LeftUpTeeVector", {226, 165, 160, 0}
-"LeftUpVectorBar", {226, 165, 152, 0}
-"LeftUpVector", {226, 134, 191, 0}
-"LeftVectorBar", {226, 165, 146, 0}
-"LeftVector", {226, 134, 188, 0}
-"lEg", {226, 170, 139, 0}
-"leg", {226, 139, 154, 0}
-"leq", {226, 137, 164, 0}
-"leqq", {226, 137, 166, 0}
-"leqslant", {226, 169, 189, 0}
-"lescc", {226, 170, 168, 0}
-"les", {226, 169, 189, 0}
-"lesdot", {226, 169, 191, 0}
-"lesdoto", {226, 170, 129, 0}
-"lesdotor", {226, 170, 131, 0}
-"lesg", {226, 139, 154, 0}
-"lesges", {226, 170, 147, 0}
-"lessapprox", {226, 170, 133, 0}
-"lessdot", {226, 139, 150, 0}
-"lesseqgtr", {226, 139, 154, 0}
-"lesseqqgtr", {226, 170, 139, 0}
-"LessEqualGreater", {226, 139, 154, 0}
-"LessFullEqual", {226, 137, 166, 0}
-"LessGreater", {226, 137, 182, 0}
-"lessgtr", {226, 137, 182, 0}
-"LessLess", {226, 170, 161, 0}
-"lesssim", {226, 137, 178, 0}
-"LessSlantEqual", {226, 169, 189, 0}
-"LessTilde", {226, 137, 178, 0}
-"lfisht", {226, 165, 188, 0}
-"lfloor", {226, 140, 138, 0}
-"Lfr", {240, 157, 148, 143}
-"lfr", {240, 157, 148, 169}
-"lg", {226, 137, 182, 0}
-"lgE", {226, 170, 145, 0}
-"lHar", {226, 165, 162, 0}
-"lhard", {226, 134, 189, 0}
-"lharu", {226, 134, 188, 0}
-"lharul", {226, 165, 170, 0}
-"lhblk", {226, 150, 132, 0}
-"LJcy", {208, 137, 0}
-"ljcy", {209, 153, 0}
-"llarr", {226, 135, 135, 0}
-"ll", {226, 137, 170, 0}
-"Ll", {226, 139, 152, 0}
-"llcorner", {226, 140, 158, 0}
-"Lleftarrow", {226, 135, 154, 0}
-"llhard", {226, 165, 171, 0}
-"lltri", {226, 151, 186, 0}
-"Lmidot", {196, 191, 0}
-"lmidot", {197, 128, 0}
-"lmoustache", {226, 142, 176, 0}
-"lmoust", {226, 142, 176, 0}
-"lnap", {226, 170, 137, 0}
-"lnapprox", {226, 170, 137, 0}
-"lne", {226, 170, 135, 0}
-"lnE", {226, 137, 168, 0}
-"lneq", {226, 170, 135, 0}
-"lneqq", {226, 137, 168, 0}
-"lnsim", {226, 139, 166, 0}
-"loang", {226, 159, 172, 0}
-"loarr", {226, 135, 189, 0}
-"lobrk", {226, 159, 166, 0}
-"longleftarrow", {226, 159, 181, 0}
-"LongLeftArrow", {226, 159, 181, 0}
-"Longleftarrow", {226, 159, 184, 0}
-"longleftrightarrow", {226, 159, 183, 0}
-"LongLeftRightArrow", {226, 159, 183, 0}
-"Longleftrightarrow", {226, 159, 186, 0}
-"longmapsto", {226, 159, 188, 0}
-"longrightarrow", {226, 159, 182, 0}
-"LongRightArrow", {226, 159, 182, 0}
-"Longrightarrow", {226, 159, 185, 0}
-"looparrowleft", {226, 134, 171, 0}
-"looparrowright", {226, 134, 172, 0}
-"lopar", {226, 166, 133, 0}
-"Lopf", {240, 157, 149, 131}
-"lopf", {240, 157, 149, 157}
-"loplus", {226, 168, 173, 0}
-"lotimes", {226, 168, 180, 0}
-"lowast", {226, 136, 151, 0}
-"lowbar", {95, 0}
-"LowerLeftArrow", {226, 134, 153, 0}
-"LowerRightArrow", {226, 134, 152, 0}
-"loz", {226, 151, 138, 0}
-"lozenge", {226, 151, 138, 0}
-"lozf", {226, 167, 171, 0}
-"lpar", {40, 0}
-"lparlt", {226, 166, 147, 0}
-"lrarr", {226, 135, 134, 0}
-"lrcorner", {226, 140, 159, 0}
-"lrhar", {226, 135, 139, 0}
-"lrhard", {226, 165, 173, 0}
-"lrm", {226, 128, 142, 0}
-"lrtri", {226, 138, 191, 0}
-"lsaquo", {226, 128, 185, 0}
-"lscr", {240, 157, 147, 129}
-"Lscr", {226, 132, 146, 0}
-"lsh", {226, 134, 176, 0}
-"Lsh", {226, 134, 176, 0}
-"lsim", {226, 137, 178, 0}
-"lsime", {226, 170, 141, 0}
-"lsimg", {226, 170, 143, 0}
-"lsqb", {91, 0}
-"lsquo", {226, 128, 152, 0}
-"lsquor", {226, 128, 154, 0}
-"Lstrok", {197, 129, 0}
-"lstrok", {197, 130, 0}
-"ltcc", {226, 170, 166, 0}
-"ltcir", {226, 169, 185, 0}
-"lt", {60, 0}
-"LT", {60, 0}
-"Lt", {226, 137, 170, 0}
-"ltdot", {226, 139, 150, 0}
-"lthree", {226, 139, 139, 0}
-"ltimes", {226, 139, 137, 0}
-"ltlarr", {226, 165, 182, 0}
-"ltquest", {226, 169, 187, 0}
-"ltri", {226, 151, 131, 0}
-"ltrie", {226, 138, 180, 0}
-"ltrif", {226, 151, 130, 0}
-"ltrPar", {226, 166, 150, 0}
-"lurdshar", {226, 165, 138, 0}
-"luruhar", {226, 165, 166, 0}
-"lvertneqq", {226, 137, 168, 0}
-"lvnE", {226, 137, 168, 0}
-"macr", {194, 175, 0}
-"male", {226, 153, 130, 0}
-"malt", {226, 156, 160, 0}
-"maltese", {226, 156, 160, 0}
-"Map", {226, 164, 133, 0}
-"map", {226, 134, 166, 0}
-"mapsto", {226, 134, 166, 0}
-"mapstodown", {226, 134, 167, 0}
-"mapstoleft", {226, 134, 164, 0}
-"mapstoup", {226, 134, 165, 0}
-"marker", {226, 150, 174, 0}
-"mcomma", {226, 168, 169, 0}
-"Mcy", {208, 156, 0}
-"mcy", {208, 188, 0}
-"mdash", {226, 128, 148, 0}
-"mDDot", {226, 136, 186, 0}
-"measuredangle", {226, 136, 161, 0}
-"MediumSpace", {226, 129, 159, 0}
-"Mellintrf", {226, 132, 179, 0}
-"Mfr", {240, 157, 148, 144}
-"mfr", {240, 157, 148, 170}
-"mho", {226, 132, 167, 0}
-"micro", {194, 181, 0}
-"midast", {42, 0}
-"midcir", {226, 171, 176, 0}
-"mid", {226, 136, 163, 0}
-"middot", {194, 183, 0}
-"minusb", {226, 138, 159, 0}
-"minus", {226, 136, 146, 0}
-"minusd", {226, 136, 184, 0}
-"minusdu", {226, 168, 170, 0}
-"MinusPlus", {226, 136, 147, 0}
-"mlcp", {226, 171, 155, 0}
-"mldr", {226, 128, 166, 0}
-"mnplus", {226, 136, 147, 0}
-"models", {226, 138, 167, 0}
-"Mopf", {240, 157, 149, 132}
-"mopf", {240, 157, 149, 158}
-"mp", {226, 136, 147, 0}
-"mscr", {240, 157, 147, 130}
-"Mscr", {226, 132, 179, 0}
-"mstpos", {226, 136, 190, 0}
-"Mu", {206, 156, 0}
-"mu", {206, 188, 0}
-"multimap", {226, 138, 184, 0}
-"mumap", {226, 138, 184, 0}
-"nabla", {226, 136, 135, 0}
-"Nacute", {197, 131, 0}
-"nacute", {197, 132, 0}
-"nang", {226, 136, 160, 0}
-"nap", {226, 137, 137, 0}
-"napE", {226, 169, 176, 0}
-"napid", {226, 137, 139, 0}
-"napos", {197, 137, 0}
-"napprox", {226, 137, 137, 0}
-"natural", {226, 153, 174, 0}
-"naturals", {226, 132, 149, 0}
-"natur", {226, 153, 174, 0}
-"nbsp", {194, 160, 0}
-"nbump", {226, 137, 142, 0}
-"nbumpe", {226, 137, 143, 0}
-"ncap", {226, 169, 131, 0}
-"Ncaron", {197, 135, 0}
-"ncaron", {197, 136, 0}
-"Ncedil", {197, 133, 0}
-"ncedil", {197, 134, 0}
-"ncong", {226, 137, 135, 0}
-"ncongdot", {226, 169, 173, 0}
-"ncup", {226, 169, 130, 0}
-"Ncy", {208, 157, 0}
-"ncy", {208, 189, 0}
-"ndash", {226, 128, 147, 0}
-"nearhk", {226, 164, 164, 0}
-"nearr", {226, 134, 151, 0}
-"neArr", {226, 135, 151, 0}
-"nearrow", {226, 134, 151, 0}
-"ne", {226, 137, 160, 0}
-"nedot", {226, 137, 144, 0}
-"NegativeMediumSpace", {226, 128, 139, 0}
-"NegativeThickSpace", {226, 128, 139, 0}
-"NegativeThinSpace", {226, 128, 139, 0}
-"NegativeVeryThinSpace", {226, 128, 139, 0}
-"nequiv", {226, 137, 162, 0}
-"nesear", {226, 164, 168, 0}
-"nesim", {226, 137, 130, 0}
-"NestedGreaterGreater", {226, 137, 171, 0}
-"NestedLessLess", {226, 137, 170, 0}
-"NewLine", {10, 0}
-"nexist", {226, 136, 132, 0}
-"nexists", {226, 136, 132, 0}
-"Nfr", {240, 157, 148, 145}
-"nfr", {240, 157, 148, 171}
-"ngE", {226, 137, 167, 0}
-"nge", {226, 137, 177, 0}
-"ngeq", {226, 137, 177, 0}
-"ngeqq", {226, 137, 167, 0}
-"ngeqslant", {226, 169, 190, 0}
-"nges", {226, 169, 190, 0}
-"nGg", {226, 139, 153, 0}
-"ngsim", {226, 137, 181, 0}
-"nGt", {226, 137, 171, 0}
-"ngt", {226, 137, 175, 0}
-"ngtr", {226, 137, 175, 0}
-"nGtv", {226, 137, 171, 0}
-"nharr", {226, 134, 174, 0}
-"nhArr", {226, 135, 142, 0}
-"nhpar", {226, 171, 178, 0}
-"ni", {226, 136, 139, 0}
-"nis", {226, 139, 188, 0}
-"nisd", {226, 139, 186, 0}
-"niv", {226, 136, 139, 0}
-"NJcy", {208, 138, 0}
-"njcy", {209, 154, 0}
-"nlarr", {226, 134, 154, 0}
-"nlArr", {226, 135, 141, 0}
-"nldr", {226, 128, 165, 0}
-"nlE", {226, 137, 166, 0}
-"nle", {226, 137, 176, 0}
-"nleftarrow", {226, 134, 154, 0}
-"nLeftarrow", {226, 135, 141, 0}
-"nleftrightarrow", {226, 134, 174, 0}
-"nLeftrightarrow", {226, 135, 142, 0}
-"nleq", {226, 137, 176, 0}
-"nleqq", {226, 137, 166, 0}
-"nleqslant", {226, 169, 189, 0}
-"nles", {226, 169, 189, 0}
-"nless", {226, 137, 174, 0}
-"nLl", {226, 139, 152, 0}
-"nlsim", {226, 137, 180, 0}
-"nLt", {226, 137, 170, 0}
-"nlt", {226, 137, 174, 0}
-"nltri", {226, 139, 170, 0}
-"nltrie", {226, 139, 172, 0}
-"nLtv", {226, 137, 170, 0}
-"nmid", {226, 136, 164, 0}
-"NoBreak", {226, 129, 160, 0}
-"NonBreakingSpace", {194, 160, 0}
-"nopf", {240, 157, 149, 159}
-"Nopf", {226, 132, 149, 0}
-"Not", {226, 171, 172, 0}
-"not", {194, 172, 0}
-"NotCongruent", {226, 137, 162, 0}
-"NotCupCap", {226, 137, 173, 0}
-"NotDoubleVerticalBar", {226, 136, 166, 0}
-"NotElement", {226, 136, 137, 0}
-"NotEqual", {226, 137, 160, 0}
-"NotEqualTilde", {226, 137, 130, 0}
-"NotExists", {226, 136, 132, 0}
-"NotGreater", {226, 137, 175, 0}
-"NotGreaterEqual", {226, 137, 177, 0}
-"NotGreaterFullEqual", {226, 137, 167, 0}
-"NotGreaterGreater", {226, 137, 171, 0}
-"NotGreaterLess", {226, 137, 185, 0}
-"NotGreaterSlantEqual", {226, 169, 190, 0}
-"NotGreaterTilde", {226, 137, 181, 0}
-"NotHumpDownHump", {226, 137, 142, 0}
-"NotHumpEqual", {226, 137, 143, 0}
-"notin", {226, 136, 137, 0}
-"notindot", {226, 139, 181, 0}
-"notinE", {226, 139, 185, 0}
-"notinva", {226, 136, 137, 0}
-"notinvb", {226, 139, 183, 0}
-"notinvc", {226, 139, 182, 0}
-"NotLeftTriangleBar", {226, 167, 143, 0}
-"NotLeftTriangle", {226, 139, 170, 0}
-"NotLeftTriangleEqual", {226, 139, 172, 0}
-"NotLess", {226, 137, 174, 0}
-"NotLessEqual", {226, 137, 176, 0}
-"NotLessGreater", {226, 137, 184, 0}
-"NotLessLess", {226, 137, 170, 0}
-"NotLessSlantEqual", {226, 169, 189, 0}
-"NotLessTilde", {226, 137, 180, 0}
-"NotNestedGreaterGreater", {226, 170, 162, 0}
-"NotNestedLessLess", {226, 170, 161, 0}
-"notni", {226, 136, 140, 0}
-"notniva", {226, 136, 140, 0}
-"notnivb", {226, 139, 190, 0}
-"notnivc", {226, 139, 189, 0}
-"NotPrecedes", {226, 138, 128, 0}
-"NotPrecedesEqual", {226, 170, 175, 0}
-"NotPrecedesSlantEqual", {226, 139, 160, 0}
-"NotReverseElement", {226, 136, 140, 0}
-"NotRightTriangleBar", {226, 167, 144, 0}
-"NotRightTriangle", {226, 139, 171, 0}
-"NotRightTriangleEqual", {226, 139, 173, 0}
-"NotSquareSubset", {226, 138, 143, 0}
-"NotSquareSubsetEqual", {226, 139, 162, 0}
-"NotSquareSuperset", {226, 138, 144, 0}
-"NotSquareSupersetEqual", {226, 139, 163, 0}
-"NotSubset", {226, 138, 130, 0}
-"NotSubsetEqual", {226, 138, 136, 0}
-"NotSucceeds", {226, 138, 129, 0}
-"NotSucceedsEqual", {226, 170, 176, 0}
-"NotSucceedsSlantEqual", {226, 139, 161, 0}
-"NotSucceedsTilde", {226, 137, 191, 0}
-"NotSuperset", {226, 138, 131, 0}
-"NotSupersetEqual", {226, 138, 137, 0}
-"NotTilde", {226, 137, 129, 0}
-"NotTildeEqual", {226, 137, 132, 0}
-"NotTildeFullEqual", {226, 137, 135, 0}
-"NotTildeTilde", {226, 137, 137, 0}
-"NotVerticalBar", {226, 136, 164, 0}
-"nparallel", {226, 136, 166, 0}
-"npar", {226, 136, 166, 0}
-"nparsl", {226, 171, 189, 0}
-"npart", {226, 136, 130, 0}
-"npolint", {226, 168, 148, 0}
-"npr", {226, 138, 128, 0}
-"nprcue", {226, 139, 160, 0}
-"nprec", {226, 138, 128, 0}
-"npreceq", {226, 170, 175, 0}
-"npre", {226, 170, 175, 0}
-"nrarrc", {226, 164, 179, 0}
-"nrarr", {226, 134, 155, 0}
-"nrArr", {226, 135, 143, 0}
-"nrarrw", {226, 134, 157, 0}
-"nrightarrow", {226, 134, 155, 0}
-"nRightarrow", {226, 135, 143, 0}
-"nrtri", {226, 139, 171, 0}
-"nrtrie", {226, 139, 173, 0}
-"nsc", {226, 138, 129, 0}
-"nsccue", {226, 139, 161, 0}
-"nsce", {226, 170, 176, 0}
-"Nscr", {240, 157, 146, 169}
-"nscr", {240, 157, 147, 131}
-"nshortmid", {226, 136, 164, 0}
-"nshortparallel", {226, 136, 166, 0}
-"nsim", {226, 137, 129, 0}
-"nsime", {226, 137, 132, 0}
-"nsimeq", {226, 137, 132, 0}
-"nsmid", {226, 136, 164, 0}
-"nspar", {226, 136, 166, 0}
-"nsqsube", {226, 139, 162, 0}
-"nsqsupe", {226, 139, 163, 0}
-"nsub", {226, 138, 132, 0}
-"nsubE", {226, 171, 133, 0}
-"nsube", {226, 138, 136, 0}
-"nsubset", {226, 138, 130, 0}
-"nsubseteq", {226, 138, 136, 0}
-"nsubseteqq", {226, 171, 133, 0}
-"nsucc", {226, 138, 129, 0}
-"nsucceq", {226, 170, 176, 0}
-"nsup", {226, 138, 133, 0}
-"nsupE", {226, 171, 134, 0}
-"nsupe", {226, 138, 137, 0}
-"nsupset", {226, 138, 131, 0}
-"nsupseteq", {226, 138, 137, 0}
-"nsupseteqq", {226, 171, 134, 0}
-"ntgl", {226, 137, 185, 0}
-"Ntilde", {195, 145, 0}
-"ntilde", {195, 177, 0}
-"ntlg", {226, 137, 184, 0}
-"ntriangleleft", {226, 139, 170, 0}
-"ntrianglelefteq", {226, 139, 172, 0}
-"ntriangleright", {226, 139, 171, 0}
-"ntrianglerighteq", {226, 139, 173, 0}
-"Nu", {206, 157, 0}
-"nu", {206, 189, 0}
-"num", {35, 0}
-"numero", {226, 132, 150, 0}
-"numsp", {226, 128, 135, 0}
-"nvap", {226, 137, 141, 0}
-"nvdash", {226, 138, 172, 0}
-"nvDash", {226, 138, 173, 0}
-"nVdash", {226, 138, 174, 0}
-"nVDash", {226, 138, 175, 0}
-"nvge", {226, 137, 165, 0}
-"nvgt", {62, 0}
-"nvHarr", {226, 164, 132, 0}
-"nvinfin", {226, 167, 158, 0}
-"nvlArr", {226, 164, 130, 0}
-"nvle", {226, 137, 164, 0}
-"nvlt", {60, 0}
-"nvltrie", {226, 138, 180, 0}
-"nvrArr", {226, 164, 131, 0}
-"nvrtrie", {226, 138, 181, 0}
-"nvsim", {226, 136, 188, 0}
-"nwarhk", {226, 164, 163, 0}
-"nwarr", {226, 134, 150, 0}
-"nwArr", {226, 135, 150, 0}
-"nwarrow", {226, 134, 150, 0}
-"nwnear", {226, 164, 167, 0}
-"Oacute", {195, 147, 0}
-"oacute", {195, 179, 0}
-"oast", {226, 138, 155, 0}
-"Ocirc", {195, 148, 0}
-"ocirc", {195, 180, 0}
-"ocir", {226, 138, 154, 0}
-"Ocy", {208, 158, 0}
-"ocy", {208, 190, 0}
-"odash", {226, 138, 157, 0}
-"Odblac", {197, 144, 0}
-"odblac", {197, 145, 0}
-"odiv", {226, 168, 184, 0}
-"odot", {226, 138, 153, 0}
-"odsold", {226, 166, 188, 0}
-"OElig", {197, 146, 0}
-"oelig", {197, 147, 0}
-"ofcir", {226, 166, 191, 0}
-"Ofr", {240, 157, 148, 146}
-"ofr", {240, 157, 148, 172}
-"ogon", {203, 155, 0}
-"Ograve", {195, 146, 0}
-"ograve", {195, 178, 0}
-"ogt", {226, 167, 129, 0}
-"ohbar", {226, 166, 181, 0}
-"ohm", {206, 169, 0}
-"oint", {226, 136, 174, 0}
-"olarr", {226, 134, 186, 0}
-"olcir", {226, 166, 190, 0}
-"olcross", {226, 166, 187, 0}
-"oline", {226, 128, 190, 0}
-"olt", {226, 167, 128, 0}
-"Omacr", {197, 140, 0}
-"omacr", {197, 141, 0}
-"Omega", {206, 169, 0}
-"omega", {207, 137, 0}
-"Omicron", {206, 159, 0}
-"omicron", {206, 191, 0}
-"omid", {226, 166, 182, 0}
-"ominus", {226, 138, 150, 0}
-"Oopf", {240, 157, 149, 134}
-"oopf", {240, 157, 149, 160}
-"opar", {226, 166, 183, 0}
-"OpenCurlyDoubleQuote", {226, 128, 156, 0}
-"OpenCurlyQuote", {226, 128, 152, 0}
-"operp", {226, 166, 185, 0}
-"oplus", {226, 138, 149, 0}
-"orarr", {226, 134, 187, 0}
-"Or", {226, 169, 148, 0}
-"or", {226, 136, 168, 0}
-"ord", {226, 169, 157, 0}
-"order", {226, 132, 180, 0}
-"orderof", {226, 132, 180, 0}
-"ordf", {194, 170, 0}
-"ordm", {194, 186, 0}
-"origof", {226, 138, 182, 0}
-"oror", {226, 169, 150, 0}
-"orslope", {226, 169, 151, 0}
-"orv", {226, 169, 155, 0}
-"oS", {226, 147, 136, 0}
-"Oscr", {240, 157, 146, 170}
-"oscr", {226, 132, 180, 0}
-"Oslash", {195, 152, 0}
-"oslash", {195, 184, 0}
-"osol", {226, 138, 152, 0}
-"Otilde", {195, 149, 0}
-"otilde", {195, 181, 0}
-"otimesas", {226, 168, 182, 0}
-"Otimes", {226, 168, 183, 0}
-"otimes", {226, 138, 151, 0}
-"Ouml", {195, 150, 0}
-"ouml", {195, 182, 0}
-"ovbar", {226, 140, 189, 0}
-"OverBar", {226, 128, 190, 0}
-"OverBrace", {226, 143, 158, 0}
-"OverBracket", {226, 142, 180, 0}
-"OverParenthesis", {226, 143, 156, 0}
-"para", {194, 182, 0}
-"parallel", {226, 136, 165, 0}
-"par", {226, 136, 165, 0}
-"parsim", {226, 171, 179, 0}
-"parsl", {226, 171, 189, 0}
-"part", {226, 136, 130, 0}
-"PartialD", {226, 136, 130, 0}
-"Pcy", {208, 159, 0}
-"pcy", {208, 191, 0}
-"percnt", {37, 0}
-"period", {46, 0}
-"permil", {226, 128, 176, 0}
-"perp", {226, 138, 165, 0}
-"pertenk", {226, 128, 177, 0}
-"Pfr", {240, 157, 148, 147}
-"pfr", {240, 157, 148, 173}
-"Phi", {206, 166, 0}
-"phi", {207, 134, 0}
-"phiv", {207, 149, 0}
-"phmmat", {226, 132, 179, 0}
-"phone", {226, 152, 142, 0}
-"Pi", {206, 160, 0}
-"pi", {207, 128, 0}
-"pitchfork", {226, 139, 148, 0}
-"piv", {207, 150, 0}
-"planck", {226, 132, 143, 0}
-"planckh", {226, 132, 142, 0}
-"plankv", {226, 132, 143, 0}
-"plusacir", {226, 168, 163, 0}
-"plusb", {226, 138, 158, 0}
-"pluscir", {226, 168, 162, 0}
-"plus", {43, 0}
-"plusdo", {226, 136, 148, 0}
-"plusdu", {226, 168, 165, 0}
-"pluse", {226, 169, 178, 0}
-"PlusMinus", {194, 177, 0}
-"plusmn", {194, 177, 0}
-"plussim", {226, 168, 166, 0}
-"plustwo", {226, 168, 167, 0}
-"pm", {194, 177, 0}
-"Poincareplane", {226, 132, 140, 0}
-"pointint", {226, 168, 149, 0}
-"popf", {240, 157, 149, 161}
-"Popf", {226, 132, 153, 0}
-"pound", {194, 163, 0}
-"prap", {226, 170, 183, 0}
-"Pr", {226, 170, 187, 0}
-"pr", {226, 137, 186, 0}
-"prcue", {226, 137, 188, 0}
-"precapprox", {226, 170, 183, 0}
-"prec", {226, 137, 186, 0}
-"preccurlyeq", {226, 137, 188, 0}
-"Precedes", {226, 137, 186, 0}
-"PrecedesEqual", {226, 170, 175, 0}
-"PrecedesSlantEqual", {226, 137, 188, 0}
-"PrecedesTilde", {226, 137, 190, 0}
-"preceq", {226, 170, 175, 0}
-"precnapprox", {226, 170, 185, 0}
-"precneqq", {226, 170, 181, 0}
-"precnsim", {226, 139, 168, 0}
-"pre", {226, 170, 175, 0}
-"prE", {226, 170, 179, 0}
-"precsim", {226, 137, 190, 0}
-"prime", {226, 128, 178, 0}
-"Prime", {226, 128, 179, 0}
-"primes", {226, 132, 153, 0}
-"prnap", {226, 170, 185, 0}
-"prnE", {226, 170, 181, 0}
-"prnsim", {226, 139, 168, 0}
-"prod", {226, 136, 143, 0}
-"Product", {226, 136, 143, 0}
-"profalar", {226, 140, 174, 0}
-"profline", {226, 140, 146, 0}
-"profsurf", {226, 140, 147, 0}
-"prop", {226, 136, 157, 0}
-"Proportional", {226, 136, 157, 0}
-"Proportion", {226, 136, 183, 0}
-"propto", {226, 136, 157, 0}
-"prsim", {226, 137, 190, 0}
-"prurel", {226, 138, 176, 0}
-"Pscr", {240, 157, 146, 171}
-"pscr", {240, 157, 147, 133}
-"Psi", {206, 168, 0}
-"psi", {207, 136, 0}
-"puncsp", {226, 128, 136, 0}
-"Qfr", {240, 157, 148, 148}
-"qfr", {240, 157, 148, 174}
-"qint", {226, 168, 140, 0}
-"qopf", {240, 157, 149, 162}
-"Qopf", {226, 132, 154, 0}
-"qprime", {226, 129, 151, 0}
-"Qscr", {240, 157, 146, 172}
-"qscr", {240, 157, 147, 134}
-"quaternions", {226, 132, 141, 0}
-"quatint", {226, 168, 150, 0}
-"quest", {63, 0}
-"questeq", {226, 137, 159, 0}
-"quot", {34, 0}
-"QUOT", {34, 0}
-"rAarr", {226, 135, 155, 0}
-"race", {226, 136, 189, 0}
-"Racute", {197, 148, 0}
-"racute", {197, 149, 0}
-"radic", {226, 136, 154, 0}
-"raemptyv", {226, 166, 179, 0}
-"rang", {226, 159, 169, 0}
-"Rang", {226, 159, 171, 0}
-"rangd", {226, 166, 146, 0}
-"range", {226, 166, 165, 0}
-"rangle", {226, 159, 169, 0}
-"raquo", {194, 187, 0}
-"rarrap", {226, 165, 181, 0}
-"rarrb", {226, 135, 165, 0}
-"rarrbfs", {226, 164, 160, 0}
-"rarrc", {226, 164, 179, 0}
-"rarr", {226, 134, 146, 0}
-"Rarr", {226, 134, 160, 0}
-"rArr", {226, 135, 146, 0}
-"rarrfs", {226, 164, 158, 0}
-"rarrhk", {226, 134, 170, 0}
-"rarrlp", {226, 134, 172, 0}
-"rarrpl", {226, 165, 133, 0}
-"rarrsim", {226, 165, 180, 0}
-"Rarrtl", {226, 164, 150, 0}
-"rarrtl", {226, 134, 163, 0}
-"rarrw", {226, 134, 157, 0}
-"ratail", {226, 164, 154, 0}
-"rAtail", {226, 164, 156, 0}
-"ratio", {226, 136, 182, 0}
-"rationals", {226, 132, 154, 0}
-"rbarr", {226, 164, 141, 0}
-"rBarr", {226, 164, 143, 0}
-"RBarr", {226, 164, 144, 0}
-"rbbrk", {226, 157, 179, 0}
-"rbrace", {125, 0}
-"rbrack", {93, 0}
-"rbrke", {226, 166, 140, 0}
-"rbrksld", {226, 166, 142, 0}
-"rbrkslu", {226, 166, 144, 0}
-"Rcaron", {197, 152, 0}
-"rcaron", {197, 153, 0}
-"Rcedil", {197, 150, 0}
-"rcedil", {197, 151, 0}
-"rceil", {226, 140, 137, 0}
-"rcub", {125, 0}
-"Rcy", {208, 160, 0}
-"rcy", {209, 128, 0}
-"rdca", {226, 164, 183, 0}
-"rdldhar", {226, 165, 169, 0}
-"rdquo", {226, 128, 157, 0}
-"rdquor", {226, 128, 157, 0}
-"rdsh", {226, 134, 179, 0}
-"real", {226, 132, 156, 0}
-"realine", {226, 132, 155, 0}
-"realpart", {226, 132, 156, 0}
-"reals", {226, 132, 157, 0}
-"Re", {226, 132, 156, 0}
-"rect", {226, 150, 173, 0}
-"reg", {194, 174, 0}
-"REG", {194, 174, 0}
-"ReverseElement", {226, 136, 139, 0}
-"ReverseEquilibrium", {226, 135, 139, 0}
-"ReverseUpEquilibrium", {226, 165, 175, 0}
-"rfisht", {226, 165, 189, 0}
-"rfloor", {226, 140, 139, 0}
-"rfr", {240, 157, 148, 175}
-"Rfr", {226, 132, 156, 0}
-"rHar", {226, 165, 164, 0}
-"rhard", {226, 135, 129, 0}
-"rharu", {226, 135, 128, 0}
-"rharul", {226, 165, 172, 0}
-"Rho", {206, 161, 0}
-"rho", {207, 129, 0}
-"rhov", {207, 177, 0}
-"RightAngleBracket", {226, 159, 169, 0}
-"RightArrowBar", {226, 135, 165, 0}
-"rightarrow", {226, 134, 146, 0}
-"RightArrow", {226, 134, 146, 0}
-"Rightarrow", {226, 135, 146, 0}
-"RightArrowLeftArrow", {226, 135, 132, 0}
-"rightarrowtail", {226, 134, 163, 0}
-"RightCeiling", {226, 140, 137, 0}
-"RightDoubleBracket", {226, 159, 167, 0}
-"RightDownTeeVector", {226, 165, 157, 0}
-"RightDownVectorBar", {226, 165, 149, 0}
-"RightDownVector", {226, 135, 130, 0}
-"RightFloor", {226, 140, 139, 0}
-"rightharpoondown", {226, 135, 129, 0}
-"rightharpoonup", {226, 135, 128, 0}
-"rightleftarrows", {226, 135, 132, 0}
-"rightleftharpoons", {226, 135, 140, 0}
-"rightrightarrows", {226, 135, 137, 0}
-"rightsquigarrow", {226, 134, 157, 0}
-"RightTeeArrow", {226, 134, 166, 0}
-"RightTee", {226, 138, 162, 0}
-"RightTeeVector", {226, 165, 155, 0}
-"rightthreetimes", {226, 139, 140, 0}
-"RightTriangleBar", {226, 167, 144, 0}
-"RightTriangle", {226, 138, 179, 0}
-"RightTriangleEqual", {226, 138, 181, 0}
-"RightUpDownVector", {226, 165, 143, 0}
-"RightUpTeeVector", {226, 165, 156, 0}
-"RightUpVectorBar", {226, 165, 148, 0}
-"RightUpVector", {226, 134, 190, 0}
-"RightVectorBar", {226, 165, 147, 0}
-"RightVector", {226, 135, 128, 0}
-"ring", {203, 154, 0}
-"risingdotseq", {226, 137, 147, 0}
-"rlarr", {226, 135, 132, 0}
-"rlhar", {226, 135, 140, 0}
-"rlm", {226, 128, 143, 0}
-"rmoustache", {226, 142, 177, 0}
-"rmoust", {226, 142, 177, 0}
-"rnmid", {226, 171, 174, 0}
-"roang", {226, 159, 173, 0}
-"roarr", {226, 135, 190, 0}
-"robrk", {226, 159, 167, 0}
-"ropar", {226, 166, 134, 0}
-"ropf", {240, 157, 149, 163}
-"Ropf", {226, 132, 157, 0}
-"roplus", {226, 168, 174, 0}
-"rotimes", {226, 168, 181, 0}
-"RoundImplies", {226, 165, 176, 0}
-"rpar", {41, 0}
-"rpargt", {226, 166, 148, 0}
-"rppolint", {226, 168, 146, 0}
-"rrarr", {226, 135, 137, 0}
-"Rrightarrow", {226, 135, 155, 0}
-"rsaquo", {226, 128, 186, 0}
-"rscr", {240, 157, 147, 135}
-"Rscr", {226, 132, 155, 0}
-"rsh", {226, 134, 177, 0}
-"Rsh", {226, 134, 177, 0}
-"rsqb", {93, 0}
-"rsquo", {226, 128, 153, 0}
-"rsquor", {226, 128, 153, 0}
-"rthree", {226, 139, 140, 0}
-"rtimes", {226, 139, 138, 0}
-"rtri", {226, 150, 185, 0}
-"rtrie", {226, 138, 181, 0}
-"rtrif", {226, 150, 184, 0}
-"rtriltri", {226, 167, 142, 0}
-"RuleDelayed", {226, 167, 180, 0}
-"ruluhar", {226, 165, 168, 0}
-"rx", {226, 132, 158, 0}
-"Sacute", {197, 154, 0}
-"sacute", {197, 155, 0}
-"sbquo", {226, 128, 154, 0}
-"scap", {226, 170, 184, 0}
-"Scaron", {197, 160, 0}
-"scaron", {197, 161, 0}
-"Sc", {226, 170, 188, 0}
-"sc", {226, 137, 187, 0}
-"sccue", {226, 137, 189, 0}
-"sce", {226, 170, 176, 0}
-"scE", {226, 170, 180, 0}
-"Scedil", {197, 158, 0}
-"scedil", {197, 159, 0}
-"Scirc", {197, 156, 0}
-"scirc", {197, 157, 0}
-"scnap", {226, 170, 186, 0}
-"scnE", {226, 170, 182, 0}
-"scnsim", {226, 139, 169, 0}
-"scpolint", {226, 168, 147, 0}
-"scsim", {226, 137, 191, 0}
-"Scy", {208, 161, 0}
-"scy", {209, 129, 0}
-"sdotb", {226, 138, 161, 0}
-"sdot", {226, 139, 133, 0}
-"sdote", {226, 169, 166, 0}
-"searhk", {226, 164, 165, 0}
-"searr", {226, 134, 152, 0}
-"seArr", {226, 135, 152, 0}
-"searrow", {226, 134, 152, 0}
-"sect", {194, 167, 0}
-"semi", {59, 0}
-"seswar", {226, 164, 169, 0}
-"setminus", {226, 136, 150, 0}
-"setmn", {226, 136, 150, 0}
-"sext", {226, 156, 182, 0}
-"Sfr", {240, 157, 148, 150}
-"sfr", {240, 157, 148, 176}
-"sfrown", {226, 140, 162, 0}
-"sharp", {226, 153, 175, 0}
-"SHCHcy", {208, 169, 0}
-"shchcy", {209, 137, 0}
-"SHcy", {208, 168, 0}
-"shcy", {209, 136, 0}
-"ShortDownArrow", {226, 134, 147, 0}
-"ShortLeftArrow", {226, 134, 144, 0}
-"shortmid", {226, 136, 163, 0}
-"shortparallel", {226, 136, 165, 0}
-"ShortRightArrow", {226, 134, 146, 0}
-"ShortUpArrow", {226, 134, 145, 0}
-"shy", {194, 173, 0}
-"Sigma", {206, 163, 0}
-"sigma", {207, 131, 0}
-"sigmaf", {207, 130, 0}
-"sigmav", {207, 130, 0}
-"sim", {226, 136, 188, 0}
-"simdot", {226, 169, 170, 0}
-"sime", {226, 137, 131, 0}
-"simeq", {226, 137, 131, 0}
-"simg", {226, 170, 158, 0}
-"simgE", {226, 170, 160, 0}
-"siml", {226, 170, 157, 0}
-"simlE", {226, 170, 159, 0}
-"simne", {226, 137, 134, 0}
-"simplus", {226, 168, 164, 0}
-"simrarr", {226, 165, 178, 0}
-"slarr", {226, 134, 144, 0}
-"SmallCircle", {226, 136, 152, 0}
-"smallsetminus", {226, 136, 150, 0}
-"smashp", {226, 168, 179, 0}
-"smeparsl", {226, 167, 164, 0}
-"smid", {226, 136, 163, 0}
-"smile", {226, 140, 163, 0}
-"smt", {226, 170, 170, 0}
-"smte", {226, 170, 172, 0}
-"smtes", {226, 170, 172, 0}
-"SOFTcy", {208, 172, 0}
-"softcy", {209, 140, 0}
-"solbar", {226, 140, 191, 0}
-"solb", {226, 167, 132, 0}
-"sol", {47, 0}
-"Sopf", {240, 157, 149, 138}
-"sopf", {240, 157, 149, 164}
-"spades", {226, 153, 160, 0}
-"spadesuit", {226, 153, 160, 0}
-"spar", {226, 136, 165, 0}
-"sqcap", {226, 138, 147, 0}
-"sqcaps", {226, 138, 147, 0}
-"sqcup", {226, 138, 148, 0}
-"sqcups", {226, 138, 148, 0}
-"Sqrt", {226, 136, 154, 0}
-"sqsub", {226, 138, 143, 0}
-"sqsube", {226, 138, 145, 0}
-"sqsubset", {226, 138, 143, 0}
-"sqsubseteq", {226, 138, 145, 0}
-"sqsup", {226, 138, 144, 0}
-"sqsupe", {226, 138, 146, 0}
-"sqsupset", {226, 138, 144, 0}
-"sqsupseteq", {226, 138, 146, 0}
-"square", {226, 150, 161, 0}
-"Square", {226, 150, 161, 0}
-"SquareIntersection", {226, 138, 147, 0}
-"SquareSubset", {226, 138, 143, 0}
-"SquareSubsetEqual", {226, 138, 145, 0}
-"SquareSuperset", {226, 138, 144, 0}
-"SquareSupersetEqual", {226, 138, 146, 0}
-"SquareUnion", {226, 138, 148, 0}
-"squarf", {226, 150, 170, 0}
-"squ", {226, 150, 161, 0}
-"squf", {226, 150, 170, 0}
-"srarr", {226, 134, 146, 0}
-"Sscr", {240, 157, 146, 174}
-"sscr", {240, 157, 147, 136}
-"ssetmn", {226, 136, 150, 0}
-"ssmile", {226, 140, 163, 0}
-"sstarf", {226, 139, 134, 0}
-"Star", {226, 139, 134, 0}
-"star", {226, 152, 134, 0}
-"starf", {226, 152, 133, 0}
-"straightepsilon", {207, 181, 0}
-"straightphi", {207, 149, 0}
-"strns", {194, 175, 0}
-"sub", {226, 138, 130, 0}
-"Sub", {226, 139, 144, 0}
-"subdot", {226, 170, 189, 0}
-"subE", {226, 171, 133, 0}
-"sube", {226, 138, 134, 0}
-"subedot", {226, 171, 131, 0}
-"submult", {226, 171, 129, 0}
-"subnE", {226, 171, 139, 0}
-"subne", {226, 138, 138, 0}
-"subplus", {226, 170, 191, 0}
-"subrarr", {226, 165, 185, 0}
-"subset", {226, 138, 130, 0}
-"Subset", {226, 139, 144, 0}
-"subseteq", {226, 138, 134, 0}
-"subseteqq", {226, 171, 133, 0}
-"SubsetEqual", {226, 138, 134, 0}
-"subsetneq", {226, 138, 138, 0}
-"subsetneqq", {226, 171, 139, 0}
-"subsim", {226, 171, 135, 0}
-"subsub", {226, 171, 149, 0}
-"subsup", {226, 171, 147, 0}
-"succapprox", {226, 170, 184, 0}
-"succ", {226, 137, 187, 0}
-"succcurlyeq", {226, 137, 189, 0}
-"Succeeds", {226, 137, 187, 0}
-"SucceedsEqual", {226, 170, 176, 0}
-"SucceedsSlantEqual", {226, 137, 189, 0}
-"SucceedsTilde", {226, 137, 191, 0}
-"succeq", {226, 170, 176, 0}
-"succnapprox", {226, 170, 186, 0}
-"succneqq", {226, 170, 182, 0}
-"succnsim", {226, 139, 169, 0}
-"succsim", {226, 137, 191, 0}
-"SuchThat", {226, 136, 139, 0}
-"sum", {226, 136, 145, 0}
-"Sum", {226, 136, 145, 0}
-"sung", {226, 153, 170, 0}
-"sup1", {194, 185, 0}
-"sup2", {194, 178, 0}
-"sup3", {194, 179, 0}
-"sup", {226, 138, 131, 0}
-"Sup", {226, 139, 145, 0}
-"supdot", {226, 170, 190, 0}
-"supdsub", {226, 171, 152, 0}
-"supE", {226, 171, 134, 0}
-"supe", {226, 138, 135, 0}
-"supedot", {226, 171, 132, 0}
-"Superset", {226, 138, 131, 0}
-"SupersetEqual", {226, 138, 135, 0}
-"suphsol", {226, 159, 137, 0}
-"suphsub", {226, 171, 151, 0}
-"suplarr", {226, 165, 187, 0}
-"supmult", {226, 171, 130, 0}
-"supnE", {226, 171, 140, 0}
-"supne", {226, 138, 139, 0}
-"supplus", {226, 171, 128, 0}
-"supset", {226, 138, 131, 0}
-"Supset", {226, 139, 145, 0}
-"supseteq", {226, 138, 135, 0}
-"supseteqq", {226, 171, 134, 0}
-"supsetneq", {226, 138, 139, 0}
-"supsetneqq", {226, 171, 140, 0}
-"supsim", {226, 171, 136, 0}
-"supsub", {226, 171, 148, 0}
-"supsup", {226, 171, 150, 0}
-"swarhk", {226, 164, 166, 0}
-"swarr", {226, 134, 153, 0}
-"swArr", {226, 135, 153, 0}
-"swarrow", {226, 134, 153, 0}
-"swnwar", {226, 164, 170, 0}
-"szlig", {195, 159, 0}
-"Tab", {9, 0}
-"target", {226, 140, 150, 0}
-"Tau", {206, 164, 0}
-"tau", {207, 132, 0}
-"tbrk", {226, 142, 180, 0}
-"Tcaron", {197, 164, 0}
-"tcaron", {197, 165, 0}
-"Tcedil", {197, 162, 0}
-"tcedil", {197, 163, 0}
-"Tcy", {208, 162, 0}
-"tcy", {209, 130, 0}
-"tdot", {226, 131, 155, 0}
-"telrec", {226, 140, 149, 0}
-"Tfr", {240, 157, 148, 151}
-"tfr", {240, 157, 148, 177}
-"there4", {226, 136, 180, 0}
-"therefore", {226, 136, 180, 0}
-"Therefore", {226, 136, 180, 0}
-"Theta", {206, 152, 0}
-"theta", {206, 184, 0}
-"thetasym", {207, 145, 0}
-"thetav", {207, 145, 0}
-"thickapprox", {226, 137, 136, 0}
-"thicksim", {226, 136, 188, 0}
-"ThickSpace", {226, 129, 159, 0}
-"ThinSpace", {226, 128, 137, 0}
-"thinsp", {226, 128, 137, 0}
-"thkap", {226, 137, 136, 0}
-"thksim", {226, 136, 188, 0}
-"THORN", {195, 158, 0}
-"thorn", {195, 190, 0}
-"tilde", {203, 156, 0}
-"Tilde", {226, 136, 188, 0}
-"TildeEqual", {226, 137, 131, 0}
-"TildeFullEqual", {226, 137, 133, 0}
-"TildeTilde", {226, 137, 136, 0}
-"timesbar", {226, 168, 177, 0}
-"timesb", {226, 138, 160, 0}
-"times", {195, 151, 0}
-"timesd", {226, 168, 176, 0}
-"tint", {226, 136, 173, 0}
-"toea", {226, 164, 168, 0}
-"topbot", {226, 140, 182, 0}
-"topcir", {226, 171, 177, 0}
-"top", {226, 138, 164, 0}
-"Topf", {240, 157, 149, 139}
-"topf", {240, 157, 149, 165}
-"topfork", {226, 171, 154, 0}
-"tosa", {226, 164, 169, 0}
-"tprime", {226, 128, 180, 0}
-"trade", {226, 132, 162, 0}
-"TRADE", {226, 132, 162, 0}
-"triangle", {226, 150, 181, 0}
-"triangledown", {226, 150, 191, 0}
-"triangleleft", {226, 151, 131, 0}
-"trianglelefteq", {226, 138, 180, 0}
-"triangleq", {226, 137, 156, 0}
-"triangleright", {226, 150, 185, 0}
-"trianglerighteq", {226, 138, 181, 0}
-"tridot", {226, 151, 172, 0}
-"trie", {226, 137, 156, 0}
-"triminus", {226, 168, 186, 0}
-"TripleDot", {226, 131, 155, 0}
-"triplus", {226, 168, 185, 0}
-"trisb", {226, 167, 141, 0}
-"tritime", {226, 168, 187, 0}
-"trpezium", {226, 143, 162, 0}
-"Tscr", {240, 157, 146, 175}
-"tscr", {240, 157, 147, 137}
-"TScy", {208, 166, 0}
-"tscy", {209, 134, 0}
-"TSHcy", {208, 139, 0}
-"tshcy", {209, 155, 0}
-"Tstrok", {197, 166, 0}
-"tstrok", {197, 167, 0}
-"twixt", {226, 137, 172, 0}
-"twoheadleftarrow", {226, 134, 158, 0}
-"twoheadrightarrow", {226, 134, 160, 0}
-"Uacute", {195, 154, 0}
-"uacute", {195, 186, 0}
-"uarr", {226, 134, 145, 0}
-"Uarr", {226, 134, 159, 0}
-"uArr", {226, 135, 145, 0}
-"Uarrocir", {226, 165, 137, 0}
-"Ubrcy", {208, 142, 0}
-"ubrcy", {209, 158, 0}
-"Ubreve", {197, 172, 0}
-"ubreve", {197, 173, 0}
-"Ucirc", {195, 155, 0}
-"ucirc", {195, 187, 0}
-"Ucy", {208, 163, 0}
-"ucy", {209, 131, 0}
-"udarr", {226, 135, 133, 0}
-"Udblac", {197, 176, 0}
-"udblac", {197, 177, 0}
-"udhar", {226, 165, 174, 0}
-"ufisht", {226, 165, 190, 0}
-"Ufr", {240, 157, 148, 152}
-"ufr", {240, 157, 148, 178}
-"Ugrave", {195, 153, 0}
-"ugrave", {195, 185, 0}
-"uHar", {226, 165, 163, 0}
-"uharl", {226, 134, 191, 0}
-"uharr", {226, 134, 190, 0}
-"uhblk", {226, 150, 128, 0}
-"ulcorn", {226, 140, 156, 0}
-"ulcorner", {226, 140, 156, 0}
-"ulcrop", {226, 140, 143, 0}
-"ultri", {226, 151, 184, 0}
-"Umacr", {197, 170, 0}
-"umacr", {197, 171, 0}
-"uml", {194, 168, 0}
-"UnderBar", {95, 0}
-"UnderBrace", {226, 143, 159, 0}
-"UnderBracket", {226, 142, 181, 0}
-"UnderParenthesis", {226, 143, 157, 0}
-"Union", {226, 139, 131, 0}
-"UnionPlus", {226, 138, 142, 0}
-"Uogon", {197, 178, 0}
-"uogon", {197, 179, 0}
-"Uopf", {240, 157, 149, 140}
-"uopf", {240, 157, 149, 166}
-"UpArrowBar", {226, 164, 146, 0}
-"uparrow", {226, 134, 145, 0}
-"UpArrow", {226, 134, 145, 0}
-"Uparrow", {226, 135, 145, 0}
-"UpArrowDownArrow", {226, 135, 133, 0}
-"updownarrow", {226, 134, 149, 0}
-"UpDownArrow", {226, 134, 149, 0}
-"Updownarrow", {226, 135, 149, 0}
-"UpEquilibrium", {226, 165, 174, 0}
-"upharpoonleft", {226, 134, 191, 0}
-"upharpoonright", {226, 134, 190, 0}
-"uplus", {226, 138, 142, 0}
-"UpperLeftArrow", {226, 134, 150, 0}
-"UpperRightArrow", {226, 134, 151, 0}
-"upsi", {207, 133, 0}
-"Upsi", {207, 146, 0}
-"upsih", {207, 146, 0}
-"Upsilon", {206, 165, 0}
-"upsilon", {207, 133, 0}
-"UpTeeArrow", {226, 134, 165, 0}
-"UpTee", {226, 138, 165, 0}
-"upuparrows", {226, 135, 136, 0}
-"urcorn", {226, 140, 157, 0}
-"urcorner", {226, 140, 157, 0}
-"urcrop", {226, 140, 142, 0}
-"Uring", {197, 174, 0}
-"uring", {197, 175, 0}
-"urtri", {226, 151, 185, 0}
-"Uscr", {240, 157, 146, 176}
-"uscr", {240, 157, 147, 138}
-"utdot", {226, 139, 176, 0}
-"Utilde", {197, 168, 0}
-"utilde", {197, 169, 0}
-"utri", {226, 150, 181, 0}
-"utrif", {226, 150, 180, 0}
-"uuarr", {226, 135, 136, 0}
-"Uuml", {195, 156, 0}
-"uuml", {195, 188, 0}
-"uwangle", {226, 166, 167, 0}
-"vangrt", {226, 166, 156, 0}
-"varepsilon", {207, 181, 0}
-"varkappa", {207, 176, 0}
-"varnothing", {226, 136, 133, 0}
-"varphi", {207, 149, 0}
-"varpi", {207, 150, 0}
-"varpropto", {226, 136, 157, 0}
-"varr", {226, 134, 149, 0}
-"vArr", {226, 135, 149, 0}
-"varrho", {207, 177, 0}
-"varsigma", {207, 130, 0}
-"varsubsetneq", {226, 138, 138, 0}
-"varsubsetneqq", {226, 171, 139, 0}
-"varsupsetneq", {226, 138, 139, 0}
-"varsupsetneqq", {226, 171, 140, 0}
-"vartheta", {207, 145, 0}
-"vartriangleleft", {226, 138, 178, 0}
-"vartriangleright", {226, 138, 179, 0}
-"vBar", {226, 171, 168, 0}
-"Vbar", {226, 171, 171, 0}
-"vBarv", {226, 171, 169, 0}
-"Vcy", {208, 146, 0}
-"vcy", {208, 178, 0}
-"vdash", {226, 138, 162, 0}
-"vDash", {226, 138, 168, 0}
-"Vdash", {226, 138, 169, 0}
-"VDash", {226, 138, 171, 0}
-"Vdashl", {226, 171, 166, 0}
-"veebar", {226, 138, 187, 0}
-"vee", {226, 136, 168, 0}
-"Vee", {226, 139, 129, 0}
-"veeeq", {226, 137, 154, 0}
-"vellip", {226, 139, 174, 0}
-"verbar", {124, 0}
-"Verbar", {226, 128, 150, 0}
-"vert", {124, 0}
-"Vert", {226, 128, 150, 0}
-"VerticalBar", {226, 136, 163, 0}
-"VerticalLine", {124, 0}
-"VerticalSeparator", {226, 157, 152, 0}
-"VerticalTilde", {226, 137, 128, 0}
-"VeryThinSpace", {226, 128, 138, 0}
-"Vfr", {240, 157, 148, 153}
-"vfr", {240, 157, 148, 179}
-"vltri", {226, 138, 178, 0}
-"vnsub", {226, 138, 130, 0}
-"vnsup", {226, 138, 131, 0}
-"Vopf", {240, 157, 149, 141}
-"vopf", {240, 157, 149, 167}
-"vprop", {226, 136, 157, 0}
-"vrtri", {226, 138, 179, 0}
-"Vscr", {240, 157, 146, 177}
-"vscr", {240, 157, 147, 139}
-"vsubnE", {226, 171, 139, 0}
-"vsubne", {226, 138, 138, 0}
-"vsupnE", {226, 171, 140, 0}
-"vsupne", {226, 138, 139, 0}
-"Vvdash", {226, 138, 170, 0}
-"vzigzag", {226, 166, 154, 0}
-"Wcirc", {197, 180, 0}
-"wcirc", {197, 181, 0}
-"wedbar", {226, 169, 159, 0}
-"wedge", {226, 136, 167, 0}
-"Wedge", {226, 139, 128, 0}
-"wedgeq", {226, 137, 153, 0}
-"weierp", {226, 132, 152, 0}
-"Wfr", {240, 157, 148, 154}
-"wfr", {240, 157, 148, 180}
-"Wopf", {240, 157, 149, 142}
-"wopf", {240, 157, 149, 168}
-"wp", {226, 132, 152, 0}
-"wr", {226, 137, 128, 0}
-"wreath", {226, 137, 128, 0}
-"Wscr", {240, 157, 146, 178}
-"wscr", {240, 157, 147, 140}
-"xcap", {226, 139, 130, 0}
-"xcirc", {226, 151, 175, 0}
-"xcup", {226, 139, 131, 0}
-"xdtri", {226, 150, 189, 0}
-"Xfr", {240, 157, 148, 155}
-"xfr", {240, 157, 148, 181}
-"xharr", {226, 159, 183, 0}
-"xhArr", {226, 159, 186, 0}
-"Xi", {206, 158, 0}
-"xi", {206, 190, 0}
-"xlarr", {226, 159, 181, 0}
-"xlArr", {226, 159, 184, 0}
-"xmap", {226, 159, 188, 0}
-"xnis", {226, 139, 187, 0}
-"xodot", {226, 168, 128, 0}
-"Xopf", {240, 157, 149, 143}
-"xopf", {240, 157, 149, 169}
-"xoplus", {226, 168, 129, 0}
-"xotime", {226, 168, 130, 0}
-"xrarr", {226, 159, 182, 0}
-"xrArr", {226, 159, 185, 0}
-"Xscr", {240, 157, 146, 179}
-"xscr", {240, 157, 147, 141}
-"xsqcup", {226, 168, 134, 0}
-"xuplus", {226, 168, 132, 0}
-"xutri", {226, 150, 179, 0}
-"xvee", {226, 139, 129, 0}
-"xwedge", {226, 139, 128, 0}
-"Yacute", {195, 157, 0}
-"yacute", {195, 189, 0}
-"YAcy", {208, 175, 0}
-"yacy", {209, 143, 0}
-"Ycirc", {197, 182, 0}
-"ycirc", {197, 183, 0}
-"Ycy", {208, 171, 0}
-"ycy", {209, 139, 0}
-"yen", {194, 165, 0}
-"Yfr", {240, 157, 148, 156}
-"yfr", {240, 157, 148, 182}
-"YIcy", {208, 135, 0}
-"yicy", {209, 151, 0}
-"Yopf", {240, 157, 149, 144}
-"yopf", {240, 157, 149, 170}
-"Yscr", {240, 157, 146, 180}
-"yscr", {240, 157, 147, 142}
-"YUcy", {208, 174, 0}
-"yucy", {209, 142, 0}
-"yuml", {195, 191, 0}
-"Yuml", {197, 184, 0}
-"Zacute", {197, 185, 0}
-"zacute", {197, 186, 0}
-"Zcaron", {197, 189, 0}
-"zcaron", {197, 190, 0}
-"Zcy", {208, 151, 0}
-"zcy", {208, 183, 0}
-"Zdot", {197, 187, 0}
-"zdot", {197, 188, 0}
-"zeetrf", {226, 132, 168, 0}
-"ZeroWidthSpace", {226, 128, 139, 0}
-"Zeta", {206, 150, 0}
-"zeta", {206, 182, 0}
-"zfr", {240, 157, 148, 183}
-"Zfr", {226, 132, 168, 0}
-"ZHcy", {208, 150, 0}
-"zhcy", {208, 182, 0}
-"zigrarr", {226, 135, 157, 0}
-"zopf", {240, 157, 149, 171}
-"Zopf", {226, 132, 164, 0}
-"Zscr", {240, 157, 146, 181}
-"zscr", {240, 157, 147, 143}
-"zwj", {226, 128, 141, 0}
-"zwnj", {226, 128, 140, 0}


[14/20] lucy-clownfish git commit: Rework display of class attributes in HTML docs

Posted by nw...@apache.org.
Rework display of class attributes in HTML docs


Project: http://git-wip-us.apache.org/repos/asf/lucy-clownfish/repo
Commit: http://git-wip-us.apache.org/repos/asf/lucy-clownfish/commit/ef144277
Tree: http://git-wip-us.apache.org/repos/asf/lucy-clownfish/tree/ef144277
Diff: http://git-wip-us.apache.org/repos/asf/lucy-clownfish/diff/ef144277

Branch: refs/heads/master
Commit: ef144277fe7bd622155a1f81dadd040306443bc4
Parents: 6c9b0ed
Author: Nick Wellnhofer <we...@aevum.de>
Authored: Sat Jul 25 19:27:53 2015 +0200
Committer: Nick Wellnhofer <we...@aevum.de>
Committed: Thu Aug 6 18:19:19 2015 +0200

----------------------------------------------------------------------
 compiler/src/CFCCHtml.c | 29 ++++++++++++++---------------
 1 file changed, 14 insertions(+), 15 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/lucy-clownfish/blob/ef144277/compiler/src/CFCCHtml.c
----------------------------------------------------------------------
diff --git a/compiler/src/CFCCHtml.c b/compiler/src/CFCCHtml.c
index e320ad9..0697754 100644
--- a/compiler/src/CFCCHtml.c
+++ b/compiler/src/CFCCHtml.c
@@ -343,10 +343,12 @@ char*
 CFCCHtml_create_html_body(CFCClass *klass) {
     CFCParcel  *parcel         = CFCClass_get_parcel(klass);
     const char *parcel_name    = CFCParcel_get_name(parcel);
+    const char *prefix         = CFCClass_get_prefix(klass);
+    const char *PREFIX         = CFCClass_get_PREFIX(klass);
     const char *class_name     = CFCClass_get_name(klass);
     const char *class_nickname = CFCClass_get_nickname(klass);
-    const char *class_var      = CFCClass_full_class_var(klass);
-    const char *struct_sym     = CFCClass_full_struct_sym(klass);
+    const char *class_var      = CFCClass_short_class_var(klass);
+    const char *struct_sym     = CFCClass_get_struct_sym(klass);
     const char *include_h      = CFCClass_include_h(klass);
 
     // Create NAME.
@@ -378,20 +380,16 @@ CFCCHtml_create_html_body(CFCClass *klass) {
         "<td><a href=\"%s\">%s</a></td>\n"
         "</tr>\n"
         "<tr>\n"
-        "<td class=\"label\">class name</td>\n"
-        "<td>%s</td>\n"
-        "</tr>\n"
-        "<tr>\n"
-        "<td class=\"label\">class nickname</td>\n"
-        "<td>%s</td>\n"
-        "</tr>\n"
-        "<tr>\n"
         "<td class=\"label\">class variable</td>\n"
-        "<td><code>%s</code></td>\n"
+        "<td><code><span class=\"prefix\">%s</span>%s</code></td>\n"
         "</tr>\n"
         "<tr>\n"
         "<td class=\"label\">struct symbol</td>\n"
-        "<td><code>%s</code></td>\n"
+        "<td><code><span class=\"prefix\">%s</span>%s</code></td>\n"
+        "</tr>\n"
+        "<tr>\n"
+        "<td class=\"label\">class nickname</td>\n"
+        "<td><code><span class=\"prefix\">%s</span>%s</code></td>\n"
         "</tr>\n"
         "<tr>\n"
         "<td class=\"label\">header file</td>\n"
@@ -406,9 +404,10 @@ CFCCHtml_create_html_body(CFCClass *klass) {
         "%s";
     char *html_body
         = CFCUtil_sprintf(pattern, class_name, index_filename,
-                          parcel_name, class_name, class_nickname, class_var,
-                          struct_sym, include_h, name, synopsis, description,
-                          functions_html, methods_html, inheritance);
+                          parcel_name, PREFIX, class_var, prefix, struct_sym,
+                          prefix, class_nickname, include_h, name, synopsis,
+                          description, functions_html, methods_html,
+                          inheritance);
 
     FREEMEM(index_filename);
     FREEMEM(name);