You likely hit the DWV (drain waste vent) stack. This is the drain plumbing for the bathroom and is commonly black ABS plastic.
This pipe is typically empty except when waste is moving though it. Depending on the size of hole, you may find small water spots that gradually get larger or notice a sewer gas odor in that room or nearby rooms.
It is not too hard to apply a patch material to the puncture to fix, but you'd need to cut a good size hole in the drywall to access it. The other option would be to enlarge the hole enough to get the tip of a caulking gun in to fill the hole and then patch the drywall.