[RFC] constify and func-attribute memory.c and strings.c

Not having `string.c` functions take `const` pointers really makes it annoying to write `const`-aware functions on top of them, which always makes me refrain from mentioning this in code reviews. As a bonus, I added some `FUNC_ATTR_*` stuff.

I used the standard C library convention: Take a `const` pointer, but return a non-`const` one. It's not safe, but the alternative would be to make `const` versions of each function. 
Here I had to check that there's no chance of `signed` to `unsigned` funny business. As an aside, `vim_strnsave` still takes an `int` and that's not good.