<feed xmlns='http://www.w3.org/2005/Atom'>
<title>cmark/src/inlines.c, branch master</title>
<subtitle>My own fork of cmark for commonmark conversion</subtitle>
<link rel='alternate' type='text/html' href='http://ns2.complex-networks.net/cmark/'/>
<entry>
<title>Don't call memcpy with NULL as 1st parameter.</title>
<updated>2020-05-14T00:07:29+00:00</updated>
<author>
<name>John MacFarlane</name>
<email>jgm@berkeley.edu</email>
</author>
<published>2020-05-14T00:07:29+00:00</published>
<link rel='alternate' type='text/html' href='http://ns2.complex-networks.net/cmark/commit/?id=53abb8e3ab21a31ca7b4921207bd97bb42355c80'/>
<id>53abb8e3ab21a31ca7b4921207bd97bb42355c80</id>
<content type='text'>
This is illegal according to the C standard, sec. 7.1.4.

"If an argument to a function has an invalid value (such as a value
outside the domain of the function, or a pointer outside the address
space of the program, or a null pointer, or a pointer to non-modifiable
storage when the corresponding parameter is not const-qualified) or a
type (after promotion) not expected by a function with variable number
of arguments, the behavior is undefined."

7.24.1(2): "Where an argument declared as size_t n specifies the length
of the array for a function, n can have the value zero […] pointer
arguments on such a call shall still have valid values, as described in
7.1.4."

See https://www.imperialviolet.org/2016/06/26/nonnull.html
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
This is illegal according to the C standard, sec. 7.1.4.

"If an argument to a function has an invalid value (such as a value
outside the domain of the function, or a pointer outside the address
space of the program, or a null pointer, or a pointer to non-modifiable
storage when the corresponding parameter is not const-qualified) or a
type (after promotion) not expected by a function with variable number
of arguments, the behavior is undefined."

7.24.1(2): "Where an argument declared as size_t n specifies the length
of the array for a function, n can have the value zero […] pointer
arguments on such a call shall still have valid values, as described in
7.1.4."

See https://www.imperialviolet.org/2016/06/26/nonnull.html
</pre>
</div>
</content>
</entry>
<entry>
<title>Add NOLINTNEXTLINE to avoid a useless linter error.</title>
<updated>2020-05-13T23:23:41+00:00</updated>
<author>
<name>John MacFarlane</name>
<email>jgm@berkeley.edu</email>
</author>
<published>2020-05-13T23:23:41+00:00</published>
<link rel='alternate' type='text/html' href='http://ns2.complex-networks.net/cmark/commit/?id=43ceb9ed52eed01de2933bc0ef48d120a15be75a'/>
<id>43ceb9ed52eed01de2933bc0ef48d120a15be75a</id>
<content type='text'>
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
</pre>
</div>
</content>
</entry>
<entry>
<title>Rearrange struct cmark_node</title>
<updated>2020-01-23T16:25:54+00:00</updated>
<author>
<name>Nick Wellnhofer</name>
<email>wellnhofer@aevum.de</email>
</author>
<published>2020-01-19T12:46:10+00:00</published>
<link rel='alternate' type='text/html' href='http://ns2.complex-networks.net/cmark/commit/?id=f3f50b29d615d2678d8047dc277b108cc5143167'/>
<id>f3f50b29d615d2678d8047dc277b108cc5143167</id>
<content type='text'>
Introduce multi-purpose data/len members in struct cmark_node. This
is mainly used to store literal text for inlines, code and HTML blocks.

Move the content strbuf for blocks from cmark_node to cmark_parser.
When finalizing nodes that allow inlines (paragraphs and headings),
detach the strbuf and store the block content in the node's data/len
members. Free the block content after processing inlines.

Reduces size of struct cmark_node by 8 bytes.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Introduce multi-purpose data/len members in struct cmark_node. This
is mainly used to store literal text for inlines, code and HTML blocks.

Move the content strbuf for blocks from cmark_node to cmark_parser.
When finalizing nodes that allow inlines (paragraphs and headings),
detach the strbuf and store the block content in the node's data/len
members. Free the block content after processing inlines.

Reduces size of struct cmark_node by 8 bytes.
</pre>
</div>
</content>
</entry>
<entry>
<title>Use C string instead of chunk for literal text</title>
<updated>2020-01-23T16:25:54+00:00</updated>
<author>
<name>Nick Wellnhofer</name>
<email>wellnhofer@aevum.de</email>
</author>
<published>2020-01-18T23:51:02+00:00</published>
<link rel='alternate' type='text/html' href='http://ns2.complex-networks.net/cmark/commit/?id=b0a4cfa36e99c27dd2b20be8f8888fa7721bad58'/>
<id>b0a4cfa36e99c27dd2b20be8f8888fa7721bad58</id>
<content type='text'>
Use zero-terminated C strings and a separate length field instead of
cmark_chunks. Literal inline text will now be copied from the parent
block's content buffer, slowing the benchmark down by 10-15%.

