...

Text file src/github.com/alecthomas/chroma/lexers/testdata/php.expected

Documentation: github.com/alecthomas/chroma/lexers/testdata

     1[
     2  {"type":"NameVariable","value":"$docs"},
     3  {"type":"Text","value":" "},
     4  {"type":"Operator","value":"="},
     5  {"type":"Text","value":" "},
     6  {"type":"NameVariable","value":"$modx"},
     7  {"type":"Operator","value":"-\u003e"},
     8  {"type":"NameAttribute","value":"getIterator"},
     9  {"type":"Punctuation","value":"("},
    10  {"type":"LiteralStringSingle","value":"'modResource'"},
    11  {"type":"Punctuation","value":","},
    12  {"type":"Text","value":" "},
    13  {"type":"Punctuation","value":"["},
    14  {"type":"LiteralStringDouble","value":"\"parent\""},
    15  {"type":"Text","value":" "},
    16  {"type":"Operator","value":"=\u003e"},
    17  {"type":"Text","value":" "},
    18  {"type":"LiteralNumberInteger","value":"84"},
    19  {"type":"Punctuation","value":"]);"},
    20  {"type":"Text","value":"\n\n"},
    21  {"type":"NameVariable","value":"$n"},
    22  {"type":"Text","value":" "},
    23  {"type":"Operator","value":"="},
    24  {"type":"Text","value":" "},
    25  {"type":"LiteralNumberHex","value":"0x21"},
    26  {"type":"Text","value":" "},
    27  {"type":"Operator","value":"+"},
    28  {"type":"Text","value":" "},
    29  {"type":"LiteralNumberInteger","value":"1_000"},
    30  {"type":"Punctuation","value":";"},
    31  {"type":"Text","value":"\n"},
    32  {"type":"NameVariable","value":"$n2"},
    33  {"type":"Text","value":" "},
    34  {"type":"Operator","value":"="},
    35  {"type":"Text","value":" "},
    36  {"type":"LiteralNumberFloat","value":"1e3"},
    37  {"type":"Punctuation","value":";"},
    38  {"type":"Text","value":"\n\n"},
    39  {"type":"Keyword","value":"foreach"},
    40  {"type":"Punctuation","value":"("},
    41  {"type":"NameVariable","value":"$docs"},
    42  {"type":"Text","value":" "},
    43  {"type":"Keyword","value":"as"},
    44  {"type":"Text","value":" "},
    45  {"type":"NameVariable","value":"$doc"},
    46  {"type":"Punctuation","value":"){"},
    47  {"type":"Text","value":"\n    "},
    48  {"type":"NameVariable","value":"$q"},
    49  {"type":"Operator","value":"="},
    50  {"type":"NameVariable","value":"$doc"},
    51  {"type":"Operator","value":"-\u003e"},
    52  {"type":"NameAttribute","value":"content"},
    53  {"type":"Punctuation","value":";"},
    54  {"type":"Text","value":"\n    "},
    55  {"type":"NameVariable","value":"$doc"},
    56  {"type":"Operator","value":"-\u003e"},
    57  {"type":"NameAttribute","value":"set"},
    58  {"type":"Punctuation","value":"("},
    59  {"type":"LiteralStringDouble","value":"\"content\""},
    60  {"type":"Punctuation","value":","},
    61  {"type":"Text","value":" "},
    62  {"type":"NameOther","value":"preg_replace"},
    63  {"type":"Punctuation","value":"("},
    64  {"type":"LiteralStringDouble","value":"\"/Some value/i\""},
    65  {"type":"Punctuation","value":","},
    66  {"type":"Text","value":" "},
    67  {"type":"LiteralStringDouble","value":"\"Replacement\""},
    68  {"type":"Punctuation","value":","},
    69  {"type":"Text","value":" "},
    70  {"type":"NameVariable","value":"$q"},
    71  {"type":"Punctuation","value":"));"},
    72  {"type":"Text","value":"\n    "},
    73  {"type":"NameOther","value":"print_r"},
    74  {"type":"Punctuation","value":"("},
    75  {"type":"NameVariable","value":"$doc"},
    76  {"type":"Operator","value":"-\u003e"},
    77  {"type":"NameAttribute","value":"content"},
    78  {"type":"Punctuation","value":");"},
    79  {"type":"Text","value":"\n    "},
    80  {"type":"CommentSingle","value":"// $doc-\u003esave();\n"},
    81  {"type":"Punctuation","value":"}"},
    82  {"type":"Text","value":"\n"},
    83  {"type":"CommentSingle","value":"// some comment\n"}
    84]

View as plain text