cmd: Remove comments about using the string module.

Even though we now have a `string` module, just keep the existing
IDENTCHARS definition.

- If someone doesn't already have string installed (or aren't otherwise
  importing it), this would add an extra dependency and more memory used.

- If they do, then the resulting concatenated string has to be allocated
  separately, so there's no gain from using the string.x components.

Signed-off-by: Jim Mussared <jim.mussared@gmail.com>
pull/411/head
Jim Mussared 2023-07-21 15:26:16 +10:00
rodzic 0a5b635594
commit fe3e0a2fae
1 zmienionych plików z 2 dodań i 3 usunięć

Wyświetl plik

@ -51,13 +51,12 @@ this means that that help by doc string feature doesn't work.
completions have also been stripped out.
"""
# import string, sys
import sys # MiroPython doesn't yet have a string module
import sys
__all__ = ["Cmd"]
PROMPT = "(Cmd) "
# IDENTCHARS = string.ascii_letters + string.digits + '_'
# This is equivalent to string.ascii_letters + string.digits + '_'
IDENTCHARS = "abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789_"