John MacFarlane
06e5a01787
js: renamed emph_stack -> emphasis_openers.
2014-10-24 10:16:44 -07:00
John MacFarlane
d6643c7a5b
Fixed a memory allocation error.
2014-10-24 10:15:50 -07:00
John MacFarlane
29fbcd6e57
Fixed memory leak by freeing all unused emphasis openers.
2014-10-24 10:09:30 -07:00
John MacFarlane
751fb7894c
Renamed subj->last_emphasis to subj->emphasis_openers.
2014-10-24 08:00:05 -07:00
John MacFarlane
6607a88478
inlines.js: Implemented stack-based emph parsing.
2014-10-23 23:29:30 -07:00
John MacFarlane
acfdce9fa8
Removed now-undeeded 'first' parameter in parse_inline.
2014-10-19 13:19:11 -07:00
John MacFarlane
50cb546d1c
Whitespace changes.
2014-10-19 13:08:23 -07:00
John MacFarlane
32abf27635
parse_inline: Correctly move to last inline.
2014-10-18 23:11:34 -07:00
John MacFarlane
db7434f4b1
Fixed performance regression.
...
See discussion under #157 .
2014-10-18 22:10:23 -07:00
John MacFarlane
a50384fac9
Don't emit empty str elements in handle_strong_emph.
2014-10-18 21:04:42 -07:00
John MacFarlane
93b1ac3408
Reindented c sources.
2014-10-18 21:02:21 -07:00
John MacFarlane
8b1a5abc80
Added renderAST to js, added AST render tab to dingus.
...
Modified processInlines so it creates new objects instead
of modifying in place. This way we can remove the extraneous
fields only needed for parsing.
2014-10-18 18:27:09 -07:00
John MacFarlane
2e01c72a7c
Added renderAST to js, added AST render tab to dingus.
...
Modified processInlines so it creates new objects instead
of modifying in place. This way we can remove the extraneous
fields only needed for parsing.
2014-10-18 18:26:37 -07:00
John MacFarlane
6fa280c2f4
Added 'make jshint'.
2014-10-18 17:40:05 -07:00
John MacFarlane
efff87ae0d
Add unescapeString as method of InlineParser.
2014-10-18 17:38:38 -07:00
John MacFarlane
e03f5ca7c6
Add unescapeString as method of InlineParser.
2014-10-18 17:38:00 -07:00
John MacFarlane
d91e106123
Factored out blocks.js from index.js.
2014-10-18 17:28:17 -07:00
John MacFarlane
a06c22541c
Factored out blocks.js from index.js.
2014-10-18 17:27:53 -07:00
John MacFarlane
41d17a5abe
Factored out inlines.js from index.js.
2014-10-18 17:24:33 -07:00
John MacFarlane
21bb27698e
Factored out inlines.js from index.js.
2014-10-18 17:23:56 -07:00
John MacFarlane
d571c76979
Change from-code-point.js so it doesn't alter String prototype.
2014-10-18 16:39:39 -07:00
John MacFarlane
fb143fbc17
Use browserify to make js code more modular.
...
* Moved js library code to `js/lib`.
* `js/stmd.js` is now generated from these files using browserify.
* Factored out `html5-entities.js` and `from-code-point.js` from main
js parsing code (which is now `index.js`).
* Moved `js/markdown` to `js/bin`.
2014-10-18 16:39:33 -07:00
John MacFarlane
17aa754c3c
Change from-code-point.js so it doesn't alter String prototype.
2014-10-18 16:38:19 -07:00
John MacFarlane
3b54fe2445
Use browserify to make js code more modular.
...
* Moved js library code to `js/lib`.
* `js/stmd.js` is now generated from these files using browserify.
* Factored out `html5-entities.js` and `from-code-point.js` from main
js parsing code (which is now `index.js`).
* Moved `js/markdown` to `js/bin`.
2014-10-18 16:31:59 -07:00
John MacFarlane
f9e91b6d2d
Merge branch 'master' of https://github.com/Knagis/stmd into emphstack
2014-10-18 14:00:36 -07:00
Abdülhamit Yilmaz
cfd6fea109
Add missing MIN directive
...
It's needed in strbuf_cmp().
2014-10-13 12:10:56 +02:00
user
c667b141b8
After inline parsing free any remaining InlineStack instances.
2014-10-09 07:44:11 -04:00
user
de80806ef5
Modified inline parsing to keep track of two pointers - the head of the list and the tail.
2014-10-09 07:36:37 -04:00
Knagis
7d7011b918
Revert "Modified inline parsing to keep track of two pointers - the head of the list and the tail."
...
This reverts commit bc78ad0a18
.
2014-10-09 14:34:36 +03:00
Knagis
bc78ad0a18
Modified inline parsing to keep track of two pointers - the head of the list and the tail.
2014-10-09 07:29:25 -04:00
John MacFarlane
3bd95fb511
Merge branch 'master' of github.com:jgm/stmd
2014-10-08 21:59:24 -07:00
Gulliver
7da937e2ae
Merge branch 'master' into cmake-build
...
* master: (75 commits)
Remove duplicate `footer`
Correct capitalization of JavaScript
Added link to commonmark.org on web page.
Added cases from #51 to spec.
Added test case from issue #147 .
Removed uthash license. We no longer use this library.
Removed bstrlib license. We no longer use this library.
Removed oldtests.
Cleaned up entity section of spec.
Adjusted tests for new js parser.
stmd.js: Fixed entityToChar, adding fromCodePoint polyfill.
Reset label_nest_level before parsing reference.
Removed spurious 'and', reflowed.
Removed spurious 'and', reflowed.
Further emph fallback optimizations.
Some jshint fixes.
Use simpler algorithm.
Revert "Use integers instead of strings for tags."
Revert "Use numerical constants."
Use numerical constants.
...
2014-10-09 00:45:00 +02:00
Gulliver
1703abe7a2
Merge branch 'master' into cmake-build
...
* master:
Adds missing newlines
Changes urls to use example.com
Changes append to prepend
Suppress 'missing field initializer' warnings
Makefile: Use ?= so variables can be set on command line.
Fix some compatibility issues
2014-10-09 00:26:00 +02:00
John MacFarlane
c69bfce61e
Merge pull request #155 from wbond/master
...
Remove duplicate `footer`
2014-10-08 10:36:36 -07:00
Will Bond
1806a06c34
Remove duplicate `footer`
2014-10-08 11:29:47 -04:00
Knagis
8837f19960
Implemented stack-based algorithm for matching emphasis
2014-10-08 11:39:47 +03:00
Kārlis Gaņģis
43b8646d44
Merge pull request #1 from jgm/master
...
merge
2014-10-08 11:02:43 +03:00
John MacFarlane
a8722bef85
Changed bench.js so it no longer requires oldtests.
2014-10-07 23:39:24 -07:00
Bengt Lüers
daeb55edc7
Correct capitalization of JavaScript
2014-10-07 23:12:36 -07:00
John MacFarlane
c74f15daae
Added link to commonmark.org on web page.
...
Closes #23 .
2014-10-07 23:07:28 -07:00
John MacFarlane
735f77b2a6
Added cases from #51 to spec.
...
Closes #51 .
2014-10-07 23:00:56 -07:00
John MacFarlane
8122177e49
Added test case from issue #147 .
2014-10-07 22:45:19 -07:00
John MacFarlane
dceca7a50f
Removed uthash license. We no longer use this library.
2014-10-07 22:36:20 -07:00
John MacFarlane
f1cc071037
Removed bstrlib license. We no longer use this library.
2014-10-07 22:35:44 -07:00
John MacFarlane
bc5b7c288d
Removed oldtests.
2014-10-07 22:35:19 -07:00
John MacFarlane
a411013e62
Merge branch 'master' into newemphasis
...
Conflicts:
spec.txt
2014-10-07 22:28:01 -07:00
John MacFarlane
d3c3e749f4
Cleaned up entity section of spec.
...
We convert entities to unicode characters, not UTF-8 sequences.
(Though they might ultimately be output that way.)
2014-10-07 22:24:53 -07:00
John MacFarlane
3d99baba06
Adjusted tests for new js parser.
2014-10-07 22:21:03 -07:00
John MacFarlane
c0c33f8332
stmd.js: Fixed entityToChar, adding fromCodePoint polyfill.
...
Closes #151 .
2014-10-07 22:02:21 -07:00
John MacFarlane
aabd412250
Reset label_nest_level before parsing reference.
...
This fixes a bug with text like:
[[some unrelated text [link]
[link]: destination
See #146 .
2014-10-07 21:34:39 -07:00