summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authormilde <milde@929543f6-e4f2-0310-98a6-ba3bd3dd1d04>2023-01-10 08:58:28 +0000
committermilde <milde@929543f6-e4f2-0310-98a6-ba3bd3dd1d04>2023-01-10 08:58:28 +0000
commit8e47f6296b2a24ab76d304ae44fcdba233828a31 (patch)
treedf7264877e7c5cc44b00b7b0f70812b05228f764
parent0eca57d1a63639f000cbf0c65425b0169a62e180 (diff)
downloaddocutils-8e47f6296b2a24ab76d304ae44fcdba233828a31.tar.gz
Policy change: accept literal Unicode characters except for identifiers.
With UTF-8 as default encoding for Python source code and widespread Unicode support in todays editors on all platforms, there is no need to be more restrictive than PEP 8 any more. git-svn-id: https://svn.code.sf.net/p/docutils/code/trunk@9313 929543f6-e4f2-0310-98a6-ba3bd3dd1d04
-rw-r--r--docutils/docs/dev/policies.txt14
1 files changed, 5 insertions, 9 deletions
diff --git a/docutils/docs/dev/policies.txt b/docutils/docs/dev/policies.txt
index f46c143d2..e95c33389 100644
--- a/docutils/docs/dev/policies.txt
+++ b/docutils/docs/dev/policies.txt
@@ -60,13 +60,13 @@ don't be surprised if the "offending" code gets fiddled over time to
conform to these conventions.
The Docutils project shall follow the generic coding conventions as
-specified in the `Style Guide for Python Code`_ and `Docstring
-Conventions`_ PEPs, summarized, clarified, and extended as follows:
+specified in the `Style Guide for Python Code` (:PEP:`8`) and `Docstring
+Conventions` (:PEP:`257`), summarized, clarified, and extended as follows:
* 4 spaces per indentation level. No hard tabs.
-* Use only 7-bit ASCII, no 8-bit strings. See `Docutils
- Internationalization`_.
+* Use UTF-8 encoding (no encoding declaration).
+ Identifiers must use ASCII only.
* No one-liner compound statements (i.e., no ``if x: return``: use two
lines & indentation), except for degenerate class or method
@@ -99,9 +99,6 @@ Conventions`_ PEPs, summarized, clarified, and extended as follows:
* Use 'single quotes' for string literals, and """triple double
quotes""" for docstrings.
-.. _Style Guide for Python Code:
- https://peps.python.org/pep-0008
-.. _Docstring Conventions: https://peps.python.org/pep-0257
.. _Docutils Internationalization: ../howto/i18n.html#python-code
@@ -110,8 +107,7 @@ Documentation Conventions
* Docutils documentation is written using reStructuredText, of course.
-* Use 7-bit ASCII if at all possible, and Unicode substitutions when
- necessary.
+* The encoding of the documentation files is UTF-8.
* Use the following section title adornment styles::