Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Display Greek small letter mu #14426

Merged
merged 2 commits into from
May 7, 2024
Merged

Display Greek small letter mu #14426

merged 2 commits into from
May 7, 2024

Commits on May 1, 2024

  1. Display Greek small letter mu

    `%time foo()` output is often copied into code comments to explain
    performance improvements. The `\xb5` Latin Extended micro sign and the
    `\u03bc` Greek small letter mu have different codes but often look
    identical.
    
    Output mu to align with:
    
    * [The International System of Units (SI) brochure](
      https://www.bipm.org/documents/20126/41483022/SI-Brochure-9-EN.pdf
      ), such as Table 7 SI prefixes
    * NFKC normalized [Python code](https://peps.python.org/pep-3131/
      ) and [domain names](https://unicode.org/reports/tr36/). For example:
    ```sh
    python -c 'print("""class C:
        \xb5=1
    print(hex(ord(dir(C)[-1])))""")' | tee /dev/fd/2 | python -
    ```
    ```python
    class C:
        µ=1
    print(hex(ord(dir(C)[-1])))
    ```
    `0x3bc`
    * Section 2.5 Duplicated Characters of [Unicode Technical Report 25](
      https://www.unicode.org/reports/tr25/)
    > ...U+03BC μ is the preferred character in a Unicode context.
    * Ruff confusable mapping [updates](
      https://github.com/astral-sh/ruff/pull/4430/files
      ), currently in the "preview" stage
    
    Add a unit test for UTF-8 display and
    https://bugs.launchpad.net/ipython/+bug/348466 ASCII fallback.
    covracer committed May 1, 2024
    Configuration menu
    Copy the full SHA
    aec299d View commit details
    Browse the repository at this point in the history
  2. Darker

    covracer committed May 1, 2024
    Configuration menu
    Copy the full SHA
    6b96eca View commit details
    Browse the repository at this point in the history