"Fossies" - the Fresh Open Source Software Archive

Member "highlight-3.57-x64/langDefs/rs.lang" (12 May 2020, 1440 Bytes) of package /windows/www/highlight-3.57-x64.zip:


As a special service "Fossies" has tried to format the requested text file into HTML format (style: standard) with prefixed line numbers. Alternatively you can here view or download the uninterpreted source code file. See also the last Fossies "Diffs" side-by-side code changes report for "rs.lang": 3.53_vs_3.54.

    1 
    2 Description="Rust"
    3 
    4 Categories = {"source"}
    5 
    6 Digits=[[ (?:0x|0o|0b)[0-9a-fA-F\_uif]+|\d+[\.]?[\d\_uif]+(?:[eE][\-\+][\d\_uif]+)?|\d+ ]]
    7 
    8 Keywords={
    9   { Id=1,
   10     List={"as", "box", "break", "const", "continue", "crate", "else",
   11           "extern", "false", "fn", "for", "if", "impl", "in", "let", "loop",
   12           "match", "mod", "move", "mut", "pub", "ref", "return", "self",
   13           "Self", "static", "super", "trait", "true", "type",
   14           "unsafe", "use", "where", "while", "abstract", "alignof", "become",
   15           "do", "final", "macro", "offsetof", "override", "priv", "pure",
   16           "sizeof", "typeof", "unsized", "virtual", "yield", "auto", "catch"
   17         }
   18   },
   19   { Id=2,
   20     List= { "u8", "u16", "u32", "u64", "i8", "i16", "i32", "i64",
   21             "f32", "f64", "usize", "isize", "char", "str", "struct","enum"
   22           }
   23   },
   24 
   25   -- weak keywords
   26   { Id=3,
   27     List= { "default", "dyn", "union"
   28           }
   29   },
   30   { Id=4,
   31     Regex=[[(\w+)\s*\(]]
   32   }
   33 }
   34 
   35 Strings = {
   36   Delimiter=[["]],
   37   RawPrefix="r",
   38   Escape = [[ \\[\'\\\"aftnrv]|\\U\{[0-9a-fA-F]{8}\}|\\u\{[0-9a-fA-F]{4}\}|\\x?? ]]
   39 }
   40 
   41 Comments = {
   42   { Block=true,
   43     Nested=true,
   44     Delimiter = { [[\/\*]], [[\*\/]] }
   45   },
   46   {
   47     Block=false,
   48     Delimiter = { [[//]] }
   49   }
   50 }
   51 
   52 IgnoreCase=false
   53 
   54 PreProcessor = {
   55   Prefix=[[#]],
   56   Continuation="\\",
   57 }
   58 
   59 Operators=[[\(|\)|\[|\]|\{|\}|\,|\;|\.|\:|\&|<|>|\!|=|\/|\*|\%|\+|\-|\~|\||\^']]
   60 
   61 EnableIndentation=true