Skip to content

Commit 6eb67a4

Browse files
committed
README: cleanup
1 parent 7e6639d commit 6eb67a4

File tree

1 file changed

+3
-28
lines changed

1 file changed

+3
-28
lines changed

README.md

+3-28
Original file line numberDiff line numberDiff line change
@@ -18,16 +18,8 @@ I try to keep the grammar in sync with the C version, by
1818
cherry-picking relevant changes. In the commit history the
1919
corresponding revisions have a suffix *[jgm/peg-markdown].*
2020

21-
A simple benchmark has been done by comparing the
22-
execution times of the Go binary (cmd/main.go) and the
23-
original C implementation's binary needed for processing
24-
a Markdown document, which had been created by
25-
concatenating ten [Markdown syntax descriptions][syntax].
26-
27-
[syntax]: http://daringfireball.net/projects/markdown/syntax.text
28-
29-
The C version is still around 1.3x faster than the Go version.
30-
21+
The Markdown parser has a performance similar to that of
22+
the original C version, and consumes less memory.
3123

3224
## Installation
3325

@@ -38,24 +30,7 @@ Provided you have a copy of Go 1, and git is available,
3830
should download and install the package according to
3931
your GOPATH settings.
4032

41-
See doc.go for an example how to use the package. There has
42-
been an API change recently: Where you previously wrote
43-
44-
buf, err := ioutil.ReadAll(os.Stdin)
45-
...
46-
doc := markdown.Parse(string(buf), markdown.Extensions{Smart: true})
47-
doc.WriteHtml(w)
48-
49-
you would now write:
50-
51-
p := markdown.NewParser(&markdown.Extensions{Smart: true})
52-
53-
w := bufio.NewWriter(os.Stdout)
54-
p.Markdown(os.Stdin, markdown.ToHTML(w))
55-
w.Flush()
56-
57-
One purpose of the change is to have a Parser that can be
58-
reused between invocations of the converter.
33+
See doc.go for an example how to use the package.
5934

6035
---
6136

0 commit comments

Comments
 (0)