diff options
Diffstat (limited to 'doc/data/messages/u/unnecessary-lambda')
-rw-r--r-- | doc/data/messages/u/unnecessary-lambda/bad.py | 5 | ||||
-rw-r--r-- | doc/data/messages/u/unnecessary-lambda/details.rst | 1 | ||||
-rw-r--r-- | doc/data/messages/u/unnecessary-lambda/good.py | 4 |
3 files changed, 8 insertions, 2 deletions
diff --git a/doc/data/messages/u/unnecessary-lambda/bad.py b/doc/data/messages/u/unnecessary-lambda/bad.py new file mode 100644 index 000000000..ddf84f7fa --- /dev/null +++ b/doc/data/messages/u/unnecessary-lambda/bad.py @@ -0,0 +1,5 @@ +function = lambda x: print(x) # [unnecessary-lambda] + +function("Hello world !") + +df.apply(lambda x: str(x)) # [unnecessary-lambda] diff --git a/doc/data/messages/u/unnecessary-lambda/details.rst b/doc/data/messages/u/unnecessary-lambda/details.rst deleted file mode 100644 index ab8204529..000000000 --- a/doc/data/messages/u/unnecessary-lambda/details.rst +++ /dev/null @@ -1 +0,0 @@ -You can help us make the doc better `by contributing <https://github.com/PyCQA/pylint/issues/5953>`_ ! diff --git a/doc/data/messages/u/unnecessary-lambda/good.py b/doc/data/messages/u/unnecessary-lambda/good.py index c40beb573..9f0678f02 100644 --- a/doc/data/messages/u/unnecessary-lambda/good.py +++ b/doc/data/messages/u/unnecessary-lambda/good.py @@ -1 +1,3 @@ -# This is a placeholder for correct code for this message. +print("Hello world !") + +df.apply(str) |