On reciprocating compressors designed for gas (I'll explain that one some day), the liquid cannot pass through the valves in sufficient quanity or rate and vertially no gas will enter too. As the piston reverses and starts the compression stroke the liquid will again not pass through the valves quickly and will stay in the cylinder filling up the volume of the cylinder that has clearance between the piston and end of the cylinder. After 1 or two stokes, there will be enough liquid that when the piston is nearing the end of the stroke the cylinder will be full of liquid AND because liquids do not compress the liquids will be just like a solid plug the the piston will push on. The piston will push on the liquid until something just breaks. The piston rod, the pin, the crank, the valves, the bolts holding the cylinder together, one of those items will fail.
What also happens is a liquid may enter the suction valve and because the valve is hot from the heat of compression, that liquid may vaporize (boil). The violent vaporization and localized cooling on the valve material can cause fatique in spots and the valve or parts of the valve will fail (typically the valve plates). All in all a recip can have a very very small drop of liquids.
If uou look at a reciprocating compressor and pump, there is no basic difference, suction valve, piston with sealing rings, back and forth, discharge valve, whats the difference. If you try to put liquids through a gas unit, it will fail. Put gas through a liquid unit, not a mechanical failure, it will just stop moving any thing. The diffence is in the valves and the area available to pass the fluid and open/close with the fluid.
The same is true for centifugals. Nothings really different except clearance areas. My favorite site had 3 3000 HP IR HHE compressors working in parallel on the same fluid as an 1000 HP Bingham splitcase pump I loved it.