needs tests for dereference