repo.or.cz
/
mono-project.git
/
blob
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
log
|
graphiclog1
|
graphiclog2
|
commit
|
commitdiff
|
tree
|
refs
|
edit
|
fork
blame
|
history
|
raw
|
HEAD
[Wasm] Fix memory override in mono_wasm_add_assembly
[mono-project.git]
/
mcs
/
tests
/
test-654.cs
blob
7d2a69dabe950e2fa0ee74b249f34c202a5cc75d
1
// Compiler options: -unsafe
2
3
using
System
;
4
5
class
Program
6
{
7
static unsafe public int
Main
()
8
{
9
return
Test
((
sbyte
*) (-
1
));
10
}
11
12
static unsafe int
Test
(
sbyte
*
x
)
13
{
14
if
((
x
+
1
) <
x
) {
15
Console
.
WriteLine
(
"OK"
);
16
return
0
;
17
}
else
{
18
Console
.
WriteLine
(
"BAD"
);
19
return
1
;
20
}
21
}
22
}
23