lkml.org 
[lkml]   [2018]   [Jan]   [24]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
From
Date
SubjectRe: [tip:perf/urgent] perf/core: Fix lock inversion between perf,trace,cpuhp
On Wed, Jan 24, 2018 at 7:32 AM, Ingo Molnar <mingo@kernel.org> wrote:
>
> Oh, the '#' was probably interpreted as a comment when I applied it ...

Indeed. That's a subtle gotcha when you cut-and-paste things into the
editor when editing a commit message (including the "git rebase -i" or
"git commit --amend" kind of editing).

If you just apply it as an email, the hash-marks at the beginning of
lines are not seen as comments - it's literally just the editing part
that uses them as comments.

I'm afraid this isn't really a git "bug". But it _is_ subtle and unlucky.

Note that only a hash-mark in the first column is seen as a comment
(unlike, say, shell programming), so you can avoid it with spacing. If
you quote code with #ifdef etc, indent it.

Maybe git should have used a different comment scheme, but I have to
admit that I think this is the first time I've heard of this issue
causing problems in practice. I'm sure it's triggered before, and
nobody has noticed (or I wasn't on the cc).

So the '#' thing _normally_ works, but yes, it can cause issues.

Linus

\
 
 \ /
  Last update: 2018-01-24 17:57    [W:0.834 / U:0.132 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site