]> Cypherpunks repositories - gostls13.git/commitdiff
cmd/gc: delete dead code
authorRuss Cox <rsc@golang.org>
Thu, 7 Jun 2012 06:15:23 +0000 (02:15 -0400)
committerRuss Cox <rsc@golang.org>
Thu, 7 Jun 2012 06:15:23 +0000 (02:15 -0400)
R=ken2
CC=golang-dev
https://golang.org/cl/6307050

src/cmd/gc/dcl.c
src/cmd/gc/go.h

index 4121a45ab209cf7bc8e86572391480290c7fcb34..32f334b710d5dfab367e51a269fe092d24d1c174 100644 (file)
@@ -432,21 +432,6 @@ oldname(Sym *s)
        return n;
 }
 
-/*
- * same for types
- */
-Type*
-newtype(Sym *s)
-{
-       Type *t;
-
-       t = typ(TFORW);
-       t->sym = s;
-       t->type = T;
-       return t;
-}
-
-
 /*
  * := declarations
  */
@@ -1311,7 +1296,7 @@ addmethod(Sym *sf, Type *t, int local)
                }
                // Should have picked off all the reasons above,
                // but just in case, fall back to generic error.
-               yyerror("invalid receiver type %T", pa);
+               yyerror("invalid receiver type %T (%lT / %lT)", pa, pa, t);
                return;
        }
 
index 82fe05be5d571869d419f619e6aba740fd44ac36..6f387c3b0306ed4095475eb68d02c06a969fd04c 100644 (file)
@@ -942,7 +942,6 @@ Node*       methodname(Node *n, Type *t);
 Node*  methodname1(Node *n, Node *t);
 Sym*   methodsym(Sym *nsym, Type *t0, int iface);
 Node*  newname(Sym *s);
-Type*  newtype(Sym *s);
 Node*  oldname(Sym *s);
 void   popdcl(void);
 void   poptodcl(void);