mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
synced 2025-01-24 01:09:38 -05:00
checkpatch: allow space between colon and bracket
Allow a space between a colon and subsequent opening bracket. This sequence may occur in inline assembler statements like asm( "ldr %[out], [%[in]]\n\t" : [out] "=r" (ret) : [in] "r" (addr) ); Link: http://lkml.kernel.org/r/20180403191655.23700-1-xypron.glpk@gmx.de Signed-off-by: Heinrich Schuchardt <xypron.glpk@gmx.de> Acked-by: Joe Perches <joe@perches.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
This commit is contained in:
parent
6a487211ec
commit
38dca988bb
1 changed files with 1 additions and 1 deletions
|
@ -4089,7 +4089,7 @@ sub process {
|
|||
my ($where, $prefix) = ($-[1], $1);
|
||||
if ($prefix !~ /$Type\s+$/ &&
|
||||
($where != 0 || $prefix !~ /^.\s+$/) &&
|
||||
$prefix !~ /[{,]\s+$/) {
|
||||
$prefix !~ /[{,:]\s+$/) {
|
||||
if (ERROR("BRACKET_SPACE",
|
||||
"space prohibited before open square bracket '['\n" . $herecurr) &&
|
||||
$fix) {
|
||||
|
|
Loading…
Add table
Reference in a new issue