The following illustrates a markdown bug:

Proc := MyProc2;

    Proc();//calls MyProc2

Editor screen shot:


| improve this question | | | | |
  • 3
    I added a screen shot (after clicking 'edit' to see how it was formatted) – Tim Post Mar 14 '12 at 9:56
  • Oh thanks for that @Tim, I did not think to do that. – David Heffernan Mar 14 '12 at 10:11
  • 1
    Are you intentionally mixing NBSP (0xA0) and normal spaces? – Mat Mar 14 '12 at 10:11
  • @Mat No, I just typed spaces and/or used the format code button {} – David Heffernan Mar 14 '12 at 10:19
  • In that case, your system information/specs please. – Time Traveling Bobby Mar 14 '12 at 10:33
  • Chrome 17.0.963.79 m running on Win7 x64. I typed into the answer form. I also did a bit of copy/paste in the answer form. I have seen this issue a couple of times before but this time I decided to post on meta. – David Heffernan Mar 14 '12 at 10:37
  • So the paste part is the issue - you had those characters in the clip board. Remember their source? – Shadow Keeps Social Distance Mar 14 '12 at 11:17
  • @sha the source was the chrome edit box – David Heffernan Mar 14 '12 at 12:03
  • Downvoting bug reports?!! What is wrong with some people? – David Heffernan Mar 14 '12 at 18:39
  • 1
    @DavidHeffernan: personally, I don't think this is a bug. I think you have unreasonable expectations about Markdown. – John Saunders Mar 14 '12 at 19:19
  • @JohnSaunders It's easy enough to decree that the spaces have to be U+0020 rather than other space characters. Sure it's not a bug that way. But it's hardly helpful to the user to take that viewpoint. If software is meant to help people then this is just the sort of thing that should be made invisible by the computer. – David Heffernan Mar 14 '12 at 19:22
  • 1
    You've got to be kidding. – John Saunders Mar 14 '12 at 19:23
  • @John No I'm not kidding. What's more it seems I am not alone: meta.stackexchange.com/questions/125658/… meta.stackexchange.com/questions/116925/… – David Heffernan Mar 14 '12 at 21:34
  • I meant kidding about "If software is meant to help people then this is just the sort of thing that should be made invisible by the computer. ". – John Saunders Mar 14 '12 at 21:39
  • 2
    The OP clearly said he did not deliberately insert unicode spaces. He has no idea how they got there, and that's why he's coming here. What if this had been someone from say .. the Cooks, or Parenting site that had no idea what unicode was? I'm a little disappointed in how this was treated. – Tim Post Mar 16 '12 at 13:30

I don't know why you would put Unicode-magic space characters in there, but you can't really expect that to behave like a normal space. If you really think that you have to be able to use a U+00A0 in place of a regular ASCII space, that's a .

A code block has to be indented by four spaces or one tab, and I think it's pretty clear that "space" in that sentence means a plain good ol' ASCII 32. Since that's the largest key on my keyboard and thus the easiest way for me to insert a space, using any other kind of space means I am deliberately not inserting a regular space and hence expecting a different behavior.

This is notwithstanding the fact that there may currently be a bug in Chrome that erroneously inserts these characters. If that's the case and we're able to reproduce it, we'll try to work around it, but not by changing the semantics of Markdown.

I fixed a small preview/rendered version inconsistency that editing your post showed though; from the next build on, that'll be fixed: The server-rendered version will look like the preview – the first line is code, the second line isn't. That's the correct interpretation, since the first line starts with four spaces, the second one doesn't. So this part is a .

I'll let you choose which of the two tags you want.

| improve this answer | | | | |
  • 4
    [status-hit-and-miss] – BoltClock's a Unicorn Mar 14 '12 at 17:48
  • 2
    "I don't know why you would put Unicode-magic space characters in there." Well, I didn't intend to. Don't know how they got there. But there it is. It's happened before though. It's a shame that you don't seem to see how more flexible interpretation of input could help users. Software is meant to make life easier for people as Jeff so often said. U+00A0, Character.isSpaceChar() Yes. If that's not a space I don't know what is. After all, you can't tell them apart on the screen. – David Heffernan Mar 14 '12 at 18:43
  • 1
    I'll take status-declined please. – David Heffernan Mar 14 '12 at 18:48
  • 1
    Looks like this might be a larger issue with Chrome; possibly worth compensating for? – Adam Lear Mar 14 '12 at 20:57
  • @DavidHeffernan U+00A0 is a different character with a different meaning. If someone (deliberately) uses this character, they rightfully expect it to behave differently; otherwise they would have just used a regular space. If there is a bug in Chrome that causes a U+00A0 to be inserted erroneously, we'll try to work around that (if we can reproduce it), but changing the semantics of this character for the purposes of Markdown parsing is not the way to do that. – balpha Mar 15 '12 at 7:19
  • @balpha do you get a lot of people deliberately using U+00A0? Any at all? You are thinking like a computer but humans don't think that way. – David Heffernan Mar 15 '12 at 7:29
  • @DavidHeffernan After you deleted your other comment, I assumed we're now past the ad-hominem insult stage. I apologize for this wrong assumption and will no longer pursue this discussion. – balpha Mar 15 '12 at 8:08
  • @balpha I note that we still have the "largest key on my keyboard" quote. Given that so many others have experienced this, perhaps you might like to reconsider that part of your answer. I clearly do have a very different view from you as to how to interact with customers, but I over-stepped the mark by saying exactly what I thought. I am sorry about that. – David Heffernan Mar 15 '12 at 8:29
  • @David I have clarified what I mean with that quote; I can see how the original phrasing may appear to be condescending, it wasn't meant to. – balpha Mar 15 '12 at 8:49

Those are not ordinary spaces. Simple ASCII analysis of the exact string you wrote before the second line of code give the following result:

null characters

Here it is again to save the need to click "edit" on your post:
    (Just copy the contents of this inline code block)

Can't copy this for some reason, to copy the source click "edit" on the question and copy the spaces before the second line of code.

How did you come up with those fancy characters in the first place? Anyway, it's not a bug since those characters are not plain spaces.

| improve this answer | | | | |
  • I've no idea where the non-breaking spaces come from. No matter, it's still a bug. I've seen this a few times of late. – David Heffernan Mar 14 '12 at 10:26
  • Note that for example Chrome browser won't allow you to paste such characters in the address bar - how did you originally type them? Surely not simple keyboard key stroke? – Shadow Keeps Social Distance Mar 14 '12 at 10:27
  • I've no idea where they came from. I was just typing into the answer form from the Chrome browser on Windows. Since I can't see that they are NBSP the markdown processor should, in my view, treat them the same as spaces. – David Heffernan Mar 14 '12 at 10:29
  • 1
    That's up to the devs here. Can see your point, but still curious how such thing can happen in the first place. :) – Shadow Keeps Social Distance Mar 14 '12 at 10:35
  • 3
    A space, by any other name, is still a .. " Oh, wait. – Tim Post Mar 14 '12 at 11:01

You must log in to answer this question.

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