updated to work with latest PDL changes