Surfacing the list bullet marker type
Nobody has claimed this yet.
- Dominant language
- C
- Stars
- 2k
- Forks
- 691
- Avg merge
- 1d 16h
- Merged PRs (30d)
- 1
Description
Howdy,
Currently ordered lists expose which delimiter, . or ), was used when defining a list. I'd like to add functionality which does something similar for unordered lists. Such that the bullet-type is made available to the AST and/or output. So something consuming the AST or output could check for something like plus, hyphen, or asterisk when +, -, or * was used to construct the list.
Is that kind of functionality something that would be accepted upstream? I'm asking this first, because instead of adding this to cmark I could instead create an entirely separate pre-processor tool for our use case, but that would be non-ideal compared to adding support to cmark. Especially given that adding this would add balance to the current discrepancy in available AST detail between ordered and unordered lists.
If it is something that would have a chance at being accepted upstream, then there are two ways of implementing this that make sense to me.
-
Extending the existing
cmark_delim_typeincmark.hto include additional delimiters for bullet-type, but that then makes this type cover more than its original intended function, which was clearly intended only for ordered lists. -
Creating an entirely new type such as
cmark_bullet_typeincmark.hto represent the different unordered list bullet types, but then this adds a whole new data type to cmark.
Either of these methods will work, but I want to make sure the solution I pursue fits in with how the cmark maintainers would prefer the extra context/metadata be captured and represented.
Any guidance on any of the above would be very helpful.
Thank you.
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by reading cmark.h and the existing ordered-list delimiter representation described in the issue. The work would need an agreed upstream design for exposing +, -, or * through the AST or output; no specific implementation files or tests are named.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- c
- Domain
- compilers
- Issue type
- Feature
- Difficulty
- 5/5
- Estimated time
- Over a week
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 25/100