Mac Yosemite and em-dash


I’m running Atom 1.0.19 on Mac Yosemite 10.10.5. Even with smart quotes and dashes turned off in the Keyboard Preferences, two hyphens are converted to an em-dash. This happens every time, whether I put the second hyphen before or after the first. I’m having to fix the problem in vi or some other editor.


That’s super weird. Does it still happen if you run atom from the terminal with atom --safe?


Aha! Nevermind–I took a look at the original file from the Packt source download (and at on line #7). It’s not a hyphen (0x2D) but E28094 before the word recursive (offset 0xE4). That hex value looks like a hyphen on the screen, and adding a second hyphen makes it look like an em-dash. Backspace it all out and try again, and it’s okay. Sorry for not catching that before.