# Possible Bug of List and Blockquote

**URL:** <https://talk.commonmark.org/t/possible-bug-of-list-and-blockquote/2025>\
**Category:** Implementation\
**Created:** [February 26, 2016, 6:38am UTC](https://talk.commonmark.org/t/possible-bug-of-list-and-blockquote/2025 "2016-02-26T06:38:12Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![lotabout](https://cdn.commonmark.org/user_avatar/talk.commonmark.org/lotabout/32/912_2.png) [@lotabout](https://talk.commonmark.org/u/lotabout)\
**Post date:** [February 26, 2016, 6:38am UTC](https://talk.commonmark.org/t/possible-bug-of-list-and-blockquote/2025/1 "2016-02-26T06:38:12Z")

</div>

I am learning the implementation of commonmark.js while coming up an test case:

```auto
1. > 1. a
   > 1. b
   > 
   > 
   > 1. c <- this should be part of the outer list

> 1. a
> 1. b
> 
> 
> 1. c <- this is the expected result

```

[Live Example](http://spec.commonmark.org/dingus/?text=1.%20%3E%201.%20a%0A%20%20%20%3E%201.%20b%0A%20%20%20%3E%20%0A%20%20%20%3E%20%0A%20%20%20%3E%201.%20c%20%20%3C-%20this%20should%20be%20part%20of%20the%20outer%20list%0A%0A%3E%201.%20a%0A%3E%201.%20b%0A%3E%20%0A%3E%20%0A%3E%201.%20c%20%3C-%20this%20is%20the%20expected%20result). I think the [markdown-it’s output](https://markdown-it.github.io/#md3=%7B%22source%22%3A%221.%20%3E%201.%20a%5Cn%20%20%20%3E%201.%20b%5Cn%20%20%20%3E%20%5Cn%20%20%20%3E%20%5Cn%20%20%20%3E%201.%20c%20%20%3C-%20this%20should%20be%20part%20of%20the%20outer%20list%5Cn%5Cn%3E%201.%20a%5Cn%3E%201.%20b%5Cn%3E%20%5Cn%3E%20%5Cn%3E%201.%20c%20%3C-%20this%20is%20the%20expected%20result%22%2C%22defaults%22%3A%7B%22html%22%3Afalse%2C%22xhtmlOut%22%3Afalse%2C%22breaks%22%3Afalse%2C%22langPrefix%22%3A%22language-%22%2C%22linkify%22%3Atrue%2C%22typographer%22%3Atrue%2C%22_highlight%22%3Atrue%2C%22_strict%22%3Afalse%2C%22_view%22%3A%22html%22%7D%7D) is the correct one.

While IMO it is a bug, but I don’t know what you guys think, so I post it here.

---

<div class="post-metadata">

**Author:** ![jgm](https://cdn.commonmark.org/user_avatar/talk.commonmark.org/jgm/32/1360_2.png) [@jgm](https://talk.commonmark.org/u/jgm)\
**Post date:** [February 26, 2016, 4:12pm UTC](https://talk.commonmark.org/t/possible-bug-of-list-and-blockquote/2025/2 "2016-02-26T16:12:54Z")

</div>

I think you’re right, this does look like a bug. Smaller case:

```auto
1. > 1. a
   > 
   > 
   > 1. c <- this should be part of the outer list

```

Could you put a bug report on jgm/cmark or jgm/commonmark.js?

Note: the “two blank lines breaks out of list” rule is under consideration for removal (see the “issues to resolve before 1.0” thread), so this might become irrelevant.

---

<div class="post-metadata">

**Author:** ![jgm](https://cdn.commonmark.org/user_avatar/talk.commonmark.org/jgm/32/1360_2.png) [@jgm](https://talk.commonmark.org/u/jgm)\
**Post date:** [March 20, 2016, 8:57pm UTC](https://talk.commonmark.org/t/possible-bug-of-list-and-blockquote/2025/3 "2016-03-20T20:57:43Z")

</div>

Actually, it’s not clear this is a bug. The rule (5.3) says that “two blank lines end all containing lists.” Since the outer list does contain the inner one (albeit with a blockquote intermediary), maybe the current behavior is not wrong.

In any case, this is not clear enough in the spec.

I am inclined to remove the two-blank-lines rule anyway. The complexity it adds isn’t justified by what it gives us, in my opinion.
