repo.or.cz
/
llvm-project.git
/
blob
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
log
|
graphiclog1
|
graphiclog2
|
commit
|
commitdiff
|
tree
|
refs
|
edit
|
fork
blame
|
history
|
raw
|
HEAD
[clang-format] Fix a bug in aligning comments above PPDirective (#72791)
[llvm-project.git]
/
clang
/
utils
/
TestUtils
/
deep-stack.py
blob
4cf5789abdb12b7ae46bb9ddca6bb50a0c7b643a
1
#!/usr/bin/env python
2
3
from
__future__
import
absolute_import
,
division
,
print_function
4
5
6
def
pcall
(
f
,
N
):
7
if
N
==
0
:
8
print
(
" f(0)"
,
file
=
f
)
9
return
10
11
print
(
" f("
,
file
=
f
)
12
pcall
(
f
,
N
-
1
)
13
print
(
" )"
,
file
=
f
)
14
15
16
def
main
():
17
f
=
open
(
"t.c"
,
"w"
)
18
print
(
"int f(int n) { return n; }"
,
file
=
f
)
19
print
(
"int t() {"
,
file
=
f
)
20
print
(
" return"
,
file
=
f
)
21
pcall
(
f
,
10000
)
22
print
(
" ;"
,
file
=
f
)
23
print
(
"}"
,
file
=
f
)
24
25
26
if
__name__
==
"__main__"
:
27
import
sys
28
29
sys
.
setrecursionlimit
(
100000
)
30
main
()