feat(lua/name): add hash method to name objects

Signed-off-by: Leonardo de Moura <leonardo@microsoft.com>
fix(util/memory): make sure realloc behaves like free when sz == 0

Signed-off-by: Leonardo de Moura <leonardo@microsoft.com>
fix(util/memory): make sure realloc behaves like free when sz == 0