123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284 |
- <?php
- /*************************************************************************************
- * d.php
- * -----
- * Author: Thomas Kuehne (thomas@kuehne.cn)
- * Copyright: (c) 2005 Thomas Kuehne (http://thomas.kuehne.cn/)
- * Release Version: 1.0.7.21
- * Date Started: 2005/04/22
- *
- * D language file for GeSHi.
- *
- * CHANGES
- * -------
- * 2005/04/22 (0.0.2)
- * - added _d_* and sizeof/ptrdiff_t
- * 2005/04/20 (0.0.1)
- * - First release
- *
- * TODO (updated 2005/04/22)
- * -------------------------
- * * nested comments
- * * correct handling of r"" and ``
- * * correct handling of ... and ..
- *
- *************************************************************************************
- *
- * This file is part of GeSHi.
- *
- * GeSHi is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation; either version 2 of the License, or
- * (at your option) any later version.
- *
- * GeSHi is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- * GNU General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License
- * along with GeSHi; if not, write to the Free Software
- * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
- *
- ************************************************************************************/
-
- $language_data = array(
- 'LANG_NAME' => 'D',
- 'COMMENT_SINGLE' => array(1 => '//'),
- 'COMMENT_MULTI' => array('/*' => '*/'),
- 'CASE_KEYWORDS' => GESHI_CAPS_NO_CHANGE,
- 'QUOTEMARKS' => array('"', "'", '`'),
- 'ESCAPE_CHAR' => '\\',
- 'KEYWORDS' => array(
- 1 => array(
- 'while',
- 'switch',
- 'if',
- 'foreach',
- 'for',
- 'goto',
- 'return',
- 'else',
- 'do',
- 'case',
- 'continue',
- 'break'
- ),
- 2 => array(
- 'with',
- 'union',
- 'typeof',
- 'typeid',
- 'typedef',
- 'try',
- 'true',
- 'throw',
- 'this',
- 'super',
- 'pragma',
- 'out',
- 'null',
- 'new',
- 'module',
- 'mixin',
- 'is',
- 'invariant',
- 'interface',
- 'inout',
- 'in',
- 'import',
- 'function',
- 'finally',
- 'false',
- 'extern',
- 'delete',
- 'delegate',
- 'default',
- 'catch',
- 'cast',
- 'body',
- 'assert',
- 'asm',
- 'alias'
- ),
- 3 => array(
- 'TypeInfo',
- 'SwitchError',
- 'OutOfMemoryException',
- 'Object',
- 'ModuleInfo',
- 'Interface',
- 'Exception',
- 'Error',
- 'ClassInfo',
- 'ArrayBoundsError',
- 'AssertError',
- '_d_throw',
- '_d_switch_ustring',
- '_d_switch_string',
- '_d_switch_dstring',
- '_d_OutOfMemory',
- '_d_obj_eq',
- '_d_obj_cmp',
- '_d_newclass',
- '_d_newbitarray',
- '_d_newarrayi',
- '_d_new',
- '_d_monitorrelease',
- '_d_monitor_prolog',
- '_d_monitor_handler',
- '_d_monitorexit',
- '_d_monitor_epilog',
- '_d_monitorenter',
- '_d_local_unwind',
- '_d_isbaseof2',
- '_d_isbaseof',
- '_d_invariant',
- '_d_interface_vtbl',
- '_d_interface_cast',
- '_d_framehandler',
- '_d_exception_filter',
- '_d_exception',
- '_d_dynamic_cast',
- '_d_delmemory',
- '_d_delinterface',
- '_d_delclass',
- '_d_delarray',
- '_d_criticalexit',
- '_d_criticalenter',
- '_d_create_exception_object',
- '_d_callfinalizer',
- '_d_arraysetlengthb',
- '_d_arraysetlength',
- '_d_arraysetbit2',
- '_d_arraysetbit',
- '_d_arraycopybit',
- '_d_arraycopy',
- '_d_arraycatn',
- '_d_arraycatb',
- '_d_arraycat',
- '_d_arraycast_frombit',
- '_d_arraycast',
- '_d_arrayappendcb',
- '_d_arrayappendc',
- '_d_arrayappendb',
- '_d_arrayappend',
- ),
- 4 => array(
- 'wchar',
- 'volatile',
- 'void',
- 'version',
- 'ushort',
- 'unittest',
- 'ulong',
- 'uint',
- 'ucent',
- 'ubyte',
- 'template',
- 'struct',
- 'static',
- 'synchronized',
- 'size_t',
- 'short',
- 'real',
- 'public',
- 'protected',
- 'private',
- 'ptrdiff_t',
- 'package',
- 'override',
- 'long',
- 'int',
- 'ireal',
- 'ifloat',
- 'idouble',
- 'float',
- 'final',
- 'export',
- 'enum',
- 'double',
- 'deprecated',
- 'debug',
- 'dchar',
- 'creal',
- 'const',
- 'class',
- 'char',
- 'cfloat',
- 'cent',
- 'cdouble',
- 'byte',
- 'bool',
- 'bit',
- 'auto',
- 'align',
- 'abstract'
- )
- ),
- 'SYMBOLS' => array(
- '(', ')', '[', ']', '{', '}', '?', '!', ';', ':', ',', '...', '..',
- '+', '-', '*', '/', '%', '&', '|', '^', '<', '>', '=', '~',
- ),
- 'CASE_SENSITIVE' => array(
- GESHI_COMMENTS => true,
- 1 => true,
- 2 => true,
- 3 => true,
- 4 => true
- ),
- 'STYLES' => array(
- 'KEYWORDS' => array(
- 1 => 'color: #b1b100;',
- 2 => 'color: #000000; font-weight: bold;',
- 3 => 'color: #aaaadd; font-weight: bold;',
- 4 => 'color: #993333;'
- ),
- 'COMMENTS' => array(
- 1=> 'color: #808080; font-style: italic;',
- 2=> 'color: #a1a100;',
- 'MULTI' => 'color: #808080; font-style: italic;'
- ),
- 'ESCAPE_CHAR' => array(
- 0 => 'color: #000099; font-weight: bold;'
- ),
- 'BRACKETS' => array(
- 0 => 'color: #66cc66;'
- ),
- 'STRINGS' => array(
- 0 => 'color: #ff0000;'
- ),
- 'NUMBERS' => array(
- 0 => 'color: #cc66cc;'
- ),
- 'METHODS' => array(
- 1 => 'color: #006600;',
- 2 => 'color: #006600;'
- ),
- 'SYMBOLS' => array(
- 0 => 'color: #66cc66;'
- ),
- 'SCRIPT' => array(
- ),
- 'REGEXPS' => array(
- )
- ),
- 'URLS' => array(
- 1 => '',
- 2 => '',
- 3 => '',
- 4 => ''
- ),
- 'OOLANG' => true,
- 'OBJECT_SPLITTERS' => array(
- 1 => '.',
- ),
- 'REGEXPS' => array(
- ),
- 'STRICT_MODE_APPLIES' => GESHI_NEVER,
- 'SCRIPT_DELIMITERS' => array(
- ),
- 'HIGHLIGHT_STRICT_BLOCK' => array(
- )
- );
|