p46 and 47 impls and tests