<commit_before>package mark

import (
	"fmt"
	"regexp"
)

// Block Grammar
var (
	reHr         = regexp.MustCompile(`^(?:(?:\* *){3,}|(?:_ *){3,}|(?:- *){3,}) *(?:\n+|$)`)
	reHeading    = regexp.MustCompile(`^ *(#{1,6}) +([^\n]+?) *#* *(?:\n|$)`)
	reLHeading   = regexp.MustCompile(`^([^\n]+?) *\n {0,3}(=|-){1,} *(?:\n+|$)`)
	reBlockQuote = regexp.MustCompile(`^( *>[^\n]*(\n[^\n]+)*\n*)+`)
	reDefLink    = regexp.MustCompile(`(?s)^ *\[([^\]]+)\]: *\n? *<?([^\s>]+)>?(?: *\n? *["'(](.+)['")])? *(?:\n+|$)`)
	reSpaceGen   = func(i int) *regexp.Regexp {
		return regexp.MustCompile(fmt.Sprintf(`(?m)^ {1,%d}`, i))
	}
)

var reList = struct {
	item, marker, loose   *regexp.Regexp
	scanLine, scanNewLine func(src string) string
}{
	regexp.MustCompile(`^( *)(?:[*+-]|\d{1,9}\.) (.*)(?:\n|)`),
	regexp.MustCompile(`^ *([*+-]|\d+\.) +`),
	regexp.MustCompile(`(?m)\n\n(.*)`),
	regexp.MustCompile(`^(.*)(?:\n|)`).FindString,
	regexp.MustCompile(`^\n{1,}`).FindString,
}

var reCodeBlock = struct {
	*regexp.Regexp<commit_msg>fix(grammar): commonmark - blockqoute 189<commit_after>package mark

import (
	"fmt"
	"regexp"
)

// Block Grammar
var (
	reHr         = regexp.MustCompile(`^(?:(?:\* *){3,}|(?:_ *){3,}|(?:- *){3,}) *(?:\n+|$)`)
	reHeading    = regexp.MustCompile(`^ *(#{1,6}) +([^\n]+?) *#* *(?:\n|$)`)
	reLHeading   = regexp.MustCompile(`^([^\n]+?) *\n {0,3}(=|-){1,} *(?:\n+|$)`)
	reBlockQuote = regexp.MustCompile(`^ *>[^\n]*(\n[^\n]+)*\n*`)
	reDefLink    = regexp.MustCompile(`(?s)^ *\[([^\]]+)\]: *\n? *<?([^\s>]+)>?(?: *\n? *["'(](.+)['")])? *(?:\n+|$)`)
	reSpaceGen   = func(i int) *regexp.Regexp {
		return regexp.MustCompile(fmt.Sprintf(`(?m)^ {1,%d}`, i))
	}
)

var reList = struct {
	item, marker, loose   *regexp.Regexp
	scanLine, scanNewLine func(src string) string
}{
	regexp.MustCompile(`^( *)(?:[*+-]|\d{1,9}\.) (.*)(?:\n|)`),
	regexp.MustCompile(`^ *([*+-]|\d+\.) +`),
	regexp.MustCompile(`(?m)\n\n(.*)`),
	regexp.MustCompile(`^(.*)(?:\n|)`).FindString,
	regexp.MustCompile(`^\n{1,}`).FindString,
}

var reCodeBlock = struct {
	*regexp.Regexp
{'fraction_non_alphanumeric': 0.36438622028141676, 'fraction_numerical': 0.013100436681222707, 'mean_word_length': 4.455026455026455, 'pattern_counts': {'":': 0, '<': 5, '<?xml version=': 0, '>': 9, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '4168311', 'n_tokens_mistral': 993, 'n_tokens_neox': 936, 'n_words': 132}