projects
/
cython.git
/ blob
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
history
|
raw
|
HEAD
Remove trailing whitespace.
[cython.git]
/
tests
/
run
/
strfunction.pyx
1
__doc__ = u"""
2
>>> str('test')
3
'test'
4
>>> z
5
'test'
6
"""
7
8
s = str
9
z = str('test')
10
11
def c(string):
12
"""
13
>>> c('testing')
14
'testing'
15
"""
16
return str(string)
17
18
class subs(str):
19
"""
20
>>> subs('testing a subtype')
21
'testing a subtype'
22
23
# >>> csub('testing a subtype')
24
# 'testing a subtype'
25
# >>> csubs('testing a subtype')
26
# 'testing a subtype'
27
"""
28
pass
29
30
def sub(string):
31
"""
32
>>> sub('testing a subtype')
33
'testing a subtype'
34
"""
35
return subs(string)
36
37
#cdef class subs(str):
38
# pass
39
40
#def csub(string):
41
# return csubs(string)