Skip to content

Commit 8fad317

Browse files
author
MarcoGorelli
committed
doctests
1 parent ad969e3 commit 8fad317

File tree

1 file changed

+3
-5
lines changed

1 file changed

+3
-5
lines changed

pandas/core/tools/datetimes.py

+3-5
Original file line numberDiff line numberDiff line change
@@ -939,14 +939,12 @@ def to_datetime(
939939
Index([2020-10-25 02:00:00+02:00, 2020-10-25 04:00:00+01:00],
940940
dtype='object')
941941
942-
- A mix of timezone-aware and timezone-naive inputs is converted to
943-
a timezone-aware :class:`DatetimeIndex` if the offsets of the timezone-aware
944-
are constant:
942+
- A mix of timezone-aware and timezone-naive inputs is also converted to
943+
a simple :class:`Index` containing :class:`datetime.datetime` objects:
945944
946945
>>> from datetime import datetime
947946
>>> pd.to_datetime(["2020-01-01 01:00:00-01:00", datetime(2020, 1, 1, 3, 0)])
948-
DatetimeIndex(['2020-01-01 01:00:00-01:00', '2020-01-01 02:00:00-01:00'],
949-
dtype='datetime64[ns, UTC-01:00]', freq=None)
947+
Index([2020-01-01 01:00:00-01:00, 2020-01-01 03:00:00], dtype='object')
950948
951949
|
952950

0 commit comments

Comments
 (0)