11

Test one

The test is to render a backslash in code block:
Transcript:

 ....\\....\(KKK\) 

Rendering

\\\(KKK\) 

Test two

The test is to render a backslash in `backquotes`
Transcript

 `\\\`.. `\(KKK\)` 

Rendering:
\\\
\(KKK\)

Now performing the same in the comments (see below) and the rendering is different.

ps. In transcript . means <space>

6
  • Test one: \\ (KKKK) Commented Jul 29, 2010 at 15:56
  • Test two: \\` (KKK)` Commented Jul 29, 2010 at 15:57
  • Test two part two only: \(KKK\) Commented Jul 29, 2010 at 15:58
  • Test two part one only: `\\` Commented Jul 29, 2010 at 15:58
  • Added additional comment to the meta.so.com meta.stackexchange.com/questions/11388/… Commented Jul 31, 2010 at 13:35
  • For formatting of backticks and backslashes in posts, see the Formatting Sand-Box. Also, see this comment for comment-related formatting of the symbols. Commented Jun 4, 2013 at 18:24

3 Answers 3

4

So is it different in comments and answers? If I do

`\( ... \)` 

then it works as I expect: \( .. \).


Edit: Okay! So that's an inconsistency between the two and I'd rate that a bug.

18
  • So let's try in a comment: \( .. \). Commented Jul 29, 2010 at 11:34
  • See? Now it works, even in old comments! Commented Feb 20, 2011 at 21:26
  • Single backslash inside tick marks: `` Commented Dec 30, 2018 at 14:44
  • Double backslash: `\` Commented Dec 30, 2018 at 14:44
  • Triple backslash: `\\` Commented Dec 30, 2018 at 14:44
  • Quadruple backslash: `\\\` Commented Dec 30, 2018 at 14:44
  • 5 backslashes: `\\\\` Commented Dec 30, 2018 at 14:44
  • What about empty backticks? `` Commented Dec 30, 2018 at 14:46
  • What if I add spaces? No backslash (backtick-space-space-backtick): ` ` Commented Dec 30, 2018 at 14:47
  • Do spaces collapse? (1 space, "1", 2 spaces, "2", 3 spaces, "3", 4 spaces) ` 1 2 3 ` Commented Dec 30, 2018 at 14:48
  • Why are they not working? abc Commented Dec 30, 2018 at 14:49
  • 5 spaces in the middle: before after Commented Dec 30, 2018 at 14:49
  • Any way to get multiple spaces? What about backtick-"before"-2 spaces-backslash-2 spaces-"after"-backtick? before \ after Commented Dec 30, 2018 at 14:50
  • What about alternating letters and backticks? Backtick on both ends: abcdefgh` Commented Dec 30, 2018 at 14:52
  • What if I use non-breaking spaces? "a", 3 NBSPs, "b": a b Commented Dec 30, 2018 at 14:58
4

That's part of the Markdown syntax, personally I'm not thrilled about it either (specially within backticks), but that's how it's documented.

Incidentally, I was just writing a comment and it took me ages to figure out how is one supposed to enter a coded line-break.

Here \\ works.

Here `\\` works 

But on a comment I had to type

On a comment `\\ `, because `\\` doesn't work! 

inconsistent and not practical at all!

2
  • On a comment \\ , because `\` doesn't work! Commented Jul 29, 2010 at 12:00
  • Well, the documentation also talks about backslash escapes for {, but this isn't in effect in inline code in comments. Commented Jan 24, 2011 at 18:12
4

I had exactly the same problem in a comment to this answer to a question of mine, and it's a real pain. Is there any hope that this bug gets fixed in the near future? (I know that answers are not really a place to ask questions, but my aim is just to give the original post here some more emphasis.)


This now got implemented as follows: Backslash escaping in inline code in comments is disabled, except for a backtick ` within single backticks `...`. For the two examples: ``\\\`` gives \\\, and `\(KKK\)` gives \(KKK\) (note that there are no line breaks and hence no code blocks in comments). For details have a look here.

0

You must log in to answer this question.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.