A logical characterization of systolic languages