History

Add 103_implicit_memmove testcase

which checks that a declaration after TCC implicitely declares an internally used function (memmove here) doesn't create any problem.

Michael Matz committed 7 years ago

Commit 85483f31 parent c07e81b2 files · +20 −0Browse files

Unified · Split

2 files
  1. tests/tests2/103_implicit_memmove.c +20 −0
  2. tests/tests2/103_implicit_memmove.expect +0 −0
tests/tests2/103_implicit_memmove.c+20−0
@@ -0,0 +1,20 @@
1/* Test that the memmove TCC is emitting for the struct copy
2 and hence implicitely declares can be declared properly also
3 later. */
4struct S { int a,b,c,d, e[1024];};
5int foo (struct S *a, struct S *b)
6{
7 *a = *b;
8 return 0;
9}
10
11void *memmove(void*,void*,long);
12void foo2 (struct S *a, struct S *b)
13{
14 memmove(a, b, sizeof *a);
15}
16
17int main()
18{
19 return 0;
20}
tests/tests2/103_implicit_memmove.expect+0−0

Empty file added.

Keyboard shortcuts

General

Show keyboard shortcuts
?
Focus the current search
/

Issues and pull requests

Open filters
f

Issues, pull requests and Inbox

Select next item
j↓
Select previous item
k↑
Open selected item
Enter
Dismiss filters or clear selection
Esc

Repository code

Go to file
t