We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 28bfaf9 commit 510e145Copy full SHA for 510e145
pygmt/clib/conversion.py
@@ -281,7 +281,7 @@ def sequence_to_ctypes_array(
281
return (ctype * size)(*sequence)
282
283
284
-def strings_to_ctypes_array(strings: Sequence[str]) -> ctp.Array:
+def strings_to_ctypes_array(strings: Sequence[str] | np.ndarray) -> ctp.Array:
285
"""
286
Convert a sequence (e.g., a list) of strings into a ctypes array.
287
@@ -307,7 +307,7 @@ def strings_to_ctypes_array(strings: Sequence[str]) -> ctp.Array:
307
return (ctp.c_char_p * len(strings))(*[s.encode() for s in strings])
308
309
310
-def array_to_datetime(array: Sequence[Any]) -> np.ndarray:
+def array_to_datetime(array: Sequence[Any] | np.ndarray) -> np.ndarray:
311
312
Convert a 1-D datetime array from various types into numpy.datetime64.
313
0 commit comments