Commit b29ed23a authored by Lucio De Re's avatar Lucio De Re Committed by Russ Cox

build: fix various 'set and not used' for Plan 9

R=dave, minux.ma, rsc
CC=golang-dev
https://golang.org/cl/6501134
parent 54193689
...@@ -147,7 +147,6 @@ regopt(Prog *firstp) ...@@ -147,7 +147,6 @@ regopt(Prog *firstp)
return; return;
} }
r1 = R;
firstr = R; firstr = R;
lastr = R; lastr = R;
......
...@@ -252,6 +252,7 @@ walkclosure(Node *func, NodeList **init) ...@@ -252,6 +252,7 @@ walkclosure(Node *func, NodeList **init)
void void
walkcallclosure(Node *n, NodeList **init) walkcallclosure(Node *n, NodeList **init)
{ {
USED(init);
if (n->op != OCALLFUNC || n->left->op != OCLOSURE) { if (n->op != OCALLFUNC || n->left->op != OCLOSURE) {
dump("walkcallclosure", n); dump("walkcallclosure", n);
fatal("abuse of walkcallclosure"); fatal("abuse of walkcallclosure");
......
...@@ -949,6 +949,7 @@ esctag(EscState *e, Node *func) ...@@ -949,6 +949,7 @@ esctag(EscState *e, Node *func)
Node *savefn; Node *savefn;
NodeList *ll; NodeList *ll;
USED(e);
func->esc = EscFuncTagged; func->esc = EscFuncTagged;
// External functions must be assumed unsafe. // External functions must be assumed unsafe.
......
...@@ -288,7 +288,7 @@ mpatoflt(Mpflt *a, char *as) ...@@ -288,7 +288,7 @@ mpatoflt(Mpflt *a, char *as)
s = as; s = as;
base = -1; base = -1;
while(base == -1) { while(base == -1) {
switch(c = *s++) { switch(*s++) {
case '-': case '-':
case '+': case '+':
break; break;
......
...@@ -471,6 +471,7 @@ typestruct(Type *t) ...@@ -471,6 +471,7 @@ typestruct(Type *t)
// Otherwise it will use a nil type word but still be usable // Otherwise it will use a nil type word but still be usable
// by package runtime (because we always use the memory // by package runtime (because we always use the memory
// after the interface value, not the interface value itself). // after the interface value, not the interface value itself).
USED(t);
return pkglookup("*reflect.commonType", weaktypepkg); return pkglookup("*reflect.commonType", weaktypepkg);
} }
......
...@@ -579,6 +579,7 @@ loaddynlinker(char *file, char *pkg, char *p, int n) ...@@ -579,6 +579,7 @@ loaddynlinker(char *file, char *pkg, char *p, int n)
char *pend, *next, *dynlinker, *p0; char *pend, *next, *dynlinker, *p0;
USED(file); USED(file);
USED(pkg);
pend = p + n; pend = p + n;
for(; p<pend; p=next) { for(; p<pend; p=next) {
next = strchr(p, '\n'); next = strchr(p, '\n');
......
...@@ -356,5 +356,6 @@ static int8 badsignal[] = "runtime: signal received on thread not created by Go. ...@@ -356,5 +356,6 @@ static int8 badsignal[] = "runtime: signal received on thread not created by Go.
void void
runtime·badsignal(int32 sig) runtime·badsignal(int32 sig)
{ {
USED(sig);
runtime·pwrite(2, badsignal, sizeof badsignal - 1, -1LL); runtime·pwrite(2, badsignal, sizeof badsignal - 1, -1LL);
} }
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment