From a1c187eef3ba08076aedb5154929f7eda8d1b424 Mon Sep 17 00:00:00 2001 From: Aleksey Kladov Date: Wed, 12 Aug 2020 18:26:51 +0200 Subject: Rename ra_syntax -> syntax --- .../lexer/err/0001_unclosed_char_at_eof.rs | 1 + .../lexer/err/0001_unclosed_char_at_eof.txt | 2 + .../lexer/err/0002_unclosed_char_with_ferris.rs | 1 + .../lexer/err/0002_unclosed_char_with_ferris.txt | 2 + .../err/0003_unclosed_char_with_ascii_escape.rs | 1 + .../err/0003_unclosed_char_with_ascii_escape.txt | 2 + .../err/0004_unclosed_char_with_unicode_escape.rs | 1 + .../err/0004_unclosed_char_with_unicode_escape.txt | 2 + .../lexer/err/0005_unclosed_char_with_space.rs | 1 + .../lexer/err/0005_unclosed_char_with_space.txt | 2 + .../lexer/err/0006_unclosed_char_with_slash.rs | 1 + .../lexer/err/0006_unclosed_char_with_slash.txt | 2 + .../lexer/err/0007_unclosed_char_with_slash_n.rs | 1 + .../lexer/err/0007_unclosed_char_with_slash_n.txt | 2 + .../0008_unclosed_char_with_slash_single_quote.rs | 1 + .../0008_unclosed_char_with_slash_single_quote.txt | 2 + .../lexer/err/0009_unclosed_byte_at_eof.rs | 1 + .../lexer/err/0009_unclosed_byte_at_eof.txt | 2 + .../lexer/err/0010_unclosed_byte_with_ferris.rs | 1 + .../lexer/err/0010_unclosed_byte_with_ferris.txt | 2 + .../err/0011_unclosed_byte_with_ascii_escape.rs | 1 + .../err/0011_unclosed_byte_with_ascii_escape.txt | 2 + .../err/0012_unclosed_byte_with_unicode_escape.rs | 1 + .../err/0012_unclosed_byte_with_unicode_escape.txt | 2 + .../lexer/err/0013_unclosed_byte_with_space.rs | 1 + .../lexer/err/0013_unclosed_byte_with_space.txt | 2 + .../lexer/err/0014_unclosed_byte_with_slash.rs | 1 + .../lexer/err/0014_unclosed_byte_with_slash.txt | 2 + .../lexer/err/0015_unclosed_byte_with_slash_n.rs | 1 + .../lexer/err/0015_unclosed_byte_with_slash_n.txt | 2 + .../0016_unclosed_byte_with_slash_single_quote.rs | 1 + .../0016_unclosed_byte_with_slash_single_quote.txt | 2 + .../lexer/err/0017_unclosed_string_at_eof.rs | 1 + .../lexer/err/0017_unclosed_string_at_eof.txt | 2 + .../lexer/err/0018_unclosed_string_with_ferris.rs | 1 + .../lexer/err/0018_unclosed_string_with_ferris.txt | 2 + .../err/0019_unclosed_string_with_ascii_escape.rs | 1 + .../err/0019_unclosed_string_with_ascii_escape.txt | 2 + .../0020_unclosed_string_with_unicode_escape.rs | 1 + .../0020_unclosed_string_with_unicode_escape.txt | 2 + .../lexer/err/0021_unclosed_string_with_space.rs | 1 + .../lexer/err/0021_unclosed_string_with_space.txt | 2 + .../lexer/err/0022_unclosed_string_with_slash.rs | 1 + .../lexer/err/0022_unclosed_string_with_slash.txt | 2 + .../lexer/err/0023_unclosed_string_with_slash_n.rs | 1 + .../err/0023_unclosed_string_with_slash_n.txt | 2 + ...0024_unclosed_string_with_slash_double_quote.rs | 1 + ...024_unclosed_string_with_slash_double_quote.txt | 2 + .../lexer/err/0025_unclosed_byte_string_at_eof.rs | 1 + .../lexer/err/0025_unclosed_byte_string_at_eof.txt | 2 + .../err/0026_unclosed_byte_string_with_ferris.rs | 1 + .../err/0026_unclosed_byte_string_with_ferris.txt | 2 + .../0027_unclosed_byte_string_with_ascii_escape.rs | 1 + ...0027_unclosed_byte_string_with_ascii_escape.txt | 2 + ...028_unclosed_byte_string_with_unicode_escape.rs | 1 + ...28_unclosed_byte_string_with_unicode_escape.txt | 2 + .../err/0029_unclosed_byte_string_with_space.rs | 1 + .../err/0029_unclosed_byte_string_with_space.txt | 2 + .../err/0030_unclosed_byte_string_with_slash.rs | 1 + .../err/0030_unclosed_byte_string_with_slash.txt | 2 + .../err/0031_unclosed_byte_string_with_slash_n.rs | 1 + .../err/0031_unclosed_byte_string_with_slash_n.txt | 2 + ...unclosed_byte_string_with_slash_double_quote.rs | 1 + ...nclosed_byte_string_with_slash_double_quote.txt | 2 + .../lexer/err/0033_unclosed_raw_string_at_eof.rs | 1 + .../lexer/err/0033_unclosed_raw_string_at_eof.txt | 2 + .../err/0034_unclosed_raw_string_with_ferris.rs | 1 + .../err/0034_unclosed_raw_string_with_ferris.txt | 2 + .../0035_unclosed_raw_string_with_ascii_escape.rs | 1 + .../0035_unclosed_raw_string_with_ascii_escape.txt | 2 + ...0036_unclosed_raw_string_with_unicode_escape.rs | 1 + ...036_unclosed_raw_string_with_unicode_escape.txt | 2 + .../err/0037_unclosed_raw_string_with_space.rs | 1 + .../err/0037_unclosed_raw_string_with_space.txt | 2 + .../err/0038_unclosed_raw_string_with_slash.rs | 1 + .../err/0038_unclosed_raw_string_with_slash.txt | 2 + .../err/0039_unclosed_raw_string_with_slash_n.rs | 1 + .../err/0039_unclosed_raw_string_with_slash_n.txt | 2 + .../err/0040_unclosed_raw_byte_string_at_eof.rs | 1 + .../err/0040_unclosed_raw_byte_string_at_eof.txt | 2 + .../0041_unclosed_raw_byte_string_with_ferris.rs | 1 + .../0041_unclosed_raw_byte_string_with_ferris.txt | 2 + ...2_unclosed_raw_byte_string_with_ascii_escape.rs | 1 + ..._unclosed_raw_byte_string_with_ascii_escape.txt | 2 + ...unclosed_raw_byte_string_with_unicode_escape.rs | 1 + ...nclosed_raw_byte_string_with_unicode_escape.txt | 2 + .../0044_unclosed_raw_byte_string_with_space.rs | 1 + .../0044_unclosed_raw_byte_string_with_space.txt | 2 + .../0045_unclosed_raw_byte_string_with_slash.rs | 1 + .../0045_unclosed_raw_byte_string_with_slash.txt | 2 + .../0046_unclosed_raw_byte_string_with_slash_n.rs | 1 + .../0046_unclosed_raw_byte_string_with_slash_n.txt | 2 + .../lexer/err/0047_unstarted_raw_string_at_eof.rs | 1 + .../lexer/err/0047_unstarted_raw_string_at_eof.txt | 2 + .../err/0048_unstarted_raw_byte_string_at_eof.rs | 1 + .../err/0048_unstarted_raw_byte_string_at_eof.txt | 2 + .../err/0049_unstarted_raw_string_with_ascii.rs | 1 + .../err/0049_unstarted_raw_string_with_ascii.txt | 10 +++ .../0050_unstarted_raw_byte_string_with_ascii.rs | 1 + .../0050_unstarted_raw_byte_string_with_ascii.txt | 10 +++ .../err/0051_unclosed_block_comment_at_eof.rs | 1 + .../err/0051_unclosed_block_comment_at_eof.txt | 2 + .../0052_unclosed_block_comment_with_content.rs | 1 + .../0052_unclosed_block_comment_with_content.txt | 2 + .../0053_unclosed_nested_block_comment_entirely.rs | 1 + ...0053_unclosed_nested_block_comment_entirely.txt | 2 + ...0054_unclosed_nested_block_comment_partially.rs | 1 + ...054_unclosed_nested_block_comment_partially.txt | 2 + .../syntax/test_data/lexer/err/0055_empty_int.rs | 17 +++++ .../syntax/test_data/lexer/err/0055_empty_int.txt | 39 +++++++++++ .../test_data/lexer/err/0056_empty_exponent.rs | 22 +++++++ .../test_data/lexer/err/0056_empty_exponent.txt | 62 +++++++++++++++++ .../err/0057_lifetime_strarts_with_a_number.rs | 2 + .../err/0057_lifetime_strarts_with_a_number.txt | 6 ++ crates/syntax/test_data/lexer/ok/0001_hello.rs | 1 + crates/syntax/test_data/lexer/ok/0001_hello.txt | 3 + .../syntax/test_data/lexer/ok/0002_whitespace.rs | 4 ++ .../syntax/test_data/lexer/ok/0002_whitespace.txt | 12 ++++ crates/syntax/test_data/lexer/ok/0003_ident.rs | 1 + crates/syntax/test_data/lexer/ok/0003_ident.txt | 14 ++++ crates/syntax/test_data/lexer/ok/0004_numbers.rs | 9 +++ crates/syntax/test_data/lexer/ok/0004_numbers.txt | 57 ++++++++++++++++ crates/syntax/test_data/lexer/ok/0005_symbols.rs | 6 ++ crates/syntax/test_data/lexer/ok/0005_symbols.txt | 77 ++++++++++++++++++++++ crates/syntax/test_data/lexer/ok/0006_chars.rs | 1 + crates/syntax/test_data/lexer/ok/0006_chars.txt | 16 +++++ crates/syntax/test_data/lexer/ok/0007_lifetimes.rs | 1 + .../syntax/test_data/lexer/ok/0007_lifetimes.txt | 8 +++ .../syntax/test_data/lexer/ok/0008_byte_strings.rs | 3 + .../test_data/lexer/ok/0008_byte_strings.txt | 22 +++++++ crates/syntax/test_data/lexer/ok/0009_strings.rs | 2 + crates/syntax/test_data/lexer/ok/0009_strings.txt | 8 +++ .../lexer/ok/0010_single_line_comments.rs | 12 ++++ .../lexer/ok/0010_single_line_comments.txt | 22 +++++++ crates/syntax/test_data/lexer/ok/0011_keywords.rs | 3 + crates/syntax/test_data/lexer/ok/0011_keywords.txt | 64 ++++++++++++++++++ .../test_data/lexer/ok/0012_block_comment.rs | 3 + .../test_data/lexer/ok/0012_block_comment.txt | 6 ++ .../syntax/test_data/lexer/ok/0013_raw_strings.rs | 1 + .../syntax/test_data/lexer/ok/0013_raw_strings.txt | 2 + crates/syntax/test_data/lexer/ok/0014_raw_ident.rs | 1 + .../syntax/test_data/lexer/ok/0014_raw_ident.txt | 2 + 142 files changed, 687 insertions(+) create mode 100644 crates/syntax/test_data/lexer/err/0001_unclosed_char_at_eof.rs create mode 100644 crates/syntax/test_data/lexer/err/0001_unclosed_char_at_eof.txt create mode 100644 crates/syntax/test_data/lexer/err/0002_unclosed_char_with_ferris.rs create mode 100644 crates/syntax/test_data/lexer/err/0002_unclosed_char_with_ferris.txt create mode 100644 crates/syntax/test_data/lexer/err/0003_unclosed_char_with_ascii_escape.rs create mode 100644 crates/syntax/test_data/lexer/err/0003_unclosed_char_with_ascii_escape.txt create mode 100644 crates/syntax/test_data/lexer/err/0004_unclosed_char_with_unicode_escape.rs create mode 100644 crates/syntax/test_data/lexer/err/0004_unclosed_char_with_unicode_escape.txt create mode 100644 crates/syntax/test_data/lexer/err/0005_unclosed_char_with_space.rs create mode 100644 crates/syntax/test_data/lexer/err/0005_unclosed_char_with_space.txt create mode 100644 crates/syntax/test_data/lexer/err/0006_unclosed_char_with_slash.rs create mode 100644 crates/syntax/test_data/lexer/err/0006_unclosed_char_with_slash.txt create mode 100644 crates/syntax/test_data/lexer/err/0007_unclosed_char_with_slash_n.rs create mode 100644 crates/syntax/test_data/lexer/err/0007_unclosed_char_with_slash_n.txt create mode 100644 crates/syntax/test_data/lexer/err/0008_unclosed_char_with_slash_single_quote.rs create mode 100644 crates/syntax/test_data/lexer/err/0008_unclosed_char_with_slash_single_quote.txt create mode 100644 crates/syntax/test_data/lexer/err/0009_unclosed_byte_at_eof.rs create mode 100644 crates/syntax/test_data/lexer/err/0009_unclosed_byte_at_eof.txt create mode 100644 crates/syntax/test_data/lexer/err/0010_unclosed_byte_with_ferris.rs create mode 100644 crates/syntax/test_data/lexer/err/0010_unclosed_byte_with_ferris.txt create mode 100644 crates/syntax/test_data/lexer/err/0011_unclosed_byte_with_ascii_escape.rs create mode 100644 crates/syntax/test_data/lexer/err/0011_unclosed_byte_with_ascii_escape.txt create mode 100644 crates/syntax/test_data/lexer/err/0012_unclosed_byte_with_unicode_escape.rs create mode 100644 crates/syntax/test_data/lexer/err/0012_unclosed_byte_with_unicode_escape.txt create mode 100644 crates/syntax/test_data/lexer/err/0013_unclosed_byte_with_space.rs create mode 100644 crates/syntax/test_data/lexer/err/0013_unclosed_byte_with_space.txt create mode 100644 crates/syntax/test_data/lexer/err/0014_unclosed_byte_with_slash.rs create mode 100644 crates/syntax/test_data/lexer/err/0014_unclosed_byte_with_slash.txt create mode 100644 crates/syntax/test_data/lexer/err/0015_unclosed_byte_with_slash_n.rs create mode 100644 crates/syntax/test_data/lexer/err/0015_unclosed_byte_with_slash_n.txt create mode 100644 crates/syntax/test_data/lexer/err/0016_unclosed_byte_with_slash_single_quote.rs create mode 100644 crates/syntax/test_data/lexer/err/0016_unclosed_byte_with_slash_single_quote.txt create mode 100644 crates/syntax/test_data/lexer/err/0017_unclosed_string_at_eof.rs create mode 100644 crates/syntax/test_data/lexer/err/0017_unclosed_string_at_eof.txt create mode 100644 crates/syntax/test_data/lexer/err/0018_unclosed_string_with_ferris.rs create mode 100644 crates/syntax/test_data/lexer/err/0018_unclosed_string_with_ferris.txt create mode 100644 crates/syntax/test_data/lexer/err/0019_unclosed_string_with_ascii_escape.rs create mode 100644 crates/syntax/test_data/lexer/err/0019_unclosed_string_with_ascii_escape.txt create mode 100644 crates/syntax/test_data/lexer/err/0020_unclosed_string_with_unicode_escape.rs create mode 100644 crates/syntax/test_data/lexer/err/0020_unclosed_string_with_unicode_escape.txt create mode 100644 crates/syntax/test_data/lexer/err/0021_unclosed_string_with_space.rs create mode 100644 crates/syntax/test_data/lexer/err/0021_unclosed_string_with_space.txt create mode 100644 crates/syntax/test_data/lexer/err/0022_unclosed_string_with_slash.rs create mode 100644 crates/syntax/test_data/lexer/err/0022_unclosed_string_with_slash.txt create mode 100644 crates/syntax/test_data/lexer/err/0023_unclosed_string_with_slash_n.rs create mode 100644 crates/syntax/test_data/lexer/err/0023_unclosed_string_with_slash_n.txt create mode 100644 crates/syntax/test_data/lexer/err/0024_unclosed_string_with_slash_double_quote.rs create mode 100644 crates/syntax/test_data/lexer/err/0024_unclosed_string_with_slash_double_quote.txt create mode 100644 crates/syntax/test_data/lexer/err/0025_unclosed_byte_string_at_eof.rs create mode 100644 crates/syntax/test_data/lexer/err/0025_unclosed_byte_string_at_eof.txt create mode 100644 crates/syntax/test_data/lexer/err/0026_unclosed_byte_string_with_ferris.rs create mode 100644 crates/syntax/test_data/lexer/err/0026_unclosed_byte_string_with_ferris.txt create mode 100644 crates/syntax/test_data/lexer/err/0027_unclosed_byte_string_with_ascii_escape.rs create mode 100644 crates/syntax/test_data/lexer/err/0027_unclosed_byte_string_with_ascii_escape.txt create mode 100644 crates/syntax/test_data/lexer/err/0028_unclosed_byte_string_with_unicode_escape.rs create mode 100644 crates/syntax/test_data/lexer/err/0028_unclosed_byte_string_with_unicode_escape.txt create mode 100644 crates/syntax/test_data/lexer/err/0029_unclosed_byte_string_with_space.rs create mode 100644 crates/syntax/test_data/lexer/err/0029_unclosed_byte_string_with_space.txt create mode 100644 crates/syntax/test_data/lexer/err/0030_unclosed_byte_string_with_slash.rs create mode 100644 crates/syntax/test_data/lexer/err/0030_unclosed_byte_string_with_slash.txt create mode 100644 crates/syntax/test_data/lexer/err/0031_unclosed_byte_string_with_slash_n.rs create mode 100644 crates/syntax/test_data/lexer/err/0031_unclosed_byte_string_with_slash_n.txt create mode 100644 crates/syntax/test_data/lexer/err/0032_unclosed_byte_string_with_slash_double_quote.rs create mode 100644 crates/syntax/test_data/lexer/err/0032_unclosed_byte_string_with_slash_double_quote.txt create mode 100644 crates/syntax/test_data/lexer/err/0033_unclosed_raw_string_at_eof.rs create mode 100644 crates/syntax/test_data/lexer/err/0033_unclosed_raw_string_at_eof.txt create mode 100644 crates/syntax/test_data/lexer/err/0034_unclosed_raw_string_with_ferris.rs create mode 100644 crates/syntax/test_data/lexer/err/0034_unclosed_raw_string_with_ferris.txt create mode 100644 crates/syntax/test_data/lexer/err/0035_unclosed_raw_string_with_ascii_escape.rs create mode 100644 crates/syntax/test_data/lexer/err/0035_unclosed_raw_string_with_ascii_escape.txt create mode 100644 crates/syntax/test_data/lexer/err/0036_unclosed_raw_string_with_unicode_escape.rs create mode 100644 crates/syntax/test_data/lexer/err/0036_unclosed_raw_string_with_unicode_escape.txt create mode 100644 crates/syntax/test_data/lexer/err/0037_unclosed_raw_string_with_space.rs create mode 100644 crates/syntax/test_data/lexer/err/0037_unclosed_raw_string_with_space.txt create mode 100644 crates/syntax/test_data/lexer/err/0038_unclosed_raw_string_with_slash.rs create mode 100644 crates/syntax/test_data/lexer/err/0038_unclosed_raw_string_with_slash.txt create mode 100644 crates/syntax/test_data/lexer/err/0039_unclosed_raw_string_with_slash_n.rs create mode 100644 crates/syntax/test_data/lexer/err/0039_unclosed_raw_string_with_slash_n.txt create mode 100644 crates/syntax/test_data/lexer/err/0040_unclosed_raw_byte_string_at_eof.rs create mode 100644 crates/syntax/test_data/lexer/err/0040_unclosed_raw_byte_string_at_eof.txt create mode 100644 crates/syntax/test_data/lexer/err/0041_unclosed_raw_byte_string_with_ferris.rs create mode 100644 crates/syntax/test_data/lexer/err/0041_unclosed_raw_byte_string_with_ferris.txt create mode 100644 crates/syntax/test_data/lexer/err/0042_unclosed_raw_byte_string_with_ascii_escape.rs create mode 100644 crates/syntax/test_data/lexer/err/0042_unclosed_raw_byte_string_with_ascii_escape.txt create mode 100644 crates/syntax/test_data/lexer/err/0043_unclosed_raw_byte_string_with_unicode_escape.rs create mode 100644 crates/syntax/test_data/lexer/err/0043_unclosed_raw_byte_string_with_unicode_escape.txt create mode 100644 crates/syntax/test_data/lexer/err/0044_unclosed_raw_byte_string_with_space.rs create mode 100644 crates/syntax/test_data/lexer/err/0044_unclosed_raw_byte_string_with_space.txt create mode 100644 crates/syntax/test_data/lexer/err/0045_unclosed_raw_byte_string_with_slash.rs create mode 100644 crates/syntax/test_data/lexer/err/0045_unclosed_raw_byte_string_with_slash.txt create mode 100644 crates/syntax/test_data/lexer/err/0046_unclosed_raw_byte_string_with_slash_n.rs create mode 100644 crates/syntax/test_data/lexer/err/0046_unclosed_raw_byte_string_with_slash_n.txt create mode 100644 crates/syntax/test_data/lexer/err/0047_unstarted_raw_string_at_eof.rs create mode 100644 crates/syntax/test_data/lexer/err/0047_unstarted_raw_string_at_eof.txt create mode 100644 crates/syntax/test_data/lexer/err/0048_unstarted_raw_byte_string_at_eof.rs create mode 100644 crates/syntax/test_data/lexer/err/0048_unstarted_raw_byte_string_at_eof.txt create mode 100644 crates/syntax/test_data/lexer/err/0049_unstarted_raw_string_with_ascii.rs create mode 100644 crates/syntax/test_data/lexer/err/0049_unstarted_raw_string_with_ascii.txt create mode 100644 crates/syntax/test_data/lexer/err/0050_unstarted_raw_byte_string_with_ascii.rs create mode 100644 crates/syntax/test_data/lexer/err/0050_unstarted_raw_byte_string_with_ascii.txt create mode 100644 crates/syntax/test_data/lexer/err/0051_unclosed_block_comment_at_eof.rs create mode 100644 crates/syntax/test_data/lexer/err/0051_unclosed_block_comment_at_eof.txt create mode 100644 crates/syntax/test_data/lexer/err/0052_unclosed_block_comment_with_content.rs create mode 100644 crates/syntax/test_data/lexer/err/0052_unclosed_block_comment_with_content.txt create mode 100644 crates/syntax/test_data/lexer/err/0053_unclosed_nested_block_comment_entirely.rs create mode 100644 crates/syntax/test_data/lexer/err/0053_unclosed_nested_block_comment_entirely.txt create mode 100644 crates/syntax/test_data/lexer/err/0054_unclosed_nested_block_comment_partially.rs create mode 100644 crates/syntax/test_data/lexer/err/0054_unclosed_nested_block_comment_partially.txt create mode 100644 crates/syntax/test_data/lexer/err/0055_empty_int.rs create mode 100644 crates/syntax/test_data/lexer/err/0055_empty_int.txt create mode 100644 crates/syntax/test_data/lexer/err/0056_empty_exponent.rs create mode 100644 crates/syntax/test_data/lexer/err/0056_empty_exponent.txt create mode 100644 crates/syntax/test_data/lexer/err/0057_lifetime_strarts_with_a_number.rs create mode 100644 crates/syntax/test_data/lexer/err/0057_lifetime_strarts_with_a_number.txt create mode 100644 crates/syntax/test_data/lexer/ok/0001_hello.rs create mode 100644 crates/syntax/test_data/lexer/ok/0001_hello.txt create mode 100644 crates/syntax/test_data/lexer/ok/0002_whitespace.rs create mode 100644 crates/syntax/test_data/lexer/ok/0002_whitespace.txt create mode 100644 crates/syntax/test_data/lexer/ok/0003_ident.rs create mode 100644 crates/syntax/test_data/lexer/ok/0003_ident.txt create mode 100644 crates/syntax/test_data/lexer/ok/0004_numbers.rs create mode 100644 crates/syntax/test_data/lexer/ok/0004_numbers.txt create mode 100644 crates/syntax/test_data/lexer/ok/0005_symbols.rs create mode 100644 crates/syntax/test_data/lexer/ok/0005_symbols.txt create mode 100644 crates/syntax/test_data/lexer/ok/0006_chars.rs create mode 100644 crates/syntax/test_data/lexer/ok/0006_chars.txt create mode 100644 crates/syntax/test_data/lexer/ok/0007_lifetimes.rs create mode 100644 crates/syntax/test_data/lexer/ok/0007_lifetimes.txt create mode 100644 crates/syntax/test_data/lexer/ok/0008_byte_strings.rs create mode 100644 crates/syntax/test_data/lexer/ok/0008_byte_strings.txt create mode 100644 crates/syntax/test_data/lexer/ok/0009_strings.rs create mode 100644 crates/syntax/test_data/lexer/ok/0009_strings.txt create mode 100644 crates/syntax/test_data/lexer/ok/0010_single_line_comments.rs create mode 100644 crates/syntax/test_data/lexer/ok/0010_single_line_comments.txt create mode 100644 crates/syntax/test_data/lexer/ok/0011_keywords.rs create mode 100644 crates/syntax/test_data/lexer/ok/0011_keywords.txt create mode 100644 crates/syntax/test_data/lexer/ok/0012_block_comment.rs create mode 100644 crates/syntax/test_data/lexer/ok/0012_block_comment.txt create mode 100644 crates/syntax/test_data/lexer/ok/0013_raw_strings.rs create mode 100644 crates/syntax/test_data/lexer/ok/0013_raw_strings.txt create mode 100644 crates/syntax/test_data/lexer/ok/0014_raw_ident.rs create mode 100644 crates/syntax/test_data/lexer/ok/0014_raw_ident.txt (limited to 'crates/syntax/test_data/lexer') diff --git a/crates/syntax/test_data/lexer/err/0001_unclosed_char_at_eof.rs b/crates/syntax/test_data/lexer/err/0001_unclosed_char_at_eof.rs new file mode 100644 index 000000000..ad2823b48 --- /dev/null +++ b/crates/syntax/test_data/lexer/err/0001_unclosed_char_at_eof.rs @@ -0,0 +1 @@ +' \ No newline at end of file diff --git a/crates/syntax/test_data/lexer/err/0001_unclosed_char_at_eof.txt b/crates/syntax/test_data/lexer/err/0001_unclosed_char_at_eof.txt new file mode 100644 index 000000000..4d5ad74df --- /dev/null +++ b/crates/syntax/test_data/lexer/err/0001_unclosed_char_at_eof.txt @@ -0,0 +1,2 @@ +CHAR 1 "\'" +> error0..1 token("\'") msg(Missing trailing `'` symbol to terminate the character literal) diff --git a/crates/syntax/test_data/lexer/err/0002_unclosed_char_with_ferris.rs b/crates/syntax/test_data/lexer/err/0002_unclosed_char_with_ferris.rs new file mode 100644 index 000000000..e264a4152 --- /dev/null +++ b/crates/syntax/test_data/lexer/err/0002_unclosed_char_with_ferris.rs @@ -0,0 +1 @@ +'πŸ¦€ \ No newline at end of file diff --git a/crates/syntax/test_data/lexer/err/0002_unclosed_char_with_ferris.txt b/crates/syntax/test_data/lexer/err/0002_unclosed_char_with_ferris.txt new file mode 100644 index 000000000..eafdb3c7c --- /dev/null +++ b/crates/syntax/test_data/lexer/err/0002_unclosed_char_with_ferris.txt @@ -0,0 +1,2 @@ +CHAR 5 "\'πŸ¦€" +> error0..5 token("\'πŸ¦€") msg(Missing trailing `'` symbol to terminate the character literal) diff --git a/crates/syntax/test_data/lexer/err/0003_unclosed_char_with_ascii_escape.rs b/crates/syntax/test_data/lexer/err/0003_unclosed_char_with_ascii_escape.rs new file mode 100644 index 000000000..cf74b4dad --- /dev/null +++ b/crates/syntax/test_data/lexer/err/0003_unclosed_char_with_ascii_escape.rs @@ -0,0 +1 @@ +'\x7f \ No newline at end of file diff --git a/crates/syntax/test_data/lexer/err/0003_unclosed_char_with_ascii_escape.txt b/crates/syntax/test_data/lexer/err/0003_unclosed_char_with_ascii_escape.txt new file mode 100644 index 000000000..cc2b4866a --- /dev/null +++ b/crates/syntax/test_data/lexer/err/0003_unclosed_char_with_ascii_escape.txt @@ -0,0 +1,2 @@ +CHAR 5 "\'\\x7f" +> error0..5 token("\'\\x7f") msg(Missing trailing `'` symbol to terminate the character literal) diff --git a/crates/syntax/test_data/lexer/err/0004_unclosed_char_with_unicode_escape.rs b/crates/syntax/test_data/lexer/err/0004_unclosed_char_with_unicode_escape.rs new file mode 100644 index 000000000..50be91f68 --- /dev/null +++ b/crates/syntax/test_data/lexer/err/0004_unclosed_char_with_unicode_escape.rs @@ -0,0 +1 @@ +'\u{20AA} \ No newline at end of file diff --git a/crates/syntax/test_data/lexer/err/0004_unclosed_char_with_unicode_escape.txt b/crates/syntax/test_data/lexer/err/0004_unclosed_char_with_unicode_escape.txt new file mode 100644 index 000000000..a6d422cb3 --- /dev/null +++ b/crates/syntax/test_data/lexer/err/0004_unclosed_char_with_unicode_escape.txt @@ -0,0 +1,2 @@ +CHAR 9 "\'\\u{20AA}" +> error0..9 token("\'\\u{20AA}") msg(Missing trailing `'` symbol to terminate the character literal) diff --git a/crates/syntax/test_data/lexer/err/0005_unclosed_char_with_space.rs b/crates/syntax/test_data/lexer/err/0005_unclosed_char_with_space.rs new file mode 100644 index 000000000..309ecfe47 --- /dev/null +++ b/crates/syntax/test_data/lexer/err/0005_unclosed_char_with_space.rs @@ -0,0 +1 @@ +' \ No newline at end of file diff --git a/crates/syntax/test_data/lexer/err/0005_unclosed_char_with_space.txt b/crates/syntax/test_data/lexer/err/0005_unclosed_char_with_space.txt new file mode 100644 index 000000000..47e7baa70 --- /dev/null +++ b/crates/syntax/test_data/lexer/err/0005_unclosed_char_with_space.txt @@ -0,0 +1,2 @@ +CHAR 2 "\' " +> error0..2 token("\' ") msg(Missing trailing `'` symbol to terminate the character literal) diff --git a/crates/syntax/test_data/lexer/err/0006_unclosed_char_with_slash.rs b/crates/syntax/test_data/lexer/err/0006_unclosed_char_with_slash.rs new file mode 100644 index 000000000..6ba258b10 --- /dev/null +++ b/crates/syntax/test_data/lexer/err/0006_unclosed_char_with_slash.rs @@ -0,0 +1 @@ +'\ \ No newline at end of file diff --git a/crates/syntax/test_data/lexer/err/0006_unclosed_char_with_slash.txt b/crates/syntax/test_data/lexer/err/0006_unclosed_char_with_slash.txt new file mode 100644 index 000000000..511029d80 --- /dev/null +++ b/crates/syntax/test_data/lexer/err/0006_unclosed_char_with_slash.txt @@ -0,0 +1,2 @@ +CHAR 2 "\'\\" +> error0..2 token("\'\\") msg(Missing trailing `'` symbol to terminate the character literal) diff --git a/crates/syntax/test_data/lexer/err/0007_unclosed_char_with_slash_n.rs b/crates/syntax/test_data/lexer/err/0007_unclosed_char_with_slash_n.rs new file mode 100644 index 000000000..78bef7e3e --- /dev/null +++ b/crates/syntax/test_data/lexer/err/0007_unclosed_char_with_slash_n.rs @@ -0,0 +1 @@ +'\n \ No newline at end of file diff --git a/crates/syntax/test_data/lexer/err/0007_unclosed_char_with_slash_n.txt b/crates/syntax/test_data/lexer/err/0007_unclosed_char_with_slash_n.txt new file mode 100644 index 000000000..d2ba5742c --- /dev/null +++ b/crates/syntax/test_data/lexer/err/0007_unclosed_char_with_slash_n.txt @@ -0,0 +1,2 @@ +CHAR 3 "\'\\n" +> error0..3 token("\'\\n") msg(Missing trailing `'` symbol to terminate the character literal) diff --git a/crates/syntax/test_data/lexer/err/0008_unclosed_char_with_slash_single_quote.rs b/crates/syntax/test_data/lexer/err/0008_unclosed_char_with_slash_single_quote.rs new file mode 100644 index 000000000..a0e722065 --- /dev/null +++ b/crates/syntax/test_data/lexer/err/0008_unclosed_char_with_slash_single_quote.rs @@ -0,0 +1 @@ +'\' \ No newline at end of file diff --git a/crates/syntax/test_data/lexer/err/0008_unclosed_char_with_slash_single_quote.txt b/crates/syntax/test_data/lexer/err/0008_unclosed_char_with_slash_single_quote.txt new file mode 100644 index 000000000..ae9a7f0e2 --- /dev/null +++ b/crates/syntax/test_data/lexer/err/0008_unclosed_char_with_slash_single_quote.txt @@ -0,0 +1,2 @@ +CHAR 3 "\'\\\'" +> error0..3 token("\'\\\'") msg(Missing trailing `'` symbol to terminate the character literal) diff --git a/crates/syntax/test_data/lexer/err/0009_unclosed_byte_at_eof.rs b/crates/syntax/test_data/lexer/err/0009_unclosed_byte_at_eof.rs new file mode 100644 index 000000000..795dc7e25 --- /dev/null +++ b/crates/syntax/test_data/lexer/err/0009_unclosed_byte_at_eof.rs @@ -0,0 +1 @@ +b' \ No newline at end of file diff --git a/crates/syntax/test_data/lexer/err/0009_unclosed_byte_at_eof.txt b/crates/syntax/test_data/lexer/err/0009_unclosed_byte_at_eof.txt new file mode 100644 index 000000000..ff1504592 --- /dev/null +++ b/crates/syntax/test_data/lexer/err/0009_unclosed_byte_at_eof.txt @@ -0,0 +1,2 @@ +BYTE 2 "b\'" +> error0..2 token("b\'") msg(Missing trailing `'` symbol to terminate the byte literal) diff --git a/crates/syntax/test_data/lexer/err/0010_unclosed_byte_with_ferris.rs b/crates/syntax/test_data/lexer/err/0010_unclosed_byte_with_ferris.rs new file mode 100644 index 000000000..c9230dc24 --- /dev/null +++ b/crates/syntax/test_data/lexer/err/0010_unclosed_byte_with_ferris.rs @@ -0,0 +1 @@ +b'πŸ¦€ \ No newline at end of file diff --git a/crates/syntax/test_data/lexer/err/0010_unclosed_byte_with_ferris.txt b/crates/syntax/test_data/lexer/err/0010_unclosed_byte_with_ferris.txt new file mode 100644 index 000000000..34f7bd6d4 --- /dev/null +++ b/crates/syntax/test_data/lexer/err/0010_unclosed_byte_with_ferris.txt @@ -0,0 +1,2 @@ +BYTE 6 "b\'πŸ¦€" +> error0..6 token("b\'πŸ¦€") msg(Missing trailing `'` symbol to terminate the byte literal) diff --git a/crates/syntax/test_data/lexer/err/0011_unclosed_byte_with_ascii_escape.rs b/crates/syntax/test_data/lexer/err/0011_unclosed_byte_with_ascii_escape.rs new file mode 100644 index 000000000..d146a8090 --- /dev/null +++ b/crates/syntax/test_data/lexer/err/0011_unclosed_byte_with_ascii_escape.rs @@ -0,0 +1 @@ +b'\x7f \ No newline at end of file diff --git a/crates/syntax/test_data/lexer/err/0011_unclosed_byte_with_ascii_escape.txt b/crates/syntax/test_data/lexer/err/0011_unclosed_byte_with_ascii_escape.txt new file mode 100644 index 000000000..c964d0f00 --- /dev/null +++ b/crates/syntax/test_data/lexer/err/0011_unclosed_byte_with_ascii_escape.txt @@ -0,0 +1,2 @@ +BYTE 6 "b\'\\x7f" +> error0..6 token("b\'\\x7f") msg(Missing trailing `'` symbol to terminate the byte literal) diff --git a/crates/syntax/test_data/lexer/err/0012_unclosed_byte_with_unicode_escape.rs b/crates/syntax/test_data/lexer/err/0012_unclosed_byte_with_unicode_escape.rs new file mode 100644 index 000000000..a3dec7c25 --- /dev/null +++ b/crates/syntax/test_data/lexer/err/0012_unclosed_byte_with_unicode_escape.rs @@ -0,0 +1 @@ +b'\u{20AA} \ No newline at end of file diff --git a/crates/syntax/test_data/lexer/err/0012_unclosed_byte_with_unicode_escape.txt b/crates/syntax/test_data/lexer/err/0012_unclosed_byte_with_unicode_escape.txt new file mode 100644 index 000000000..cc65fb86f --- /dev/null +++ b/crates/syntax/test_data/lexer/err/0012_unclosed_byte_with_unicode_escape.txt @@ -0,0 +1,2 @@ +BYTE 10 "b\'\\u{20AA}" +> error0..10 token("b\'\\u{20AA}") msg(Missing trailing `'` symbol to terminate the byte literal) diff --git a/crates/syntax/test_data/lexer/err/0013_unclosed_byte_with_space.rs b/crates/syntax/test_data/lexer/err/0013_unclosed_byte_with_space.rs new file mode 100644 index 000000000..93b7f9c87 --- /dev/null +++ b/crates/syntax/test_data/lexer/err/0013_unclosed_byte_with_space.rs @@ -0,0 +1 @@ +b' \ No newline at end of file diff --git a/crates/syntax/test_data/lexer/err/0013_unclosed_byte_with_space.txt b/crates/syntax/test_data/lexer/err/0013_unclosed_byte_with_space.txt new file mode 100644 index 000000000..800834a14 --- /dev/null +++ b/crates/syntax/test_data/lexer/err/0013_unclosed_byte_with_space.txt @@ -0,0 +1,2 @@ +BYTE 3 "b\' " +> error0..3 token("b\' ") msg(Missing trailing `'` symbol to terminate the byte literal) diff --git a/crates/syntax/test_data/lexer/err/0014_unclosed_byte_with_slash.rs b/crates/syntax/test_data/lexer/err/0014_unclosed_byte_with_slash.rs new file mode 100644 index 000000000..abffa5037 --- /dev/null +++ b/crates/syntax/test_data/lexer/err/0014_unclosed_byte_with_slash.rs @@ -0,0 +1 @@ +b'\ \ No newline at end of file diff --git a/crates/syntax/test_data/lexer/err/0014_unclosed_byte_with_slash.txt b/crates/syntax/test_data/lexer/err/0014_unclosed_byte_with_slash.txt new file mode 100644 index 000000000..7b85ee646 --- /dev/null +++ b/crates/syntax/test_data/lexer/err/0014_unclosed_byte_with_slash.txt @@ -0,0 +1,2 @@ +BYTE 3 "b\'\\" +> error0..3 token("b\'\\") msg(Missing trailing `'` symbol to terminate the byte literal) diff --git a/crates/syntax/test_data/lexer/err/0015_unclosed_byte_with_slash_n.rs b/crates/syntax/test_data/lexer/err/0015_unclosed_byte_with_slash_n.rs new file mode 100644 index 000000000..4f46836a9 --- /dev/null +++ b/crates/syntax/test_data/lexer/err/0015_unclosed_byte_with_slash_n.rs @@ -0,0 +1 @@ +b'\n \ No newline at end of file diff --git a/crates/syntax/test_data/lexer/err/0015_unclosed_byte_with_slash_n.txt b/crates/syntax/test_data/lexer/err/0015_unclosed_byte_with_slash_n.txt new file mode 100644 index 000000000..4b9a63117 --- /dev/null +++ b/crates/syntax/test_data/lexer/err/0015_unclosed_byte_with_slash_n.txt @@ -0,0 +1,2 @@ +BYTE 4 "b\'\\n" +> error0..4 token("b\'\\n") msg(Missing trailing `'` symbol to terminate the byte literal) diff --git a/crates/syntax/test_data/lexer/err/0016_unclosed_byte_with_slash_single_quote.rs b/crates/syntax/test_data/lexer/err/0016_unclosed_byte_with_slash_single_quote.rs new file mode 100644 index 000000000..645b641ee --- /dev/null +++ b/crates/syntax/test_data/lexer/err/0016_unclosed_byte_with_slash_single_quote.rs @@ -0,0 +1 @@ +b'\' \ No newline at end of file diff --git a/crates/syntax/test_data/lexer/err/0016_unclosed_byte_with_slash_single_quote.txt b/crates/syntax/test_data/lexer/err/0016_unclosed_byte_with_slash_single_quote.txt new file mode 100644 index 000000000..fe337f8d3 --- /dev/null +++ b/crates/syntax/test_data/lexer/err/0016_unclosed_byte_with_slash_single_quote.txt @@ -0,0 +1,2 @@ +BYTE 4 "b\'\\\'" +> error0..4 token("b\'\\\'") msg(Missing trailing `'` symbol to terminate the byte literal) diff --git a/crates/syntax/test_data/lexer/err/0017_unclosed_string_at_eof.rs b/crates/syntax/test_data/lexer/err/0017_unclosed_string_at_eof.rs new file mode 100644 index 000000000..9d68933c4 --- /dev/null +++ b/crates/syntax/test_data/lexer/err/0017_unclosed_string_at_eof.rs @@ -0,0 +1 @@ +" \ No newline at end of file diff --git a/crates/syntax/test_data/lexer/err/0017_unclosed_string_at_eof.txt b/crates/syntax/test_data/lexer/err/0017_unclosed_string_at_eof.txt new file mode 100644 index 000000000..d11a8d880 --- /dev/null +++ b/crates/syntax/test_data/lexer/err/0017_unclosed_string_at_eof.txt @@ -0,0 +1,2 @@ +STRING 1 "\"" +> error0..1 token("\"") msg(Missing trailing `"` symbol to terminate the string literal) diff --git a/crates/syntax/test_data/lexer/err/0018_unclosed_string_with_ferris.rs b/crates/syntax/test_data/lexer/err/0018_unclosed_string_with_ferris.rs new file mode 100644 index 000000000..d439b8d2a --- /dev/null +++ b/crates/syntax/test_data/lexer/err/0018_unclosed_string_with_ferris.rs @@ -0,0 +1 @@ +"πŸ¦€ \ No newline at end of file diff --git a/crates/syntax/test_data/lexer/err/0018_unclosed_string_with_ferris.txt b/crates/syntax/test_data/lexer/err/0018_unclosed_string_with_ferris.txt new file mode 100644 index 000000000..167f942d1 --- /dev/null +++ b/crates/syntax/test_data/lexer/err/0018_unclosed_string_with_ferris.txt @@ -0,0 +1,2 @@ +STRING 5 "\"πŸ¦€" +> error0..5 token("\"πŸ¦€") msg(Missing trailing `"` symbol to terminate the string literal) diff --git a/crates/syntax/test_data/lexer/err/0019_unclosed_string_with_ascii_escape.rs b/crates/syntax/test_data/lexer/err/0019_unclosed_string_with_ascii_escape.rs new file mode 100644 index 000000000..56186a344 --- /dev/null +++ b/crates/syntax/test_data/lexer/err/0019_unclosed_string_with_ascii_escape.rs @@ -0,0 +1 @@ +"\x7f \ No newline at end of file diff --git a/crates/syntax/test_data/lexer/err/0019_unclosed_string_with_ascii_escape.txt b/crates/syntax/test_data/lexer/err/0019_unclosed_string_with_ascii_escape.txt new file mode 100644 index 000000000..224c653d2 --- /dev/null +++ b/crates/syntax/test_data/lexer/err/0019_unclosed_string_with_ascii_escape.txt @@ -0,0 +1,2 @@ +STRING 5 "\"\\x7f" +> error0..5 token("\"\\x7f") msg(Missing trailing `"` symbol to terminate the string literal) diff --git a/crates/syntax/test_data/lexer/err/0020_unclosed_string_with_unicode_escape.rs b/crates/syntax/test_data/lexer/err/0020_unclosed_string_with_unicode_escape.rs new file mode 100644 index 000000000..ed24095c3 --- /dev/null +++ b/crates/syntax/test_data/lexer/err/0020_unclosed_string_with_unicode_escape.rs @@ -0,0 +1 @@ +"\u{20AA} \ No newline at end of file diff --git a/crates/syntax/test_data/lexer/err/0020_unclosed_string_with_unicode_escape.txt b/crates/syntax/test_data/lexer/err/0020_unclosed_string_with_unicode_escape.txt new file mode 100644 index 000000000..48975bbcb --- /dev/null +++ b/crates/syntax/test_data/lexer/err/0020_unclosed_string_with_unicode_escape.txt @@ -0,0 +1,2 @@ +STRING 9 "\"\\u{20AA}" +> error0..9 token("\"\\u{20AA}") msg(Missing trailing `"` symbol to terminate the string literal) diff --git a/crates/syntax/test_data/lexer/err/0021_unclosed_string_with_space.rs b/crates/syntax/test_data/lexer/err/0021_unclosed_string_with_space.rs new file mode 100644 index 000000000..72cdc841f --- /dev/null +++ b/crates/syntax/test_data/lexer/err/0021_unclosed_string_with_space.rs @@ -0,0 +1 @@ +" \ No newline at end of file diff --git a/crates/syntax/test_data/lexer/err/0021_unclosed_string_with_space.txt b/crates/syntax/test_data/lexer/err/0021_unclosed_string_with_space.txt new file mode 100644 index 000000000..a823cca7a --- /dev/null +++ b/crates/syntax/test_data/lexer/err/0021_unclosed_string_with_space.txt @@ -0,0 +1,2 @@ +STRING 2 "\" " +> error0..2 token("\" ") msg(Missing trailing `"` symbol to terminate the string literal) diff --git a/crates/syntax/test_data/lexer/err/0022_unclosed_string_with_slash.rs b/crates/syntax/test_data/lexer/err/0022_unclosed_string_with_slash.rs new file mode 100644 index 000000000..00a258400 --- /dev/null +++ b/crates/syntax/test_data/lexer/err/0022_unclosed_string_with_slash.rs @@ -0,0 +1 @@ +"\ \ No newline at end of file diff --git a/crates/syntax/test_data/lexer/err/0022_unclosed_string_with_slash.txt b/crates/syntax/test_data/lexer/err/0022_unclosed_string_with_slash.txt new file mode 100644 index 000000000..0914f001f --- /dev/null +++ b/crates/syntax/test_data/lexer/err/0022_unclosed_string_with_slash.txt @@ -0,0 +1,2 @@ +STRING 2 "\"\\" +> error0..2 token("\"\\") msg(Missing trailing `"` symbol to terminate the string literal) diff --git a/crates/syntax/test_data/lexer/err/0023_unclosed_string_with_slash_n.rs b/crates/syntax/test_data/lexer/err/0023_unclosed_string_with_slash_n.rs new file mode 100644 index 000000000..a0c29b8cf --- /dev/null +++ b/crates/syntax/test_data/lexer/err/0023_unclosed_string_with_slash_n.rs @@ -0,0 +1 @@ +"\n \ No newline at end of file diff --git a/crates/syntax/test_data/lexer/err/0023_unclosed_string_with_slash_n.txt b/crates/syntax/test_data/lexer/err/0023_unclosed_string_with_slash_n.txt new file mode 100644 index 000000000..5674b55fd --- /dev/null +++ b/crates/syntax/test_data/lexer/err/0023_unclosed_string_with_slash_n.txt @@ -0,0 +1,2 @@ +STRING 3 "\"\\n" +> error0..3 token("\"\\n") msg(Missing trailing `"` symbol to terminate the string literal) diff --git a/crates/syntax/test_data/lexer/err/0024_unclosed_string_with_slash_double_quote.rs b/crates/syntax/test_data/lexer/err/0024_unclosed_string_with_slash_double_quote.rs new file mode 100644 index 000000000..403c2d6dd --- /dev/null +++ b/crates/syntax/test_data/lexer/err/0024_unclosed_string_with_slash_double_quote.rs @@ -0,0 +1 @@ +"\" \ No newline at end of file diff --git a/crates/syntax/test_data/lexer/err/0024_unclosed_string_with_slash_double_quote.txt b/crates/syntax/test_data/lexer/err/0024_unclosed_string_with_slash_double_quote.txt new file mode 100644 index 000000000..4c9a774e4 --- /dev/null +++ b/crates/syntax/test_data/lexer/err/0024_unclosed_string_with_slash_double_quote.txt @@ -0,0 +1,2 @@ +STRING 3 "\"\\\"" +> error0..3 token("\"\\\"") msg(Missing trailing `"` symbol to terminate the string literal) diff --git a/crates/syntax/test_data/lexer/err/0025_unclosed_byte_string_at_eof.rs b/crates/syntax/test_data/lexer/err/0025_unclosed_byte_string_at_eof.rs new file mode 100644 index 000000000..36f4f4321 --- /dev/null +++ b/crates/syntax/test_data/lexer/err/0025_unclosed_byte_string_at_eof.rs @@ -0,0 +1 @@ +b" \ No newline at end of file diff --git a/crates/syntax/test_data/lexer/err/0025_unclosed_byte_string_at_eof.txt b/crates/syntax/test_data/lexer/err/0025_unclosed_byte_string_at_eof.txt new file mode 100644 index 000000000..04e6b0aa4 --- /dev/null +++ b/crates/syntax/test_data/lexer/err/0025_unclosed_byte_string_at_eof.txt @@ -0,0 +1,2 @@ +BYTE_STRING 2 "b\"" +> error0..2 token("b\"") msg(Missing trailing `"` symbol to terminate the byte string literal) diff --git a/crates/syntax/test_data/lexer/err/0026_unclosed_byte_string_with_ferris.rs b/crates/syntax/test_data/lexer/err/0026_unclosed_byte_string_with_ferris.rs new file mode 100644 index 000000000..3c23a0372 --- /dev/null +++ b/crates/syntax/test_data/lexer/err/0026_unclosed_byte_string_with_ferris.rs @@ -0,0 +1 @@ +b"πŸ¦€ \ No newline at end of file diff --git a/crates/syntax/test_data/lexer/err/0026_unclosed_byte_string_with_ferris.txt b/crates/syntax/test_data/lexer/err/0026_unclosed_byte_string_with_ferris.txt new file mode 100644 index 000000000..0576a0609 --- /dev/null +++ b/crates/syntax/test_data/lexer/err/0026_unclosed_byte_string_with_ferris.txt @@ -0,0 +1,2 @@ +BYTE_STRING 6 "b\"πŸ¦€" +> error0..6 token("b\"πŸ¦€") msg(Missing trailing `"` symbol to terminate the byte string literal) diff --git a/crates/syntax/test_data/lexer/err/0027_unclosed_byte_string_with_ascii_escape.rs b/crates/syntax/test_data/lexer/err/0027_unclosed_byte_string_with_ascii_escape.rs new file mode 100644 index 000000000..836c112c1 --- /dev/null +++ b/crates/syntax/test_data/lexer/err/0027_unclosed_byte_string_with_ascii_escape.rs @@ -0,0 +1 @@ +b"\x7f \ No newline at end of file diff --git a/crates/syntax/test_data/lexer/err/0027_unclosed_byte_string_with_ascii_escape.txt b/crates/syntax/test_data/lexer/err/0027_unclosed_byte_string_with_ascii_escape.txt new file mode 100644 index 000000000..541a013d8 --- /dev/null +++ b/crates/syntax/test_data/lexer/err/0027_unclosed_byte_string_with_ascii_escape.txt @@ -0,0 +1,2 @@ +BYTE_STRING 6 "b\"\\x7f" +> error0..6 token("b\"\\x7f") msg(Missing trailing `"` symbol to terminate the byte string literal) diff --git a/crates/syntax/test_data/lexer/err/0028_unclosed_byte_string_with_unicode_escape.rs b/crates/syntax/test_data/lexer/err/0028_unclosed_byte_string_with_unicode_escape.rs new file mode 100644 index 000000000..1c6df1d00 --- /dev/null +++ b/crates/syntax/test_data/lexer/err/0028_unclosed_byte_string_with_unicode_escape.rs @@ -0,0 +1 @@ +b"\u{20AA} \ No newline at end of file diff --git a/crates/syntax/test_data/lexer/err/0028_unclosed_byte_string_with_unicode_escape.txt b/crates/syntax/test_data/lexer/err/0028_unclosed_byte_string_with_unicode_escape.txt new file mode 100644 index 000000000..71b0fb211 --- /dev/null +++ b/crates/syntax/test_data/lexer/err/0028_unclosed_byte_string_with_unicode_escape.txt @@ -0,0 +1,2 @@ +BYTE_STRING 10 "b\"\\u{20AA}" +> error0..10 token("b\"\\u{20AA}") msg(Missing trailing `"` symbol to terminate the byte string literal) diff --git a/crates/syntax/test_data/lexer/err/0029_unclosed_byte_string_with_space.rs b/crates/syntax/test_data/lexer/err/0029_unclosed_byte_string_with_space.rs new file mode 100644 index 000000000..d6898541e --- /dev/null +++ b/crates/syntax/test_data/lexer/err/0029_unclosed_byte_string_with_space.rs @@ -0,0 +1 @@ +b" \ No newline at end of file diff --git a/crates/syntax/test_data/lexer/err/0029_unclosed_byte_string_with_space.txt b/crates/syntax/test_data/lexer/err/0029_unclosed_byte_string_with_space.txt new file mode 100644 index 000000000..bd5058bc1 --- /dev/null +++ b/crates/syntax/test_data/lexer/err/0029_unclosed_byte_string_with_space.txt @@ -0,0 +1,2 @@ +BYTE_STRING 3 "b\" " +> error0..3 token("b\" ") msg(Missing trailing `"` symbol to terminate the byte string literal) diff --git a/crates/syntax/test_data/lexer/err/0030_unclosed_byte_string_with_slash.rs b/crates/syntax/test_data/lexer/err/0030_unclosed_byte_string_with_slash.rs new file mode 100644 index 000000000..cce661538 --- /dev/null +++ b/crates/syntax/test_data/lexer/err/0030_unclosed_byte_string_with_slash.rs @@ -0,0 +1 @@ +b"\ \ No newline at end of file diff --git a/crates/syntax/test_data/lexer/err/0030_unclosed_byte_string_with_slash.txt b/crates/syntax/test_data/lexer/err/0030_unclosed_byte_string_with_slash.txt new file mode 100644 index 000000000..7f94f10ba --- /dev/null +++ b/crates/syntax/test_data/lexer/err/0030_unclosed_byte_string_with_slash.txt @@ -0,0 +1,2 @@ +BYTE_STRING 3 "b\"\\" +> error0..3 token("b\"\\") msg(Missing trailing `"` symbol to terminate the byte string literal) diff --git a/crates/syntax/test_data/lexer/err/0031_unclosed_byte_string_with_slash_n.rs b/crates/syntax/test_data/lexer/err/0031_unclosed_byte_string_with_slash_n.rs new file mode 100644 index 000000000..5e680aabb --- /dev/null +++ b/crates/syntax/test_data/lexer/err/0031_unclosed_byte_string_with_slash_n.rs @@ -0,0 +1 @@ +b"\n \ No newline at end of file diff --git a/crates/syntax/test_data/lexer/err/0031_unclosed_byte_string_with_slash_n.txt b/crates/syntax/test_data/lexer/err/0031_unclosed_byte_string_with_slash_n.txt new file mode 100644 index 000000000..9c3c089d7 --- /dev/null +++ b/crates/syntax/test_data/lexer/err/0031_unclosed_byte_string_with_slash_n.txt @@ -0,0 +1,2 @@ +BYTE_STRING 4 "b\"\\n" +> error0..4 token("b\"\\n") msg(Missing trailing `"` symbol to terminate the byte string literal) diff --git a/crates/syntax/test_data/lexer/err/0032_unclosed_byte_string_with_slash_double_quote.rs b/crates/syntax/test_data/lexer/err/0032_unclosed_byte_string_with_slash_double_quote.rs new file mode 100644 index 000000000..f2ff58ba9 --- /dev/null +++ b/crates/syntax/test_data/lexer/err/0032_unclosed_byte_string_with_slash_double_quote.rs @@ -0,0 +1 @@ +b"\" \ No newline at end of file diff --git a/crates/syntax/test_data/lexer/err/0032_unclosed_byte_string_with_slash_double_quote.txt b/crates/syntax/test_data/lexer/err/0032_unclosed_byte_string_with_slash_double_quote.txt new file mode 100644 index 000000000..884b12c8e --- /dev/null +++ b/crates/syntax/test_data/lexer/err/0032_unclosed_byte_string_with_slash_double_quote.txt @@ -0,0 +1,2 @@ +BYTE_STRING 4 "b\"\\\"" +> error0..4 token("b\"\\\"") msg(Missing trailing `"` symbol to terminate the byte string literal) diff --git a/crates/syntax/test_data/lexer/err/0033_unclosed_raw_string_at_eof.rs b/crates/syntax/test_data/lexer/err/0033_unclosed_raw_string_at_eof.rs new file mode 100644 index 000000000..557c59b62 --- /dev/null +++ b/crates/syntax/test_data/lexer/err/0033_unclosed_raw_string_at_eof.rs @@ -0,0 +1 @@ +r##" \ No newline at end of file diff --git a/crates/syntax/test_data/lexer/err/0033_unclosed_raw_string_at_eof.txt b/crates/syntax/test_data/lexer/err/0033_unclosed_raw_string_at_eof.txt new file mode 100644 index 000000000..6fd59ccc0 --- /dev/null +++ b/crates/syntax/test_data/lexer/err/0033_unclosed_raw_string_at_eof.txt @@ -0,0 +1,2 @@ +RAW_STRING 4 "r##\"" +> error0..4 token("r##\"") msg(Missing trailing `"` with `#` symbols to terminate the raw string literal) diff --git a/crates/syntax/test_data/lexer/err/0034_unclosed_raw_string_with_ferris.rs b/crates/syntax/test_data/lexer/err/0034_unclosed_raw_string_with_ferris.rs new file mode 100644 index 000000000..bd046e4bb --- /dev/null +++ b/crates/syntax/test_data/lexer/err/0034_unclosed_raw_string_with_ferris.rs @@ -0,0 +1 @@ +r##"πŸ¦€ \ No newline at end of file diff --git a/crates/syntax/test_data/lexer/err/0034_unclosed_raw_string_with_ferris.txt b/crates/syntax/test_data/lexer/err/0034_unclosed_raw_string_with_ferris.txt new file mode 100644 index 000000000..8d9ca0e8f --- /dev/null +++ b/crates/syntax/test_data/lexer/err/0034_unclosed_raw_string_with_ferris.txt @@ -0,0 +1,2 @@ +RAW_STRING 8 "r##\"πŸ¦€" +> error0..8 token("r##\"πŸ¦€") msg(Missing trailing `"` with `#` symbols to terminate the raw string literal) diff --git a/crates/syntax/test_data/lexer/err/0035_unclosed_raw_string_with_ascii_escape.rs b/crates/syntax/test_data/lexer/err/0035_unclosed_raw_string_with_ascii_escape.rs new file mode 100644 index 000000000..5bec883dc --- /dev/null +++ b/crates/syntax/test_data/lexer/err/0035_unclosed_raw_string_with_ascii_escape.rs @@ -0,0 +1 @@ +r##"\x7f \ No newline at end of file diff --git a/crates/syntax/test_data/lexer/err/0035_unclosed_raw_string_with_ascii_escape.txt b/crates/syntax/test_data/lexer/err/0035_unclosed_raw_string_with_ascii_escape.txt new file mode 100644 index 000000000..a906380c7 --- /dev/null +++ b/crates/syntax/test_data/lexer/err/0035_unclosed_raw_string_with_ascii_escape.txt @@ -0,0 +1,2 @@ +RAW_STRING 8 "r##\"\\x7f" +> error0..8 token("r##\"\\x7f") msg(Missing trailing `"` with `#` symbols to terminate the raw string literal) diff --git a/crates/syntax/test_data/lexer/err/0036_unclosed_raw_string_with_unicode_escape.rs b/crates/syntax/test_data/lexer/err/0036_unclosed_raw_string_with_unicode_escape.rs new file mode 100644 index 000000000..bf05c3913 --- /dev/null +++ b/crates/syntax/test_data/lexer/err/0036_unclosed_raw_string_with_unicode_escape.rs @@ -0,0 +1 @@ +r##"\u{20AA} \ No newline at end of file diff --git a/crates/syntax/test_data/lexer/err/0036_unclosed_raw_string_with_unicode_escape.txt b/crates/syntax/test_data/lexer/err/0036_unclosed_raw_string_with_unicode_escape.txt new file mode 100644 index 000000000..5667c6149 --- /dev/null +++ b/crates/syntax/test_data/lexer/err/0036_unclosed_raw_string_with_unicode_escape.txt @@ -0,0 +1,2 @@ +RAW_STRING 12 "r##\"\\u{20AA}" +> error0..12 token("r##\"\\u{20AA}") msg(Missing trailing `"` with `#` symbols to terminate the raw string literal) diff --git a/crates/syntax/test_data/lexer/err/0037_unclosed_raw_string_with_space.rs b/crates/syntax/test_data/lexer/err/0037_unclosed_raw_string_with_space.rs new file mode 100644 index 000000000..f104bae4f --- /dev/null +++ b/crates/syntax/test_data/lexer/err/0037_unclosed_raw_string_with_space.rs @@ -0,0 +1 @@ +r##" \ No newline at end of file diff --git a/crates/syntax/test_data/lexer/err/0037_unclosed_raw_string_with_space.txt b/crates/syntax/test_data/lexer/err/0037_unclosed_raw_string_with_space.txt new file mode 100644 index 000000000..141c8268e --- /dev/null +++ b/crates/syntax/test_data/lexer/err/0037_unclosed_raw_string_with_space.txt @@ -0,0 +1,2 @@ +RAW_STRING 5 "r##\" " +> error0..5 token("r##\" ") msg(Missing trailing `"` with `#` symbols to terminate the raw string literal) diff --git a/crates/syntax/test_data/lexer/err/0038_unclosed_raw_string_with_slash.rs b/crates/syntax/test_data/lexer/err/0038_unclosed_raw_string_with_slash.rs new file mode 100644 index 000000000..9242077b8 --- /dev/null +++ b/crates/syntax/test_data/lexer/err/0038_unclosed_raw_string_with_slash.rs @@ -0,0 +1 @@ +r##"\ \ No newline at end of file diff --git a/crates/syntax/test_data/lexer/err/0038_unclosed_raw_string_with_slash.txt b/crates/syntax/test_data/lexer/err/0038_unclosed_raw_string_with_slash.txt new file mode 100644 index 000000000..f61d4cc91 --- /dev/null +++ b/crates/syntax/test_data/lexer/err/0038_unclosed_raw_string_with_slash.txt @@ -0,0 +1,2 @@ +RAW_STRING 5 "r##\"\\" +> error0..5 token("r##\"\\") msg(Missing trailing `"` with `#` symbols to terminate the raw string literal) diff --git a/crates/syntax/test_data/lexer/err/0039_unclosed_raw_string_with_slash_n.rs b/crates/syntax/test_data/lexer/err/0039_unclosed_raw_string_with_slash_n.rs new file mode 100644 index 000000000..db1c16f2b --- /dev/null +++ b/crates/syntax/test_data/lexer/err/0039_unclosed_raw_string_with_slash_n.rs @@ -0,0 +1 @@ +r##"\n \ No newline at end of file diff --git a/crates/syntax/test_data/lexer/err/0039_unclosed_raw_string_with_slash_n.txt b/crates/syntax/test_data/lexer/err/0039_unclosed_raw_string_with_slash_n.txt new file mode 100644 index 000000000..12e2c0fc0 --- /dev/null +++ b/crates/syntax/test_data/lexer/err/0039_unclosed_raw_string_with_slash_n.txt @@ -0,0 +1,2 @@ +RAW_STRING 6 "r##\"\\n" +> error0..6 token("r##\"\\n") msg(Missing trailing `"` with `#` symbols to terminate the raw string literal) diff --git a/crates/syntax/test_data/lexer/err/0040_unclosed_raw_byte_string_at_eof.rs b/crates/syntax/test_data/lexer/err/0040_unclosed_raw_byte_string_at_eof.rs new file mode 100644 index 000000000..ae5bae622 --- /dev/null +++ b/crates/syntax/test_data/lexer/err/0040_unclosed_raw_byte_string_at_eof.rs @@ -0,0 +1 @@ +br##" \ No newline at end of file diff --git a/crates/syntax/test_data/lexer/err/0040_unclosed_raw_byte_string_at_eof.txt b/crates/syntax/test_data/lexer/err/0040_unclosed_raw_byte_string_at_eof.txt new file mode 100644 index 000000000..fe12cb5fc --- /dev/null +++ b/crates/syntax/test_data/lexer/err/0040_unclosed_raw_byte_string_at_eof.txt @@ -0,0 +1,2 @@ +RAW_BYTE_STRING 5 "br##\"" +> error0..5 token("br##\"") msg(Missing trailing `"` with `#` symbols to terminate the raw byte string literal) diff --git a/crates/syntax/test_data/lexer/err/0041_unclosed_raw_byte_string_with_ferris.rs b/crates/syntax/test_data/lexer/err/0041_unclosed_raw_byte_string_with_ferris.rs new file mode 100644 index 000000000..9ef01207a --- /dev/null +++ b/crates/syntax/test_data/lexer/err/0041_unclosed_raw_byte_string_with_ferris.rs @@ -0,0 +1 @@ +br##"πŸ¦€ \ No newline at end of file diff --git a/crates/syntax/test_data/lexer/err/0041_unclosed_raw_byte_string_with_ferris.txt b/crates/syntax/test_data/lexer/err/0041_unclosed_raw_byte_string_with_ferris.txt new file mode 100644 index 000000000..5be2a7861 --- /dev/null +++ b/crates/syntax/test_data/lexer/err/0041_unclosed_raw_byte_string_with_ferris.txt @@ -0,0 +1,2 @@ +RAW_BYTE_STRING 9 "br##\"πŸ¦€" +> error0..9 token("br##\"πŸ¦€") msg(Missing trailing `"` with `#` symbols to terminate the raw byte string literal) diff --git a/crates/syntax/test_data/lexer/err/0042_unclosed_raw_byte_string_with_ascii_escape.rs b/crates/syntax/test_data/lexer/err/0042_unclosed_raw_byte_string_with_ascii_escape.rs new file mode 100644 index 000000000..d50270afe --- /dev/null +++ b/crates/syntax/test_data/lexer/err/0042_unclosed_raw_byte_string_with_ascii_escape.rs @@ -0,0 +1 @@ +br##"\x7f \ No newline at end of file diff --git a/crates/syntax/test_data/lexer/err/0042_unclosed_raw_byte_string_with_ascii_escape.txt b/crates/syntax/test_data/lexer/err/0042_unclosed_raw_byte_string_with_ascii_escape.txt new file mode 100644 index 000000000..6cbe08d07 --- /dev/null +++ b/crates/syntax/test_data/lexer/err/0042_unclosed_raw_byte_string_with_ascii_escape.txt @@ -0,0 +1,2 @@ +RAW_BYTE_STRING 9 "br##\"\\x7f" +> error0..9 token("br##\"\\x7f") msg(Missing trailing `"` with `#` symbols to terminate the raw byte string literal) diff --git a/crates/syntax/test_data/lexer/err/0043_unclosed_raw_byte_string_with_unicode_escape.rs b/crates/syntax/test_data/lexer/err/0043_unclosed_raw_byte_string_with_unicode_escape.rs new file mode 100644 index 000000000..90e299a1a --- /dev/null +++ b/crates/syntax/test_data/lexer/err/0043_unclosed_raw_byte_string_with_unicode_escape.rs @@ -0,0 +1 @@ +br##"\u{20AA} \ No newline at end of file diff --git a/crates/syntax/test_data/lexer/err/0043_unclosed_raw_byte_string_with_unicode_escape.txt b/crates/syntax/test_data/lexer/err/0043_unclosed_raw_byte_string_with_unicode_escape.txt new file mode 100644 index 000000000..f56a4f984 --- /dev/null +++ b/crates/syntax/test_data/lexer/err/0043_unclosed_raw_byte_string_with_unicode_escape.txt @@ -0,0 +1,2 @@ +RAW_BYTE_STRING 13 "br##\"\\u{20AA}" +> error0..13 token("br##\"\\u{20AA}") msg(Missing trailing `"` with `#` symbols to terminate the raw byte string literal) diff --git a/crates/syntax/test_data/lexer/err/0044_unclosed_raw_byte_string_with_space.rs b/crates/syntax/test_data/lexer/err/0044_unclosed_raw_byte_string_with_space.rs new file mode 100644 index 000000000..14c602fd2 --- /dev/null +++ b/crates/syntax/test_data/lexer/err/0044_unclosed_raw_byte_string_with_space.rs @@ -0,0 +1 @@ +br##" \ No newline at end of file diff --git a/crates/syntax/test_data/lexer/err/0044_unclosed_raw_byte_string_with_space.txt b/crates/syntax/test_data/lexer/err/0044_unclosed_raw_byte_string_with_space.txt new file mode 100644 index 000000000..3d32ce34e --- /dev/null +++ b/crates/syntax/test_data/lexer/err/0044_unclosed_raw_byte_string_with_space.txt @@ -0,0 +1,2 @@ +RAW_BYTE_STRING 6 "br##\" " +> error0..6 token("br##\" ") msg(Missing trailing `"` with `#` symbols to terminate the raw byte string literal) diff --git a/crates/syntax/test_data/lexer/err/0045_unclosed_raw_byte_string_with_slash.rs b/crates/syntax/test_data/lexer/err/0045_unclosed_raw_byte_string_with_slash.rs new file mode 100644 index 000000000..0b3c015d7 --- /dev/null +++ b/crates/syntax/test_data/lexer/err/0045_unclosed_raw_byte_string_with_slash.rs @@ -0,0 +1 @@ +br##"\ \ No newline at end of file diff --git a/crates/syntax/test_data/lexer/err/0045_unclosed_raw_byte_string_with_slash.txt b/crates/syntax/test_data/lexer/err/0045_unclosed_raw_byte_string_with_slash.txt new file mode 100644 index 000000000..320fea177 --- /dev/null +++ b/crates/syntax/test_data/lexer/err/0045_unclosed_raw_byte_string_with_slash.txt @@ -0,0 +1,2 @@ +RAW_BYTE_STRING 6 "br##\"\\" +> error0..6 token("br##\"\\") msg(Missing trailing `"` with `#` symbols to terminate the raw byte string literal) diff --git a/crates/syntax/test_data/lexer/err/0046_unclosed_raw_byte_string_with_slash_n.rs b/crates/syntax/test_data/lexer/err/0046_unclosed_raw_byte_string_with_slash_n.rs new file mode 100644 index 000000000..0d8b0e7ab --- /dev/null +++ b/crates/syntax/test_data/lexer/err/0046_unclosed_raw_byte_string_with_slash_n.rs @@ -0,0 +1 @@ +br##"\n \ No newline at end of file diff --git a/crates/syntax/test_data/lexer/err/0046_unclosed_raw_byte_string_with_slash_n.txt b/crates/syntax/test_data/lexer/err/0046_unclosed_raw_byte_string_with_slash_n.txt new file mode 100644 index 000000000..b3a56380c --- /dev/null +++ b/crates/syntax/test_data/lexer/err/0046_unclosed_raw_byte_string_with_slash_n.txt @@ -0,0 +1,2 @@ +RAW_BYTE_STRING 7 "br##\"\\n" +> error0..7 token("br##\"\\n") msg(Missing trailing `"` with `#` symbols to terminate the raw byte string literal) diff --git a/crates/syntax/test_data/lexer/err/0047_unstarted_raw_string_at_eof.rs b/crates/syntax/test_data/lexer/err/0047_unstarted_raw_string_at_eof.rs new file mode 100644 index 000000000..eddf8d080 --- /dev/null +++ b/crates/syntax/test_data/lexer/err/0047_unstarted_raw_string_at_eof.rs @@ -0,0 +1 @@ +r## \ No newline at end of file diff --git a/crates/syntax/test_data/lexer/err/0047_unstarted_raw_string_at_eof.txt b/crates/syntax/test_data/lexer/err/0047_unstarted_raw_string_at_eof.txt new file mode 100644 index 000000000..5af1e2d97 --- /dev/null +++ b/crates/syntax/test_data/lexer/err/0047_unstarted_raw_string_at_eof.txt @@ -0,0 +1,2 @@ +RAW_STRING 3 "r##" +> error0..3 token("r##") msg(Missing `"` symbol after `#` symbols to begin the raw string literal) diff --git a/crates/syntax/test_data/lexer/err/0048_unstarted_raw_byte_string_at_eof.rs b/crates/syntax/test_data/lexer/err/0048_unstarted_raw_byte_string_at_eof.rs new file mode 100644 index 000000000..7e8cadf4f --- /dev/null +++ b/crates/syntax/test_data/lexer/err/0048_unstarted_raw_byte_string_at_eof.rs @@ -0,0 +1 @@ +br## \ No newline at end of file diff --git a/crates/syntax/test_data/lexer/err/0048_unstarted_raw_byte_string_at_eof.txt b/crates/syntax/test_data/lexer/err/0048_unstarted_raw_byte_string_at_eof.txt new file mode 100644 index 000000000..aec7afd92 --- /dev/null +++ b/crates/syntax/test_data/lexer/err/0048_unstarted_raw_byte_string_at_eof.txt @@ -0,0 +1,2 @@ +RAW_BYTE_STRING 4 "br##" +> error0..4 token("br##") msg(Missing `"` symbol after `#` symbols to begin the raw byte string literal) diff --git a/crates/syntax/test_data/lexer/err/0049_unstarted_raw_string_with_ascii.rs b/crates/syntax/test_data/lexer/err/0049_unstarted_raw_string_with_ascii.rs new file mode 100644 index 000000000..534668a9b --- /dev/null +++ b/crates/syntax/test_data/lexer/err/0049_unstarted_raw_string_with_ascii.rs @@ -0,0 +1 @@ +r## I lack a quote! \ No newline at end of file diff --git a/crates/syntax/test_data/lexer/err/0049_unstarted_raw_string_with_ascii.txt b/crates/syntax/test_data/lexer/err/0049_unstarted_raw_string_with_ascii.txt new file mode 100644 index 000000000..e22fe5374 --- /dev/null +++ b/crates/syntax/test_data/lexer/err/0049_unstarted_raw_string_with_ascii.txt @@ -0,0 +1,10 @@ +RAW_STRING 4 "r## " +IDENT 1 "I" +WHITESPACE 1 " " +IDENT 4 "lack" +WHITESPACE 1 " " +IDENT 1 "a" +WHITESPACE 1 " " +IDENT 5 "quote" +BANG 1 "!" +> error0..4 token("r## ") msg(Missing `"` symbol after `#` symbols to begin the raw string literal) diff --git a/crates/syntax/test_data/lexer/err/0050_unstarted_raw_byte_string_with_ascii.rs b/crates/syntax/test_data/lexer/err/0050_unstarted_raw_byte_string_with_ascii.rs new file mode 100644 index 000000000..d9b55455a --- /dev/null +++ b/crates/syntax/test_data/lexer/err/0050_unstarted_raw_byte_string_with_ascii.rs @@ -0,0 +1 @@ +br## I lack a quote! \ No newline at end of file diff --git a/crates/syntax/test_data/lexer/err/0050_unstarted_raw_byte_string_with_ascii.txt b/crates/syntax/test_data/lexer/err/0050_unstarted_raw_byte_string_with_ascii.txt new file mode 100644 index 000000000..d74ea4c27 --- /dev/null +++ b/crates/syntax/test_data/lexer/err/0050_unstarted_raw_byte_string_with_ascii.txt @@ -0,0 +1,10 @@ +RAW_BYTE_STRING 5 "br## " +IDENT 1 "I" +WHITESPACE 1 " " +IDENT 4 "lack" +WHITESPACE 1 " " +IDENT 1 "a" +WHITESPACE 1 " " +IDENT 5 "quote" +BANG 1 "!" +> error0..5 token("br## ") msg(Missing `"` symbol after `#` symbols to begin the raw byte string literal) diff --git a/crates/syntax/test_data/lexer/err/0051_unclosed_block_comment_at_eof.rs b/crates/syntax/test_data/lexer/err/0051_unclosed_block_comment_at_eof.rs new file mode 100644 index 000000000..22e83649f --- /dev/null +++ b/crates/syntax/test_data/lexer/err/0051_unclosed_block_comment_at_eof.rs @@ -0,0 +1 @@ +/* \ No newline at end of file diff --git a/crates/syntax/test_data/lexer/err/0051_unclosed_block_comment_at_eof.txt b/crates/syntax/test_data/lexer/err/0051_unclosed_block_comment_at_eof.txt new file mode 100644 index 000000000..2a256e9df --- /dev/null +++ b/crates/syntax/test_data/lexer/err/0051_unclosed_block_comment_at_eof.txt @@ -0,0 +1,2 @@ +COMMENT 2 "/*" +> error0..2 token("/*") msg(Missing trailing `*/` symbols to terminate the block comment) diff --git a/crates/syntax/test_data/lexer/err/0052_unclosed_block_comment_with_content.rs b/crates/syntax/test_data/lexer/err/0052_unclosed_block_comment_with_content.rs new file mode 100644 index 000000000..c45c2844d --- /dev/null +++ b/crates/syntax/test_data/lexer/err/0052_unclosed_block_comment_with_content.rs @@ -0,0 +1 @@ +/* comment diff --git a/crates/syntax/test_data/lexer/err/0052_unclosed_block_comment_with_content.txt b/crates/syntax/test_data/lexer/err/0052_unclosed_block_comment_with_content.txt new file mode 100644 index 000000000..8e8490302 --- /dev/null +++ b/crates/syntax/test_data/lexer/err/0052_unclosed_block_comment_with_content.txt @@ -0,0 +1,2 @@ +COMMENT 11 "/* comment\n" +> error0..11 token("/* comment\n") msg(Missing trailing `*/` symbols to terminate the block comment) diff --git a/crates/syntax/test_data/lexer/err/0053_unclosed_nested_block_comment_entirely.rs b/crates/syntax/test_data/lexer/err/0053_unclosed_nested_block_comment_entirely.rs new file mode 100644 index 000000000..3fcfc9660 --- /dev/null +++ b/crates/syntax/test_data/lexer/err/0053_unclosed_nested_block_comment_entirely.rs @@ -0,0 +1 @@ +/* /* /* diff --git a/crates/syntax/test_data/lexer/err/0053_unclosed_nested_block_comment_entirely.txt b/crates/syntax/test_data/lexer/err/0053_unclosed_nested_block_comment_entirely.txt new file mode 100644 index 000000000..b7d28fc05 --- /dev/null +++ b/crates/syntax/test_data/lexer/err/0053_unclosed_nested_block_comment_entirely.txt @@ -0,0 +1,2 @@ +COMMENT 9 "/* /* /*\n" +> error0..9 token("/* /* /*\n") msg(Missing trailing `*/` symbols to terminate the block comment) diff --git a/crates/syntax/test_data/lexer/err/0054_unclosed_nested_block_comment_partially.rs b/crates/syntax/test_data/lexer/err/0054_unclosed_nested_block_comment_partially.rs new file mode 100644 index 000000000..26c898f01 --- /dev/null +++ b/crates/syntax/test_data/lexer/err/0054_unclosed_nested_block_comment_partially.rs @@ -0,0 +1 @@ +/** /*! /* comment */ */ diff --git a/crates/syntax/test_data/lexer/err/0054_unclosed_nested_block_comment_partially.txt b/crates/syntax/test_data/lexer/err/0054_unclosed_nested_block_comment_partially.txt new file mode 100644 index 000000000..4742d2c12 --- /dev/null +++ b/crates/syntax/test_data/lexer/err/0054_unclosed_nested_block_comment_partially.txt @@ -0,0 +1,2 @@ +COMMENT 25 "/** /*! /* comment */ */\n" +> error0..25 token("/** /*! /* comment */ */\n") msg(Missing trailing `*/` symbols to terminate the block comment) diff --git a/crates/syntax/test_data/lexer/err/0055_empty_int.rs b/crates/syntax/test_data/lexer/err/0055_empty_int.rs new file mode 100644 index 000000000..aa2a9fdca --- /dev/null +++ b/crates/syntax/test_data/lexer/err/0055_empty_int.rs @@ -0,0 +1,17 @@ +0b +0o +0x + +0b_ +0o_ +0x_ + +0bnoDigit +0onoDigit +0xnoDigit + +0xG +0xg + +0x_g +0x_G diff --git a/crates/syntax/test_data/lexer/err/0055_empty_int.txt b/crates/syntax/test_data/lexer/err/0055_empty_int.txt new file mode 100644 index 000000000..bcd094b6e --- /dev/null +++ b/crates/syntax/test_data/lexer/err/0055_empty_int.txt @@ -0,0 +1,39 @@ +INT_NUMBER 2 "0b" +WHITESPACE 1 "\n" +INT_NUMBER 2 "0o" +WHITESPACE 1 "\n" +INT_NUMBER 2 "0x" +WHITESPACE 2 "\n\n" +INT_NUMBER 3 "0b_" +WHITESPACE 1 "\n" +INT_NUMBER 3 "0o_" +WHITESPACE 1 "\n" +INT_NUMBER 3 "0x_" +WHITESPACE 2 "\n\n" +INT_NUMBER 9 "0bnoDigit" +WHITESPACE 1 "\n" +INT_NUMBER 9 "0onoDigit" +WHITESPACE 1 "\n" +INT_NUMBER 9 "0xnoDigit" +WHITESPACE 2 "\n\n" +INT_NUMBER 3 "0xG" +WHITESPACE 1 "\n" +INT_NUMBER 3 "0xg" +WHITESPACE 2 "\n\n" +INT_NUMBER 4 "0x_g" +WHITESPACE 1 "\n" +INT_NUMBER 4 "0x_G" +WHITESPACE 1 "\n" +> error0..2 token("0b") msg(Missing digits after the integer base prefix) +> error3..5 token("0o") msg(Missing digits after the integer base prefix) +> error6..8 token("0x") msg(Missing digits after the integer base prefix) +> error10..13 token("0b_") msg(Missing digits after the integer base prefix) +> error14..17 token("0o_") msg(Missing digits after the integer base prefix) +> error18..21 token("0x_") msg(Missing digits after the integer base prefix) +> error23..32 token("0bnoDigit") msg(Missing digits after the integer base prefix) +> error33..42 token("0onoDigit") msg(Missing digits after the integer base prefix) +> error43..52 token("0xnoDigit") msg(Missing digits after the integer base prefix) +> error54..57 token("0xG") msg(Missing digits after the integer base prefix) +> error58..61 token("0xg") msg(Missing digits after the integer base prefix) +> error63..67 token("0x_g") msg(Missing digits after the integer base prefix) +> error68..72 token("0x_G") msg(Missing digits after the integer base prefix) diff --git a/crates/syntax/test_data/lexer/err/0056_empty_exponent.rs b/crates/syntax/test_data/lexer/err/0056_empty_exponent.rs new file mode 100644 index 000000000..286584c88 --- /dev/null +++ b/crates/syntax/test_data/lexer/err/0056_empty_exponent.rs @@ -0,0 +1,22 @@ +0e +0E + +42e+ +42e- +42E+ +42E- + +42.e+ +42.e- +42.E+ +42.E- + +42.2e+ +42.2e- +42.2E+ +42.2E- + +42.2e+f32 +42.2e-f32 +42.2E+f32 +42.2E-f32 diff --git a/crates/syntax/test_data/lexer/err/0056_empty_exponent.txt b/crates/syntax/test_data/lexer/err/0056_empty_exponent.txt new file mode 100644 index 000000000..6a645a6a4 --- /dev/null +++ b/crates/syntax/test_data/lexer/err/0056_empty_exponent.txt @@ -0,0 +1,62 @@ +FLOAT_NUMBER 2 "0e" +WHITESPACE 1 "\n" +FLOAT_NUMBER 2 "0E" +WHITESPACE 2 "\n\n" +FLOAT_NUMBER 4 "42e+" +WHITESPACE 1 "\n" +FLOAT_NUMBER 4 "42e-" +WHITESPACE 1 "\n" +FLOAT_NUMBER 4 "42E+" +WHITESPACE 1 "\n" +FLOAT_NUMBER 4 "42E-" +WHITESPACE 2 "\n\n" +INT_NUMBER 2 "42" +DOT 1 "." +IDENT 1 "e" +PLUS 1 "+" +WHITESPACE 1 "\n" +INT_NUMBER 2 "42" +DOT 1 "." +IDENT 1 "e" +MINUS 1 "-" +WHITESPACE 1 "\n" +INT_NUMBER 2 "42" +DOT 1 "." +IDENT 1 "E" +PLUS 1 "+" +WHITESPACE 1 "\n" +INT_NUMBER 2 "42" +DOT 1 "." +IDENT 1 "E" +MINUS 1 "-" +WHITESPACE 2 "\n\n" +FLOAT_NUMBER 6 "42.2e+" +WHITESPACE 1 "\n" +FLOAT_NUMBER 6 "42.2e-" +WHITESPACE 1 "\n" +FLOAT_NUMBER 6 "42.2E+" +WHITESPACE 1 "\n" +FLOAT_NUMBER 6 "42.2E-" +WHITESPACE 2 "\n\n" +FLOAT_NUMBER 9 "42.2e+f32" +WHITESPACE 1 "\n" +FLOAT_NUMBER 9 "42.2e-f32" +WHITESPACE 1 "\n" +FLOAT_NUMBER 9 "42.2E+f32" +WHITESPACE 1 "\n" +FLOAT_NUMBER 9 "42.2E-f32" +WHITESPACE 1 "\n" +> error0..2 token("0e") msg(Missing digits after the exponent symbol) +> error3..5 token("0E") msg(Missing digits after the exponent symbol) +> error7..11 token("42e+") msg(Missing digits after the exponent symbol) +> error12..16 token("42e-") msg(Missing digits after the exponent symbol) +> error17..21 token("42E+") msg(Missing digits after the exponent symbol) +> error22..26 token("42E-") msg(Missing digits after the exponent symbol) +> error53..59 token("42.2e+") msg(Missing digits after the exponent symbol) +> error60..66 token("42.2e-") msg(Missing digits after the exponent symbol) +> error67..73 token("42.2E+") msg(Missing digits after the exponent symbol) +> error74..80 token("42.2E-") msg(Missing digits after the exponent symbol) +> error82..91 token("42.2e+f32") msg(Missing digits after the exponent symbol) +> error92..101 token("42.2e-f32") msg(Missing digits after the exponent symbol) +> error102..111 token("42.2E+f32") msg(Missing digits after the exponent symbol) +> error112..121 token("42.2E-f32") msg(Missing digits after the exponent symbol) diff --git a/crates/syntax/test_data/lexer/err/0057_lifetime_strarts_with_a_number.rs b/crates/syntax/test_data/lexer/err/0057_lifetime_strarts_with_a_number.rs new file mode 100644 index 000000000..a7698a404 --- /dev/null +++ b/crates/syntax/test_data/lexer/err/0057_lifetime_strarts_with_a_number.rs @@ -0,0 +1,2 @@ +'1 +'1lifetime diff --git a/crates/syntax/test_data/lexer/err/0057_lifetime_strarts_with_a_number.txt b/crates/syntax/test_data/lexer/err/0057_lifetime_strarts_with_a_number.txt new file mode 100644 index 000000000..e138bcebc --- /dev/null +++ b/crates/syntax/test_data/lexer/err/0057_lifetime_strarts_with_a_number.txt @@ -0,0 +1,6 @@ +LIFETIME 2 "\'1" +WHITESPACE 1 "\n" +LIFETIME 10 "\'1lifetime" +WHITESPACE 1 "\n" +> error0..2 token("\'1") msg(Lifetime name cannot start with a number) +> error3..13 token("\'1lifetime") msg(Lifetime name cannot start with a number) diff --git a/crates/syntax/test_data/lexer/ok/0001_hello.rs b/crates/syntax/test_data/lexer/ok/0001_hello.rs new file mode 100644 index 000000000..95d09f2b1 --- /dev/null +++ b/crates/syntax/test_data/lexer/ok/0001_hello.rs @@ -0,0 +1 @@ +hello world \ No newline at end of file diff --git a/crates/syntax/test_data/lexer/ok/0001_hello.txt b/crates/syntax/test_data/lexer/ok/0001_hello.txt new file mode 100644 index 000000000..27a5940a9 --- /dev/null +++ b/crates/syntax/test_data/lexer/ok/0001_hello.txt @@ -0,0 +1,3 @@ +IDENT 5 "hello" +WHITESPACE 1 " " +IDENT 5 "world" diff --git a/crates/syntax/test_data/lexer/ok/0002_whitespace.rs b/crates/syntax/test_data/lexer/ok/0002_whitespace.rs new file mode 100644 index 000000000..08fce1418 --- /dev/null +++ b/crates/syntax/test_data/lexer/ok/0002_whitespace.rs @@ -0,0 +1,4 @@ +a b c +d + +e f diff --git a/crates/syntax/test_data/lexer/ok/0002_whitespace.txt b/crates/syntax/test_data/lexer/ok/0002_whitespace.txt new file mode 100644 index 000000000..01d260918 --- /dev/null +++ b/crates/syntax/test_data/lexer/ok/0002_whitespace.txt @@ -0,0 +1,12 @@ +IDENT 1 "a" +WHITESPACE 1 " " +IDENT 1 "b" +WHITESPACE 2 " " +IDENT 1 "c" +WHITESPACE 1 "\n" +IDENT 1 "d" +WHITESPACE 2 "\n\n" +IDENT 1 "e" +WHITESPACE 1 "\t" +IDENT 1 "f" +WHITESPACE 1 "\n" diff --git a/crates/syntax/test_data/lexer/ok/0003_ident.rs b/crates/syntax/test_data/lexer/ok/0003_ident.rs new file mode 100644 index 000000000..c05c9c009 --- /dev/null +++ b/crates/syntax/test_data/lexer/ok/0003_ident.rs @@ -0,0 +1 @@ +foo foo_ _foo _ __ x ΠΏΡ€ΠΈΠ²Π΅Ρ‚ diff --git a/crates/syntax/test_data/lexer/ok/0003_ident.txt b/crates/syntax/test_data/lexer/ok/0003_ident.txt new file mode 100644 index 000000000..4a0d5c053 --- /dev/null +++ b/crates/syntax/test_data/lexer/ok/0003_ident.txt @@ -0,0 +1,14 @@ +IDENT 3 "foo" +WHITESPACE 1 " " +IDENT 4 "foo_" +WHITESPACE 1 " " +IDENT 4 "_foo" +WHITESPACE 1 " " +UNDERSCORE 1 "_" +WHITESPACE 1 " " +IDENT 2 "__" +WHITESPACE 1 " " +IDENT 1 "x" +WHITESPACE 1 " " +IDENT 12 "ΠΏΡ€ΠΈΠ²Π΅Ρ‚" +WHITESPACE 1 "\n" diff --git a/crates/syntax/test_data/lexer/ok/0004_numbers.rs b/crates/syntax/test_data/lexer/ok/0004_numbers.rs new file mode 100644 index 000000000..bc761c235 --- /dev/null +++ b/crates/syntax/test_data/lexer/ok/0004_numbers.rs @@ -0,0 +1,9 @@ +0 00 0_ 0. 0z +01790 0b1790 0o1790 0x1790aAbBcCdDeEfF 001279 0_1279 0.1279 0e1279 0E1279 +0..2 +0.foo() +0e+1 +0.e+1 +0.0E-2 +0___0.10000____0000e+111__ +1i64 92.0f32 11__s diff --git a/crates/syntax/test_data/lexer/ok/0004_numbers.txt b/crates/syntax/test_data/lexer/ok/0004_numbers.txt new file mode 100644 index 000000000..e19fc5789 --- /dev/null +++ b/crates/syntax/test_data/lexer/ok/0004_numbers.txt @@ -0,0 +1,57 @@ +INT_NUMBER 1 "0" +WHITESPACE 1 " " +INT_NUMBER 2 "00" +WHITESPACE 1 " " +INT_NUMBER 2 "0_" +WHITESPACE 1 " " +FLOAT_NUMBER 2 "0." +WHITESPACE 1 " " +INT_NUMBER 2 "0z" +WHITESPACE 1 "\n" +INT_NUMBER 5 "01790" +WHITESPACE 1 " " +INT_NUMBER 6 "0b1790" +WHITESPACE 1 " " +INT_NUMBER 6 "0o1790" +WHITESPACE 1 " " +INT_NUMBER 18 "0x1790aAbBcCdDeEfF" +WHITESPACE 1 " " +INT_NUMBER 6 "001279" +WHITESPACE 1 " " +INT_NUMBER 6 "0_1279" +WHITESPACE 1 " " +FLOAT_NUMBER 6 "0.1279" +WHITESPACE 1 " " +FLOAT_NUMBER 6 "0e1279" +WHITESPACE 1 " " +FLOAT_NUMBER 6 "0E1279" +WHITESPACE 1 "\n" +INT_NUMBER 1 "0" +DOT 1 "." +DOT 1 "." +INT_NUMBER 1 "2" +WHITESPACE 1 "\n" +INT_NUMBER 1 "0" +DOT 1 "." +IDENT 3 "foo" +L_PAREN 1 "(" +R_PAREN 1 ")" +WHITESPACE 1 "\n" +FLOAT_NUMBER 4 "0e+1" +WHITESPACE 1 "\n" +INT_NUMBER 1 "0" +DOT 1 "." +IDENT 1 "e" +PLUS 1 "+" +INT_NUMBER 1 "1" +WHITESPACE 1 "\n" +FLOAT_NUMBER 6 "0.0E-2" +WHITESPACE 1 "\n" +FLOAT_NUMBER 26 "0___0.10000____0000e+111__" +WHITESPACE 1 "\n" +INT_NUMBER 4 "1i64" +WHITESPACE 1 " " +FLOAT_NUMBER 7 "92.0f32" +WHITESPACE 1 " " +INT_NUMBER 5 "11__s" +WHITESPACE 1 "\n" diff --git a/crates/syntax/test_data/lexer/ok/0005_symbols.rs b/crates/syntax/test_data/lexer/ok/0005_symbols.rs new file mode 100644 index 000000000..487569b5a --- /dev/null +++ b/crates/syntax/test_data/lexer/ok/0005_symbols.rs @@ -0,0 +1,6 @@ +; , ( ) { } [ ] < > @ # ~ ? $ & | + * / ^ % +. .. ... ..= +: :: += => +! != +- -> diff --git a/crates/syntax/test_data/lexer/ok/0005_symbols.txt b/crates/syntax/test_data/lexer/ok/0005_symbols.txt new file mode 100644 index 000000000..2049c2f1d --- /dev/null +++ b/crates/syntax/test_data/lexer/ok/0005_symbols.txt @@ -0,0 +1,77 @@ +SEMICOLON 1 ";" +WHITESPACE 1 " " +COMMA 1 "," +WHITESPACE 1 " " +L_PAREN 1 "(" +WHITESPACE 1 " " +R_PAREN 1 ")" +WHITESPACE 1 " " +L_CURLY 1 "{" +WHITESPACE 1 " " +R_CURLY 1 "}" +WHITESPACE 1 " " +L_BRACK 1 "[" +WHITESPACE 1 " " +R_BRACK 1 "]" +WHITESPACE 1 " " +L_ANGLE 1 "<" +WHITESPACE 1 " " +R_ANGLE 1 ">" +WHITESPACE 1 " " +AT 1 "@" +WHITESPACE 1 " " +POUND 1 "#" +WHITESPACE 1 " " +TILDE 1 "~" +WHITESPACE 1 " " +QUESTION 1 "?" +WHITESPACE 1 " " +DOLLAR 1 "$" +WHITESPACE 1 " " +AMP 1 "&" +WHITESPACE 1 " " +PIPE 1 "|" +WHITESPACE 1 " " +PLUS 1 "+" +WHITESPACE 1 " " +STAR 1 "*" +WHITESPACE 1 " " +SLASH 1 "/" +WHITESPACE 1 " " +CARET 1 "^" +WHITESPACE 1 " " +PERCENT 1 "%" +WHITESPACE 1 "\n" +DOT 1 "." +WHITESPACE 1 " " +DOT 1 "." +DOT 1 "." +WHITESPACE 1 " " +DOT 1 "." +DOT 1 "." +DOT 1 "." +WHITESPACE 1 " " +DOT 1 "." +DOT 1 "." +EQ 1 "=" +WHITESPACE 1 "\n" +COLON 1 ":" +WHITESPACE 1 " " +COLON 1 ":" +COLON 1 ":" +WHITESPACE 1 "\n" +EQ 1 "=" +WHITESPACE 1 " " +EQ 1 "=" +R_ANGLE 1 ">" +WHITESPACE 1 "\n" +BANG 1 "!" +WHITESPACE 1 " " +BANG 1 "!" +EQ 1 "=" +WHITESPACE 1 "\n" +MINUS 1 "-" +WHITESPACE 1 " " +MINUS 1 "-" +R_ANGLE 1 ">" +WHITESPACE 1 "\n" diff --git a/crates/syntax/test_data/lexer/ok/0006_chars.rs b/crates/syntax/test_data/lexer/ok/0006_chars.rs new file mode 100644 index 000000000..454ee0a5f --- /dev/null +++ b/crates/syntax/test_data/lexer/ok/0006_chars.rs @@ -0,0 +1 @@ +'x' ' ' '0' 'hello' '\x7f' '\n' '\\' '\'' diff --git a/crates/syntax/test_data/lexer/ok/0006_chars.txt b/crates/syntax/test_data/lexer/ok/0006_chars.txt new file mode 100644 index 000000000..950954fbc --- /dev/null +++ b/crates/syntax/test_data/lexer/ok/0006_chars.txt @@ -0,0 +1,16 @@ +CHAR 3 "\'x\'" +WHITESPACE 1 " " +CHAR 3 "\' \'" +WHITESPACE 1 " " +CHAR 3 "\'0\'" +WHITESPACE 1 " " +CHAR 7 "\'hello\'" +WHITESPACE 1 " " +CHAR 6 "\'\\x7f\'" +WHITESPACE 1 " " +CHAR 4 "\'\\n\'" +WHITESPACE 1 " " +CHAR 4 "\'\\\\\'" +WHITESPACE 1 " " +CHAR 4 "\'\\\'\'" +WHITESPACE 1 "\n" diff --git a/crates/syntax/test_data/lexer/ok/0007_lifetimes.rs b/crates/syntax/test_data/lexer/ok/0007_lifetimes.rs new file mode 100644 index 000000000..b764f1dce --- /dev/null +++ b/crates/syntax/test_data/lexer/ok/0007_lifetimes.rs @@ -0,0 +1 @@ +'a 'foo 'foo_bar_baz '_ diff --git a/crates/syntax/test_data/lexer/ok/0007_lifetimes.txt b/crates/syntax/test_data/lexer/ok/0007_lifetimes.txt new file mode 100644 index 000000000..005c29100 --- /dev/null +++ b/crates/syntax/test_data/lexer/ok/0007_lifetimes.txt @@ -0,0 +1,8 @@ +LIFETIME 2 "\'a" +WHITESPACE 1 " " +LIFETIME 4 "\'foo" +WHITESPACE 1 " " +LIFETIME 12 "\'foo_bar_baz" +WHITESPACE 1 " " +LIFETIME 2 "\'_" +WHITESPACE 1 "\n" diff --git a/crates/syntax/test_data/lexer/ok/0008_byte_strings.rs b/crates/syntax/test_data/lexer/ok/0008_byte_strings.rs new file mode 100644 index 000000000..b54930f5e --- /dev/null +++ b/crates/syntax/test_data/lexer/ok/0008_byte_strings.rs @@ -0,0 +1,3 @@ +b'' b'x' b"foo" br"" +b''suf b""ix br""br +b'\n' b'\\' b'\'' b'hello' diff --git a/crates/syntax/test_data/lexer/ok/0008_byte_strings.txt b/crates/syntax/test_data/lexer/ok/0008_byte_strings.txt new file mode 100644 index 000000000..bc03b51a8 --- /dev/null +++ b/crates/syntax/test_data/lexer/ok/0008_byte_strings.txt @@ -0,0 +1,22 @@ +BYTE 3 "b\'\'" +WHITESPACE 1 " " +BYTE 4 "b\'x\'" +WHITESPACE 1 " " +BYTE_STRING 6 "b\"foo\"" +WHITESPACE 1 " " +RAW_BYTE_STRING 4 "br\"\"" +WHITESPACE 1 "\n" +BYTE 6 "b\'\'suf" +WHITESPACE 1 " " +BYTE_STRING 5 "b\"\"ix" +WHITESPACE 1 " " +RAW_BYTE_STRING 6 "br\"\"br" +WHITESPACE 1 "\n" +BYTE 5 "b\'\\n\'" +WHITESPACE 1 " " +BYTE 5 "b\'\\\\\'" +WHITESPACE 1 " " +BYTE 5 "b\'\\\'\'" +WHITESPACE 1 " " +BYTE 8 "b\'hello\'" +WHITESPACE 1 "\n" diff --git a/crates/syntax/test_data/lexer/ok/0009_strings.rs b/crates/syntax/test_data/lexer/ok/0009_strings.rs new file mode 100644 index 000000000..4ddb5bffc --- /dev/null +++ b/crates/syntax/test_data/lexer/ok/0009_strings.rs @@ -0,0 +1,2 @@ +"hello" r"world" "\n\"\\no escape" "multi +line" diff --git a/crates/syntax/test_data/lexer/ok/0009_strings.txt b/crates/syntax/test_data/lexer/ok/0009_strings.txt new file mode 100644 index 000000000..4cb4d711d --- /dev/null +++ b/crates/syntax/test_data/lexer/ok/0009_strings.txt @@ -0,0 +1,8 @@ +STRING 7 "\"hello\"" +WHITESPACE 1 " " +RAW_STRING 8 "r\"world\"" +WHITESPACE 1 " " +STRING 17 "\"\\n\\\"\\\\no escape\"" +WHITESPACE 1 " " +STRING 12 "\"multi\nline\"" +WHITESPACE 1 "\n" diff --git a/crates/syntax/test_data/lexer/ok/0010_single_line_comments.rs b/crates/syntax/test_data/lexer/ok/0010_single_line_comments.rs new file mode 100644 index 000000000..4b6653f9c --- /dev/null +++ b/crates/syntax/test_data/lexer/ok/0010_single_line_comments.rs @@ -0,0 +1,12 @@ +#!/usr/bin/env bash +// hello +//! World +//!! Inner line doc +/// Outer line doc +//// Just a comment + +// +//! +//!! +/// +//// diff --git a/crates/syntax/test_data/lexer/ok/0010_single_line_comments.txt b/crates/syntax/test_data/lexer/ok/0010_single_line_comments.txt new file mode 100644 index 000000000..98a3818c0 --- /dev/null +++ b/crates/syntax/test_data/lexer/ok/0010_single_line_comments.txt @@ -0,0 +1,22 @@ +SHEBANG 19 "#!/usr/bin/env bash" +WHITESPACE 1 "\n" +COMMENT 8 "// hello" +WHITESPACE 1 "\n" +COMMENT 9 "//! World" +WHITESPACE 1 "\n" +COMMENT 19 "//!! Inner line doc" +WHITESPACE 1 "\n" +COMMENT 18 "/// Outer line doc" +WHITESPACE 1 "\n" +COMMENT 19 "//// Just a comment" +WHITESPACE 2 "\n\n" +COMMENT 2 "//" +WHITESPACE 1 "\n" +COMMENT 3 "//!" +WHITESPACE 1 "\n" +COMMENT 4 "//!!" +WHITESPACE 1 "\n" +COMMENT 3 "///" +WHITESPACE 1 "\n" +COMMENT 4 "////" +WHITESPACE 1 "\n" diff --git a/crates/syntax/test_data/lexer/ok/0011_keywords.rs b/crates/syntax/test_data/lexer/ok/0011_keywords.rs new file mode 100644 index 000000000..1e91bff4e --- /dev/null +++ b/crates/syntax/test_data/lexer/ok/0011_keywords.rs @@ -0,0 +1,3 @@ +async fn use struct trait enum impl true false as extern crate +mod pub self super in where for loop while if match const +static mut type ref let else move return diff --git a/crates/syntax/test_data/lexer/ok/0011_keywords.txt b/crates/syntax/test_data/lexer/ok/0011_keywords.txt new file mode 100644 index 000000000..22c00eefb --- /dev/null +++ b/crates/syntax/test_data/lexer/ok/0011_keywords.txt @@ -0,0 +1,64 @@ +ASYNC_KW 5 "async" +WHITESPACE 1 " " +FN_KW 2 "fn" +WHITESPACE 1 " " +USE_KW 3 "use" +WHITESPACE 1 " " +STRUCT_KW 6 "struct" +WHITESPACE 1 " " +TRAIT_KW 5 "trait" +WHITESPACE 1 " " +ENUM_KW 4 "enum" +WHITESPACE 1 " " +IMPL_KW 4 "impl" +WHITESPACE 1 " " +TRUE_KW 4 "true" +WHITESPACE 1 " " +FALSE_KW 5 "false" +WHITESPACE 1 " " +AS_KW 2 "as" +WHITESPACE 1 " " +EXTERN_KW 6 "extern" +WHITESPACE 1 " " +CRATE_KW 5 "crate" +WHITESPACE 1 "\n" +MOD_KW 3 "mod" +WHITESPACE 1 " " +PUB_KW 3 "pub" +WHITESPACE 1 " " +SELF_KW 4 "self" +WHITESPACE 1 " " +SUPER_KW 5 "super" +WHITESPACE 1 " " +IN_KW 2 "in" +WHITESPACE 1 " " +WHERE_KW 5 "where" +WHITESPACE 1 " " +FOR_KW 3 "for" +WHITESPACE 1 " " +LOOP_KW 4 "loop" +WHITESPACE 1 " " +WHILE_KW 5 "while" +WHITESPACE 1 " " +IF_KW 2 "if" +WHITESPACE 1 " " +MATCH_KW 5 "match" +WHITESPACE 1 " " +CONST_KW 5 "const" +WHITESPACE 1 "\n" +STATIC_KW 6 "static" +WHITESPACE 1 " " +MUT_KW 3 "mut" +WHITESPACE 1 " " +TYPE_KW 4 "type" +WHITESPACE 1 " " +REF_KW 3 "ref" +WHITESPACE 1 " " +LET_KW 3 "let" +WHITESPACE 1 " " +ELSE_KW 4 "else" +WHITESPACE 1 " " +MOVE_KW 4 "move" +WHITESPACE 1 " " +RETURN_KW 6 "return" +WHITESPACE 1 "\n" diff --git a/crates/syntax/test_data/lexer/ok/0012_block_comment.rs b/crates/syntax/test_data/lexer/ok/0012_block_comment.rs new file mode 100644 index 000000000..b880a59d9 --- /dev/null +++ b/crates/syntax/test_data/lexer/ok/0012_block_comment.rs @@ -0,0 +1,3 @@ +/* */ +/**/ +/* /* */ */ diff --git a/crates/syntax/test_data/lexer/ok/0012_block_comment.txt b/crates/syntax/test_data/lexer/ok/0012_block_comment.txt new file mode 100644 index 000000000..2618e287e --- /dev/null +++ b/crates/syntax/test_data/lexer/ok/0012_block_comment.txt @@ -0,0 +1,6 @@ +COMMENT 5 "/* */" +WHITESPACE 1 "\n" +COMMENT 4 "/**/" +WHITESPACE 1 "\n" +COMMENT 11 "/* /* */ */" +WHITESPACE 1 "\n" diff --git a/crates/syntax/test_data/lexer/ok/0013_raw_strings.rs b/crates/syntax/test_data/lexer/ok/0013_raw_strings.rs new file mode 100644 index 000000000..e5ed0b693 --- /dev/null +++ b/crates/syntax/test_data/lexer/ok/0013_raw_strings.rs @@ -0,0 +1 @@ +r###"this is a r##"raw"## string"### diff --git a/crates/syntax/test_data/lexer/ok/0013_raw_strings.txt b/crates/syntax/test_data/lexer/ok/0013_raw_strings.txt new file mode 100644 index 000000000..9cf0957d1 --- /dev/null +++ b/crates/syntax/test_data/lexer/ok/0013_raw_strings.txt @@ -0,0 +1,2 @@ +RAW_STRING 36 "r###\"this is a r##\"raw\"## string\"###" +WHITESPACE 1 "\n" diff --git a/crates/syntax/test_data/lexer/ok/0014_raw_ident.rs b/crates/syntax/test_data/lexer/ok/0014_raw_ident.rs new file mode 100644 index 000000000..b40a1b6a2 --- /dev/null +++ b/crates/syntax/test_data/lexer/ok/0014_raw_ident.rs @@ -0,0 +1 @@ +r#raw_ident diff --git a/crates/syntax/test_data/lexer/ok/0014_raw_ident.txt b/crates/syntax/test_data/lexer/ok/0014_raw_ident.txt new file mode 100644 index 000000000..484689693 --- /dev/null +++ b/crates/syntax/test_data/lexer/ok/0014_raw_ident.txt @@ -0,0 +1,2 @@ +IDENT 11 "r#raw_ident" +WHITESPACE 1 "\n" -- cgit v1.2.3