Skip to content

Commit

Permalink
Merge pull request #6983 from aditya-deshpande-arm/backport-check-fil…
Browse files Browse the repository at this point in the history
…es-characters

[Backport 2.28] check_files.py: Allow specific Box Drawings characters to be used
  • Loading branch information
gilles-peskine-arm authored Feb 3, 2023
2 parents fc9cb13 + a9186f3 commit a4f9148
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion tests/scripts/check_files.py
Original file line number Diff line number Diff line change
Expand Up @@ -268,7 +268,7 @@ class UnicodeIssueTracker(LineIssueTracker):

heading = "Invalid UTF-8 or forbidden character:"

# Only allow valid UTF-8, and only white-listed characters.
# Only allow valid UTF-8, and only other explicitly allowed characters.
# We deliberately exclude all characters that aren't a simple non-blank,
# non-zero-width glyph, apart from a very small set (tab, ordinary space,
# line breaks, "basic" no-break space and soft hyphen). In particular,
Expand All @@ -285,6 +285,7 @@ class UnicodeIssueTracker(LineIssueTracker):
'\u2070\u2071\u2074-\u208E\u2090-\u209C', # Superscripts and Subscripts
'\u2190-\u21FF', # Arrows
'\u2200-\u22FF', # Mathematical Symbols
'\u2500-\u257F' # Box Drawings characters used in markdown trees
])
# Allow any of the characters and ranges above, and anything classified
# as a word constituent.
Expand Down

0 comments on commit a4f9148

Please sign in to comment.