improved ddquote, added tests