Message287628
I got slightly confused here while playing around.
Python 3.6.0 (default, Jan 31 2017, 11:39:39)
[GCC 4.9.2] on linux
Type "help", "copyright", "credits" or "license" for more information.
>>> class Huacaya:
... f"""Huacaya!"""
...
>>> class Suri:
... f"""{'Suri!'}"""
...
>>> Huacaya.__doc__ is None
False
>>> Suri.__doc__ is None
True
At first I thought f-strings *did* work as docstrings since it worked just fine for the first class. But, the docstring suddenly vanished when putting an actual expression into it. |
|
Date |
User |
Action |
Args |
2017-02-12 00:40:00 | JockeTF | set | recipients:
+ JockeTF, gvanrossum, rhettinger, terry.reedy, eric.smith, ned.deily, docs@python, python-dev, martin.panter, serhiy.storchaka, yselivanov |
2017-02-12 00:40:00 | JockeTF | set | messageid: <1486860000.36.0.0915873277971.issue28739@psf.upfronthosting.co.za> |
2017-02-12 00:40:00 | JockeTF | link | issue28739 messages |
2017-02-12 00:40:00 | JockeTF | create | |
|