Skip to content
Snippets Groups Projects
Commit 983d007f authored by Andreas Klöckner's avatar Andreas Klöckner Committed by Andreas Klöckner
Browse files

Improve deprecation message for force_device_scalars

parent d7810bba
No related branches found
No related tags found
No related merge requests found
...@@ -101,8 +101,11 @@ class PyOpenCLArrayContext(ArrayContext): ...@@ -101,8 +101,11 @@ class PyOpenCLArrayContext(ArrayContext):
to the host. to the host.
""" """
if not force_device_scalars: if not force_device_scalars:
warn("Returning host scalars from the array context is deprecated. " warn("Configuring the PyOpenCLArrayContext to return host scalars "
"To return device scalars set 'force_device_scalars=True'. " "from reductions is deprecated. "
"To configure the PyOpenCLArrayContext to return "
"device scalars, pass 'force_device_scalars=True' to the "
"constructor. "
"Support for returning host scalars will be removed in 2022.", "Support for returning host scalars will be removed in 2022.",
DeprecationWarning, stacklevel=2) DeprecationWarning, stacklevel=2)
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment