Evolution: Even Medieval Castles Evolved!
This is a modified arrowslit or loophole. This embrasure was originally used for archers or crossbowmen to fire arrows or bolts toward incoming threats on the other side of the wall.
Adaptation to New Technologies
The modification you see is the addition of a hole at the bottom of the slit. This hole was designed so the barrel of a hand-held culverin or arquebus could protrude beyond the wall and thus the weapon be fired.
Evolution for Compatibility
An example of evolution and adaptation, making this ancient defensive fort “compatible” with early black powder weapons.
-RBM.