FFI: Fix __index/__newindex metamethod resolution for ctypes.