The node struct never references memory of other nodes now, fixing #309.
Node accessors don't have to check for delayed creation of C strings,
so parsing and iterating all literals using the public API should
actually be faster than before.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Use zero-terminated C strings and a separate length field instead of
cmark_chunks. Literal inline text will now be copied from the parent
block's content buffer, slowing the benchmark down by 10-15%.

The node struct never references memory of other nodes now, fixing #309.
Node accessors don't have to check for delayed creation of C strings,
so parsing and iterating all literals using the public API should
actually be faster than before.
</pre>
</div>
</content>
</entry>
<entry>
<title>Use C string instead of chunk for link URL and title</title>
<updated>2020-01-23T16:25:54+00:00</updated>
<author>
<name>Nick Wellnhofer</name>
<email>wellnhofer@aevum.de</email>
</author>
<published>2020-01-18T22:12:37+00:00</published>
<link rel='alternate' type='text/html' href='http://ns2.complex-networks.net/cmark/commit/?id=b237924585e61532ada774bf9e70eadff00666dc'/>
<id>b237924585e61532ada774bf9e70eadff00666dc</id>
<content type='text'>
Use zero-terminated C strings instead of cmark_chunks without storing
the length. This introduces a few additional strlen computations,
but overhead should be low.

Allows to reduce size of struct cmark_node later.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Use zero-terminated C strings instead of cmark_chunks without storing
the length. This introduces a few additional strlen computations,
but overhead should be low.

Allows to reduce size of struct cmark_node later.
</pre>
</div>
</content>
</entry>
<entry>
<title>Cleaner approach to max digits for numeric entities.</title>
<updated>2019-11-11T20:55:33+00:00</updated>
<author>
<name>John MacFarlane</name>
<email>jgm@berkeley.edu</email>
</author>
<published>2019-11-11T20:55:33+00:00</published>
<link rel='alternate' type='text/html' href='http://ns2.complex-networks.net/cmark/commit/?id=7b35d4bdc5e514ded03c0f0012983fe315a3aaf4'/>
<id>7b35d4bdc5e514ded03c0f0012983fe315a3aaf4</id>
<content type='text'>
This modifies unescaping in houdini_html_u.c rather than
the entity handling in inlines.c.  Unlike the other,
this approach works also in e.g. link titles.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
This modifies unescaping in houdini_html_u.c rather than
the entity handling in inlines.c.  Unlike the other,
this approach works also in e.g. link titles.
</pre>
</div>
</content>
</entry>
<entry>
<title>Fix entity parser (and api test) to respect length limit on numeric entities.</title>
<updated>2019-11-11T20:52:35+00:00</updated>
<author>
<name>John MacFarlane</name>
<email>jgm@berkeley.edu</email>
</author>
<published>2019-11-11T20:52:35+00:00</published>
<link rel='alternate' type='text/html' href='http://ns2.complex-networks.net/cmark/commit/?id=cb1cd888cce0cae20a33663d6d17ef7630c5d4d7'/>
<id>cb1cd888cce0cae20a33663d6d17ef7630c5d4d7</id>
<content type='text'>
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
</pre>
</div>
</content>
</entry>
<entry>
<title>Code reformat</title>
<updated>2019-11-11T20:40:37+00:00</updated>
<author>
<name>John MacFarlane</name>
<email>jgm@berkeley.edu</email>
</author>
<published>2019-11-11T20:40:37+00:00</published>
<link rel='alternate' type='text/html' href='http://ns2.complex-networks.net/cmark/commit/?id=7d04065de4c793003af01647ff23132de1c9e919'/>
<id>7d04065de4c793003af01647ff23132de1c9e919</id>
<content type='text'>
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
</pre>
</div>
</content>
</entry>
<entry>
<title>Don't allow link destinations with unbalanced unescaped parentheses.</title>
<updated>2019-11-11T20:38:52+00:00</updated>
<author>
<name>John MacFarlane</name>
<email>jgm@berkeley.edu</email>
</author>
<published>2019-11-11T20:38:52+00:00</published>
<link rel='alternate' type='text/html' href='http://ns2.complex-networks.net/cmark/commit/?id=58dd044ca1ea8316f4f4b6034eec12d204cc6913'/>
<id>58dd044ca1ea8316f4f4b6034eec12d204cc6913</id>
<content type='text'>
See commonmark/commonmark.js#177.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
See commonmark/commonmark.js#177.
</pre>
</div>
</content>
</entry>
<entry>
<title>Update code span normalization...</title>
<updated>2019-04-05T05:05:12+00:00</updated>
<author>
<name>John MacFarlane</name>
<email>jgm@berkeley.edu</email>
</author>
<published>2019-04-05T05:05:12+00:00</published>
<link rel='alternate' type='text/html' href='http://ns2.complex-networks.net/cmark/commit/?id=4bb756a98c0982b8b39b4eee8091e1a5f60d7111'/>
<id>4bb756a98c0982b8b39b4eee8091e1a5f60d7111</id>
<content type='text'>
to conform with spec change.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
to conform with spec change.
</pre>
</div>
</content>
</entry>
</feed>
