l0bsterssg

node.js static responsive blog post generator
Log | Files | Refs | README

vbnet.js (2844B)


      1 /*
      2 Language: Visual Basic .NET
      3 Description: Visual Basic .NET (VB.NET) is a multi-paradigm, object-oriented programming language, implemented on the .NET Framework.
      4 Author: Poren Chiang <ren.chiang@gmail.com>
      5 Website: https://docs.microsoft.com/en-us/dotnet/visual-basic/getting-started/
      6 */
      7 
      8 function vbnet(hljs) {
      9   return {
     10     name: 'Visual Basic .NET',
     11     aliases: ['vb'],
     12     case_insensitive: true,
     13     keywords: {
     14       keyword:
     15         'addhandler addressof alias and andalso aggregate ansi as async assembly auto await binary by byref byval ' + /* a-b */
     16         'call case catch class compare const continue custom declare default delegate dim distinct do ' + /* c-d */
     17         'each equals else elseif end enum erase error event exit explicit finally for friend from function ' + /* e-f */
     18         'get global goto group handles if implements imports in inherits interface into is isfalse isnot istrue iterator ' + /* g-i */
     19         'join key let lib like loop me mid mod module mustinherit mustoverride mybase myclass ' + /* j-m */
     20         'nameof namespace narrowing new next not notinheritable notoverridable ' + /* n */
     21         'of off on operator option optional or order orelse overloads overridable overrides ' + /* o */
     22         'paramarray partial preserve private property protected public ' + /* p */
     23         'raiseevent readonly redim rem removehandler resume return ' + /* r */
     24         'select set shadows shared skip static step stop structure strict sub synclock ' + /* s */
     25         'take text then throw to try unicode until using when where while widening with withevents writeonly xor yield', /* t-y */
     26       built_in:
     27         'boolean byte cbool cbyte cchar cdate cdec cdbl char cint clng cobj csbyte cshort csng cstr ctype ' +  /* b-c */
     28         'date decimal directcast double gettype getxmlnamespace iif integer long object ' + /* d-o */
     29         'sbyte short single string trycast typeof uinteger ulong ushort', /* s-u */
     30       literal:
     31         'true false nothing'
     32     },
     33     illegal: '//|{|}|endif|gosub|variant|wend|^\\$ ', /* reserved deprecated keywords */
     34     contains: [
     35       hljs.inherit(hljs.QUOTE_STRING_MODE, {contains: [{begin: '""'}]}),
     36       hljs.COMMENT(
     37         '\'',
     38         '$',
     39         {
     40           returnBegin: true,
     41           contains: [
     42             {
     43               className: 'doctag',
     44               begin: '\'\'\'|<!--|-->',
     45               contains: [hljs.PHRASAL_WORDS_MODE]
     46             },
     47             {
     48               className: 'doctag',
     49               begin: '</?', end: '>',
     50               contains: [hljs.PHRASAL_WORDS_MODE]
     51             }
     52           ]
     53         }
     54       ),
     55       hljs.C_NUMBER_MODE,
     56       {
     57         className: 'meta',
     58         begin: '#', end: '$',
     59         keywords: {'meta-keyword': 'if else elseif end region externalsource'}
     60       }
     61     ]
     62   };
     63 }
     64 
     65 module.exports = vbnet;