]> Cypherpunks.ru repositories - gostls13.git/commitdiff
delete forward type declarations
authorRuss Cox <rsc@golang.org>
Wed, 12 Aug 2009 21:40:47 +0000 (14:40 -0700)
committerRuss Cox <rsc@golang.org>
Wed, 12 Aug 2009 21:40:47 +0000 (14:40 -0700)
R=r
DELTA=163  (1 added, 149 deleted, 13 changed)
OCL=33106
CL=33111

13 files changed:
src/pkg/datafmt/datafmt.go
src/pkg/flag/flag.go
src/pkg/go/ast/ast.go
src/pkg/gob/decode.go
src/pkg/gob/encode.go
src/pkg/http/server.go
src/pkg/reflect/type.go
src/pkg/runtime/type.go
src/run.bash
test/fixedbugs/bug066.go
test/interface/fail.go
test/interface/recursive.go
test/ken/rob2.go

index 60dde3bdbcbd563208681100b37cb7e3c59bb0b5..3a0fa08586e47423b379becf0a2a5bdbb57c45b3 100644 (file)
@@ -218,8 +218,6 @@ import (
 // ----------------------------------------------------------------------------
 // Format representation
 
-type State struct
-
 // Custom formatters implement the Formatter function type.
 // A formatter is invoked with the current formatting state, the
 // value to format, and the rule name under which the formatter
index 9927886435724ef2d5ccdf9975f065269abdcb10..b2509e64633d2073f504d4eb385196153e5d5172 100644 (file)
@@ -59,15 +59,6 @@ func atob(str string) (value bool, ok bool) {
        return false, false
 }
 
-type (
-       boolValue struct;
-       intValue struct;
-       int64Value struct;
-       uintValue struct;
-       uint64Value struct;
-       stringValue struct;
-)
-
 // -- Bool Value
 type boolValue struct {
        p *bool;
index 9ab6dc9ce63c483f74dbbab1bdd760ca9b73a1ac..3c7b86818da5b567eb643fd9100c45ac9e38736e 100644 (file)
@@ -36,13 +36,6 @@ import (
 // node sizes a bit.
 
 
-type (
-       ExprVisitor interface;
-       StmtVisitor interface;
-       DeclVisitor interface;
-)
-
-
 // All expression nodes implement the Expr interface.
 type Expr interface {
        // For a (dynamic) node type X, calling Visit with an expression
@@ -101,24 +94,17 @@ type CommentGroup struct {
 // ----------------------------------------------------------------------------
 // Expressions and types
 
-// Support types.
-type (
-       Ident struct;
-       StringLit struct;
-       FuncType struct;
-       BlockStmt struct;
-
-       // A Field represents a Field declaration list in a struct type,
-       // a method in an interface type, or a parameter/result declaration
-       // in a signature.
-       Field struct {
-               Doc *CommentGroup;  // associated documentation; or nil
-               Names []*Ident;  // field/method/parameter names; nil if anonymous field
-               Type Expr;  // field/method/parameter type
-               Tag []*StringLit;  // field tag; or nil
-               Comment *CommentGroup;  // line comments; or nil
-       };
-)
+// A Field represents a Field declaration list in a struct type,
+// a method in an interface type, or a parameter/result declaration
+// in a signature.
+//
+type Field struct {
+       Doc *CommentGroup;  // associated documentation; or nil
+       Names []*Ident;  // field/method/parameter names; nil if anonymous field
+       Type Expr;  // field/method/parameter type
+       Tag []*StringLit;  // field tag; or nil
+       Comment *CommentGroup;  // line comments; or nil
+};
 
 
 // An expression is represented by a tree consisting of one
index ce4bc0b970a9cd9f741a3bbe219070a6a2c55157..2c17aee40c1e262d5ca7d62968bd3112112d0067 100644 (file)
@@ -116,7 +116,6 @@ func decodeInt(state *decodeState) int64 {
        return int64(x >> 1)
 }
 
-type decInstr struct
 type decOp func(i *decInstr, state *decodeState, p unsafe.Pointer);
 
 // The 'instructions' of the decoding machine
index 332c3d6b8d3e813e159656e32266f002423beec2..34e58466d332a69385a465755acd7ddbac720405 100644 (file)
@@ -66,7 +66,6 @@ func encodeInt(state *encoderState, i int64){
        encodeUint(state, uint64(x))
 }
 
-type encInstr struct
 type encOp func(i *encInstr, state *encoderState, p unsafe.Pointer)
 
 // The 'instructions' of the encoding machine
index 47f7d01e7c95e87a37ed53803b5fb890525594bc..4ffdc780be3ee10ba6e6231ef3cf7b64c39f8ac4 100644 (file)
@@ -29,8 +29,6 @@ var (
        ErrHijacked = os.NewError("Conn has been hijacked");
 )
 
-type Conn struct
-
 // Objects implemeting the Handler interface can be
 // registered to serve a particular path or subtree
 // in the HTTP server.
index 4bd2fc1214659a16590ea26f192916063bf1216b..4b9ada0390bd6453b15464d32150647181a46dd8 100644 (file)
@@ -24,8 +24,6 @@ import (
  * copy in order to access the private fields.
  */
 
-type uncommonType struct
-
 type commonType struct {
        size uintptr;
        hash uint32;
index 2a380e21f6c55181cfa0e92d3bbfb93afdba0501..bd3d011a8fd29adf57ddf4e92786e206d605bd6a 100644 (file)
@@ -23,8 +23,6 @@ import "unsafe"
 // so that the compiler can lay out references as data.
 type Type interface { }
 
-type uncommonType struct
-
 // All types begin with a few common fields needed for
 // the interface runtime.
 type commonType struct {
index 0210d9fb919c69ee451f8beb53edcdc75987a574..9ae1ece74277bf36d7f78075d8582ee537cce4e5 100755 (executable)
@@ -16,8 +16,8 @@ maketest() {
        do
                (
                        xcd $i
-               #       make clean
-               #       time make
+                       make clean
+                       time make
                        make install
                        make test
                ) || exit $?
index 4f64152aec01e29ec5b4d627dd0f51fe1b20e9d2..2fa5048f1bfe63904aecbf16070b9e2e30e09664 100644 (file)
@@ -6,11 +6,6 @@
 
 package main
 
-type (
-       Type struct;
-       Object struct;
-)
-
 type Scope struct {
        entries map[string] *Object;
 }
index 1e3758069f5282455e786a7c11ffd64462f19bbd..0e0c4d3ca586f491d1a73174ed8d743bb9695d18 100644 (file)
@@ -8,8 +8,6 @@
 
 package main
 
-type S struct
-
 type I interface {
        Foo()
 }
index 87509838f4c08a2866df5a89ac707fc4e0d50c5d..1eb56e976726e8b6cf243da3af9b293d032932cd 100644 (file)
@@ -8,8 +8,6 @@
 
 package main
 
-type I2 interface
-
 type I1 interface {
        foo() I2
 }
index 5098d939901e2e7d653858947e0bb68ebaa63a63..0e18b3b8a0f07895f0340aba0ba4d5a5048cf7a7 100644 (file)
@@ -9,12 +9,6 @@ package main
 
 const nilchar = 0;
 
-type (
-       Atom struct;
-       List struct;
-       Slist struct;
-)
-
 type Atom struct {
        str             string;
        integer         int;