<s> def validate_type_strict ( object_ , object_types ) : <EOL> '''<STR_LIT>''' <EOL> if not isinstance ( object_types , tuple ) : <EOL> object_types = ( object_types , ) <EOL> exact_type_match = any ( [ type ( object_ ) == t for t in object_types ] ) <EOL> if not exact_type_match : <EOL> error_format = '<STR_LIT>' <EOL> message = error_format % ( object_types , type ( object_ ) ) <EOL> raise ValueError ( message ) <EOL> def validate_list_of_strict ( object_list , object_types ) : <EOL> '''<STR_LIT>''' <EOL> for object_ in object_list : <EOL> validate_type_strict ( object_ , object_types ) </s>
