I'm attaching a patch to fix an edge case of (subword-forward). To reproduce the issue: 1. create a buffer that has an all-caps string such as 'ASDF' at the end of the buffer. There must not be a newline at the end; the 'F' should be the last character 2. Go to the start of the buffer, and do (subword-forward). Observe that the point ends up at the 'F', but it should end up one character ahead of there. To see more clearly that this is wrong, do (subword-downcase 1) instead of (subword-forward). This should make all the characters lowercase, but it misses the last one. This is happening because (subword-forward) is trying to match the character after the start of the new subword, but at the end of the buffer, this character doesn't exist.