Skip to content

Commit 5b80a8b

Browse files
committed
Fix comments too accordingly
1 parent 9564e37 commit 5b80a8b

File tree

1 file changed

+5
-4
lines changed

1 file changed

+5
-4
lines changed

python/pyspark/sql/types.py

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1251,11 +1251,12 @@ def _infer_schema_type(obj, dataType):
12511251

12521252
def _make_type_verifier(dataType, nullable=True, name=None):
12531253
"""
1254-
Verify the type of obj against dataType, raise a TypeError if they do not match.
1254+
Make a verifier that checks the type of obj against dataType and raises a TypeError if they do
1255+
not match.
12551256
1256-
Also verify the value of obj against datatype, raise a ValueError if it's not within the allowed
1257-
range, e.g. using 128 as ByteType will overflow. Note that, Python float is not checked, so it
1258-
will become infinity when cast to Java float if it overflows.
1257+
This verifier also checks the value of obj against datatype and raises a ValueError if it's not
1258+
within the allowed range, e.g. using 128 as ByteType will overflow. Note that, Python float is
1259+
not checked, so it will become infinity when cast to Java float if it overflows.
12591260
12601261
>>> _make_type_verifier(StructType([]))(None)
12611262
>>> _make_type_verifier(StringType())("")

0 commit comments

Comments
 (0)