mirror of
https://github.com/zyedidia/micro.git
synced 2026-02-04 22:20:20 +09:00
highlighter: Remove EmptyDef since it's superseeded by a nil check of SyntaxDef
This commit is contained in:
@@ -908,8 +908,6 @@ func (b *Buffer) UpdateRules() {
|
||||
if b.SyntaxDef != nil {
|
||||
b.Settings["filetype"] = b.SyntaxDef.FileType
|
||||
}
|
||||
} else {
|
||||
b.SyntaxDef = &highlight.EmptyDef
|
||||
}
|
||||
|
||||
if b.SyntaxDef != nil {
|
||||
|
||||
@@ -67,9 +67,6 @@ func combineLineMatch(src, dst LineMatch) LineMatch {
|
||||
// A State represents the region at the end of a line
|
||||
type State *region
|
||||
|
||||
// EmptyDef is an empty definition.
|
||||
var EmptyDef = Def{nil, &rules{}}
|
||||
|
||||
// LineStates is an interface for a buffer-like object which can also store the states and matches for every line
|
||||
type LineStates interface {
|
||||
LineBytes(n int) []byte
|
||||
|
||||
Reference in New Issue
Block a user