File tree Expand file tree Collapse file tree 2 files changed +1
-10
lines changed Expand file tree Collapse file tree 2 files changed +1
-10
lines changed Original file line number Diff line number Diff line change @@ -39,8 +39,6 @@ def mask_missing(arr, values_to_mask):
3939 # numpy elementwise comparison warning
4040 if is_numeric_v_string_like (arr , x ):
4141 mask = False
42- # elif is_object_dtype(arr):
43- # mask = lib.scalar_compare(arr, x, operator.eq)
4442 else :
4543 mask = arr == x
4644
@@ -53,8 +51,6 @@ def mask_missing(arr, values_to_mask):
5351 # numpy elementwise comparison warning
5452 if is_numeric_v_string_like (arr , x ):
5553 mask |= False
56- # elif is_object_dtype(arr):
57- # mask |= lib.scalar_compare(arr, x, operator.eq)
5854 else :
5955 mask |= arr == x
6056
Original file line number Diff line number Diff line change @@ -350,9 +350,6 @@ def _infer_dtype_from_scalar(val, pandas_dtype=False):
350350 else :
351351 if pandas_dtype :
352352 dtype = DatetimeTZDtype (unit = 'ns' , tz = val .tz )
353- # ToDo: This localization is not needed if
354- # DatetimeTZBlock doesn't localize internal values
355- val = val .tz_localize (None )
356353 else :
357354 # return datetimetz as object
358355 return np .object_ , val
@@ -381,9 +378,7 @@ def _infer_dtype_from_scalar(val, pandas_dtype=False):
381378 dtype = np .complex_
382379
383380 elif pandas_dtype :
384- # to do use util
385- from pandas .tseries .period import Period
386- if isinstance (val , Period ):
381+ if lib .is_period (val ):
387382 dtype = PeriodDtype (freq = val .freq )
388383 val = val .ordinal
389384
You can’t perform that action at this time.
0 commit comments