From bf6f5d2151cf35dfb82646ffc969a20299e7886d Mon Sep 17 00:00:00 2001 From: Carlos Maddela Date: Thu, 24 Jan 2019 21:04:57 +1100 Subject: [PATCH] Fix some typos. --- DOC/Algorithm | 2 +- ReadMe.c | 2 +- bestmatch.c | 2 +- ccan/hash/hash.c | 6 +++--- ccan/hash/hash.h | 4 ++-- 5 files changed, 8 insertions(+), 8 deletions(-) diff --git a/DOC/Algorithm b/DOC/Algorithm index 515ba07..cb2ec48 100644 --- a/DOC/Algorithm +++ b/DOC/Algorithm @@ -23,7 +23,7 @@ side and build up the full path using linear space and only doubling your work. Wiggle takes a different approach. Finding where the snakes cross -seemed awkward to me, and having two blocks of similiar but not +seemed awkward to me, and having two blocks of similar but not identical code (one to search forward, one to search backwards) didn't appeal at all. diff --git a/ReadMe.c b/ReadMe.c index e76a04b..c559a58 100644 --- a/ReadMe.c +++ b/ReadMe.c @@ -119,7 +119,7 @@ char HelpExtract[] = "\n" char HelpDiff[] = "\n" "wiggle --diff [-wl] [-p12] [-R] file-or-patch [file-or-patch]\n" "\n" -"The diff function will report the differencs and similarities between\n" +"The diff function will report the differences and similarities between\n" "two files in a format similar to 'diff -u'. With --word mode\n" "(the default) word-wise differences are displayed on lines starting\n" "with a '|'. With --line mode, only whole lines are considered\n" diff --git a/bestmatch.c b/bestmatch.c index d1dcacf..eb35592 100644 --- a/bestmatch.c +++ b/bestmatch.c @@ -276,7 +276,7 @@ static void find_best(struct file *a, struct file *b, * in line-mode are interesting) and words that start with * and alphanumeric are interesting. This excludes spaces and * special characters in word mode - * Doing a best-fit comparision on only interesting words is + * Doing a best-fit comparison on only interesting words is * much faster than on all words, and is nearly as good */ diff --git a/ccan/hash/hash.c b/ccan/hash/hash.c index 2659b92..cc58da6 100644 --- a/ccan/hash/hash.c +++ b/ccan/hash/hash.c @@ -9,7 +9,7 @@ if SELF_TEST is defined. You can use this free for any purpose. It's in the public domain. It has no warranty. You probably want to use hashlittle(). hashlittle() and hashbig() -hash byte arrays. hashlittle() is is faster than hashbig() on +hash byte arrays. hashlittle() is faster than hashbig() on little-endian machines. Intel and AMD are little-endian machines. On second thought, you probably want hashlittle2(), which is identical to hashlittle() except it returns two 32-bit hashes for the price of one. @@ -280,7 +280,7 @@ static uint32_t hashlittle( const void *key, size_t length, uint32_t *val2 ) * rest of the string. Every machine with memory protection I've seen * does it on word boundaries, so is OK with this. But VALGRIND will * still catch it and complain. The masking trick does make the hash - * noticably faster for short strings (like English words). + * noticeably faster for short strings (like English words). * * Not on my testing with gcc 4.5 on an intel i5 CPU, at least --RR. */ @@ -457,7 +457,7 @@ static uint32_t hashbig( const void *key, size_t length, uint32_t *val2) * rest of the string. Every machine with memory protection I've seen * does it on word boundaries, so is OK with this. But VALGRIND will * still catch it and complain. The masking trick does make the hash - * noticably faster for short strings (like English words). + * noticeably faster for short strings (like English words). * * Not on my testing with gcc 4.5 on an intel i5 CPU, at least --RR. */ diff --git a/ccan/hash/hash.h b/ccan/hash/hash.h index 0400e6a..5bbef5d 100644 --- a/ccan/hash/hash.h +++ b/ccan/hash/hash.h @@ -34,7 +34,7 @@ * #include * #include * - * // Simple demonstration: idential strings will have the same hash, but + * // Simple demonstration: identical strings will have the same hash, but * // two different strings will probably not. * int main(int argc, char *argv[]) * { @@ -163,7 +163,7 @@ static inline uint32_t hash_string(const char *string) * #include * #include * - * // Simple demonstration: idential strings will have the same hash, but + * // Simple demonstration: identical strings will have the same hash, but * // two different strings will probably not. * int main(int argc, char *argv[]) * { -- 2.39.5