File: super_strings.py

package info (click to toggle)
python-libcst 1.8.6-1
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid
  • size: 6,240 kB
  • sloc: python: 78,096; makefile: 15; sh: 2
file content (58 lines) | stat: -rw-r--r-- 1,097 bytes parent folder | download | duplicates (3)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
_ = ""
_ = ''
_ = """"""
_ = ''''''

_ = 'a'   "string" 'that'   r"is" 'concatenated ' 

b"string "
b"and non f" rb'string'

(
    "parenthesized"
    "concatenated"
    """triple
    quoted
    """
    
)

_ = f"string"

f"string" "bonanza" f'starts' r"""here"""

_ = f"something {{**not** an expression}} {but(this._is)} {{and this isn't.}} end"

_(f"ok { expr = !r: aosidjhoi } end")

print(f"{self.ERASE_CURRENT_LINE}{self._human_seconds(elapsed_time)} {percent:.{self.pretty_precision}f}% complete, {self.estimate_completion(elapsed_time, finished, left)} estimated for {left} files to go...")

f"{"\n".join()}"

f"___{
    x
}___"

f"___{(
    x
)}___"

f'\{{\}}'
f"regexp_like(path, '.*\{file_type}$')"
f"\lfoo"

f"{_:{_:}{a}}"

f"foo {f"bar {x}"} baz"
f'some words {a+b:.3f} more words {c+d=} final words'
f"{'':*^{1:{1}}}"
f"{'':*^{1:{1:{1}}}}"
f"{f"{f"{f"{f"{f"{1+1}"}"}"}"}"}"


t'Nothing to see here, move along'
t"User {action}: {amount:.2f} {item}"
t"<p>HTML is code {too}</p>"
t"value={value!r}"
t"This wrinkles my brain {value:.{precision}f}"
_ = t"everything" + t" is {tstrings}"