Meta Stack Exchange is where users like you discuss bugs, features, and support issues that affect the software powering all 158 Stack Exchange communities.

What is meta?
Here's how it works:
  1. Any Stack Exchange user can ask a question
  2. The community provides support, votes on ideas, and reports bugs
  3. Your voice helps shape the way Stack Exchange operates

When commenting, I recently came across an issue when I needed to explain instance variables using the Ruby syntax @variablename; of course, I'm only allowed to mention one user per comment, so this proved tricky.

How do I stop comments from automatically creating user links when @ is used, and simply be interpreted as plain text?

share|improve this question
When I read this title, I thought you meant "escape" as in "run away from". Disappointed that you're not fleeing from your inbox =) – jadarnel27 Jan 6 '12 at 0:24
up vote 4 down vote accepted

Use \@ instead of @. That avoids the character is thought to be a @-reference, and allows it to be used.

share|improve this answer
Simple, really should have thought of that. Cheers. – Yule Jan 5 '12 at 23:28
Sadly the \ still shows up, but this does work – Michael Mrozek Jan 5 '12 at 23:36

Use backticks ` to make the @ mention into an inline code block.

share|improve this answer
Reasonable suggestion, however not applicable in this case as wouldn't want the text to look like code in this particular scenario. Good to know you can do this though – Yule Jan 5 '12 at 23:31
@Yule Admittedly, I like kiam's suggestion better, but isn't your @variable representing something in the code anyway? Hehe. – jonsca Jan 5 '12 at 23:33
It is representing something in the code, but it's not actual code. It's discussing the use of \@variables, rather than a particular \@variable in the question – Yule Jan 5 '12 at 23:35
@Yule Okay, got it. – jonsca Jan 5 '12 at 23:57
I think this approach looks more natural in most cases. +1 – jadarnel27 Jan 6 '12 at 0:27

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .