diffcore

package
v1.0.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Apr 9, 2025 License: MIT Imports: 2 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func ComputeEditsLCS

func ComputeEditsLCS(a, b []string) []diff.Line

ComputeEditsLCS implements a simple diff algorithm based on longest common subsequence

func LongestCommonSubsequence

func LongestCommonSubsequence(a, b []string) []matchItem

LongestCommonSubsequence finds the longest common subsequence between two string slices using a standard dynamic programming approach. Time complexity: O(len(a) * len(b)) Space complexity: O(len(a) * len(b)) for the DP table.

func SplitLines

func SplitLines(s string) []string

SplitLines splits a string into lines, handling empty strings and trailing newlines

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL