History

fix asm_expr_unary()

keep unary unsigned. problem is exposed on i386 with unary like 0xC0000000. In this case a sign is extended in pe->v = n; if n declared as long.

seyko committed 10 years ago

Commit 3f233ab1 parent f2a4cb01 file · +1 −1Browse files

Unified · Split

tccasm.c+1−1
@@ -42,7 +42,7 @@ static void asm_expr_unary(TCCState *s1, ExprValue *pe) · 41 unmodified lines
42{42{
43 Sym *sym;43 Sym *sym;
44 int op, label;44 int op, label;
45 long n;45 unsigned long n;
46 const char *p;46 const char *p;
47 47
48 switch(tok) {48 switch(tok) {

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