Lukasa / language-restructuredtext

A ReStructuredText syntax package for Atom
MIT License
27 stars 15 forks source link

Fix errors with parsing indented code-blocks #38

Closed Alhadis closed 8 years ago

Alhadis commented 8 years ago

Last night I begun "translating" a document into reStructuredText, and I noticed an issue (which was already reported). I fixed it for you.

Notes:

Alhadis commented 8 years ago

In case it wasn't clear, this PR patches both issues mentioned in #22. There were two separate (but related) bugs.

Lukasa commented 8 years ago

Thanks for this @Alhadis! :sparkles:

Alhadis commented 8 years ago

Crap, you already pushed a release. Uh, I'm in the middle of adding Doctest Block highlighting too... just smoothing out some potential edge-cases:

Figure 3

This how it's meant to go? I'm no fan of Python, so I wouldn't know much about this >>> stuff.

Lukasa commented 8 years ago

Heh, that's ok, we can do lots of releases. Releases are good. =D

Per docutils documentation:

Doctest blocks are text blocks which begin with ">>> ", the Python interactive interpreter main prompt, and end with a blank line.

So that highlighting isn't quite right, I'm afraid.

Alhadis commented 8 years ago

How's this?

screen shot 2016-05-24 at 7 03 29 pm
Lukasa commented 8 years ago

That looks great, I'd merge that. =D

Alhadis commented 8 years ago

Done too.

Sorry about prompting a double-release, haha.

Lukasa commented 8 years ago

No worries, pushing releases is easy. =D