adding a modicum of type safety