all repos — grayfriday @ c9ea588e6f2982de480eaea6129d00ee1aa47fbb

blackfriday fork with a few changes

Convert uint32 fields to ints

The former is a bit too inconvenient despite being more accurate.
Vytautas Ĺ altenis vytas@rtfb.lt
Mon, 11 Apr 2016 11:15:15 +0300
commit

c9ea588e6f2982de480eaea6129d00ee1aa47fbb

parent

98ddf9899707b54da904d2f654970fe466e3c0bb

3 files changed, 6 insertions(+), 6 deletions(-)

jump to
M block.goblock.go

@@ -267,7 +267,7 @@ id = sanitized_anchor_name.Create(string(data[i:end]))

} block := p.addBlock(Header, data[i:end]) block.HeaderID = id - block.Level = uint32(level) + block.Level = level } return skip }

@@ -1423,7 +1423,7 @@ id = sanitized_anchor_name.Create(string(data[prev:eol]))

} block := p.addBlock(Header, data[prev:eol]) - block.Level = uint32(level) + block.Level = level block.HeaderID = id // find the end of the underline
M markdown.gomarkdown.go

@@ -472,7 +472,7 @@ var topList *Node

var listNode *Node var lastItem *Node headerCount := 0 - var currentLevel uint32 + currentLevel := 0 p.doc.Walk(func(node *Node, entering bool) WalkStatus { if entering && node.Type == Header { if node.Level > currentLevel {
M node.gonode.go

@@ -83,8 +83,8 @@ type CodeBlockData struct {

IsFenced bool // Specifies whether it's a fenced code block or an indented one Info []byte // This holds the info string FenceChar byte - FenceLength uint32 - FenceOffset uint32 + FenceLength int + FenceOffset int } type TableCellData struct {

@@ -93,7 +93,7 @@ Align CellAlignFlags // This holds the value for align attribute

} type HeaderData struct { - Level uint32 // This holds the heading level number + Level int // This holds the heading level number HeaderID string // This might hold header ID, if present IsTitleblock bool // Specifies whether it's a title block }