mirror of https://github.com/golang/go.git
build: fix various 'set and not used' for Plan 9
R=dave, minux.ma, rsc CC=golang-dev https://golang.org/cl/6501134
This commit is contained in:
parent
54193689cc
commit
b29ed23ab5
|
|
@ -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)
|
||||||
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)
|
||||||
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)
|
||||||
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)
|
||||||
// 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)
|
||||||
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.
|
||||||
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);
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue