public inbox for u-boot@lists.denx.de
 help / color / mirror / Atom feed
* [PATCH] checkpatch: fix a false check against wchar/utf-16 string
@ 2020-06-16  5:43 AKASHI Takahiro
  2020-06-16 14:17 ` Tom Rini
  0 siblings, 1 reply; 6+ messages in thread
From: AKASHI Takahiro @ 2020-06-16  5:43 UTC (permalink / raw)
  To: u-boot

UEFI subsystem uses utf-16 string, but checkpatch.pl complains
about any occurrences of L"xxx" which is definitely legal.
So just suppress this kind of warning.
Precautiously, we will check u"xxx" as well.

Signed-off-by: AKASHI Takahiro <takahiro.akashi@linaro.org>
---
 scripts/checkpatch.pl | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/scripts/checkpatch.pl b/scripts/checkpatch.pl
index edba36565167..b3697720787c 100755
--- a/scripts/checkpatch.pl
+++ b/scripts/checkpatch.pl
@@ -5462,7 +5462,7 @@ sub process {
 		}
 
 # concatenated string without spaces between elements
-		if ($line =~ /$String[A-Za-z0-9_]/ || $line =~ /[A-Za-z0-9_]$String/) {
+		if ($line =~ /$String[A-Za-z0-9_]/ || $line =~ /([A-Za-z0-9_]+[Lu]|[A-Za-z0-9_]*[A-KM-Za-tv-z0-9_])$String/) {
 			if (CHK("CONCATENATED_STRING",
 				"Concatenated strings should use spaces between elements\n" . $herecurr) &&
 			    $fix) {
-- 
2.27.0

^ permalink raw reply related	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2020-07-03  6:08 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2020-06-16  5:43 [PATCH] checkpatch: fix a false check against wchar/utf-16 string AKASHI Takahiro
2020-06-16 14:17 ` Tom Rini
2020-07-02 17:00   ` Heinrich Schuchardt
2020-07-02 20:26     ` Tom Rini
2020-07-03  5:45       ` AKASHI Takahiro
2020-07-03  6:08         ` Heinrich Schuchardt

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox