summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorTavian Barnes <tavianator@tavianator.com>2024-07-29 13:33:24 -0400
committerTavian Barnes <tavianator@tavianator.com>2024-08-02 17:18:26 -0400
commite3dd073fb071fe27cfd955e4eca31ff7faf2a18e (patch)
tree3cf15eb33fac1d864d263f58e05b14db1c6b7400
parentc03316834dcef8a3b7ebf489dbbb9409a7990eab (diff)
downloadbfs-e3dd073fb071fe27cfd955e4eca31ff7faf2a18e.tar.xz
Revert "typo: Raise the insert/delete cost"
That was a little too aggressive, with -alse suggesting -size instead of -false. This reverts commit 0d6822ee71c1f60c8003e13ab149501e586f9ae6.
-rw-r--r--src/typo.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/typo.c b/src/typo.c
index cb826fc..b1c5c44 100644
--- a/src/typo.c
+++ b/src/typo.c
@@ -125,7 +125,7 @@ int typo_distance(const char *actual, const char *expected) {
// This is the Wagner-Fischer algorithm for Levenshtein distance, using
// Manhattan distance on the keyboard for individual characters.
- const int insert_cost = (40 + 12 + 1) / 2;
+ const int insert_cost = 12;
size_t rows = strlen(actual) + 1;
size_t cols = strlen(expected) + 1;