design/go2draft-type-parameters: fix cross-reference anchor links

When linking to heading anchors, replace spaces by - in the anchor.

This will lead to the links being shown properly e.g. with the and GitHub Markdown renderers.

Change-Id: Ib32dc08128d0c146e8ce8b2fbea7115357f82cc1
Reviewed-by: Ian Lance Taylor <>
diff --git a/design/ b/design/
index d6ade68..3fda094 100644
--- a/design/
+++ b/design/
@@ -115,7 +115,7 @@
 element type of the slice, here called `T`, is unknown.
 This is a trivial example of the kind of function we want to permit in
 order to support generic programming.
-(Later we'll also discuss [generic types](#Generic types)).
+(Later we'll also discuss [generic types](#Generic-types)).
 // Print prints the elements of a slice.
@@ -163,7 +163,7 @@
 type argument.
 Later we will see how this type argument can usually be deduced from
 the non-type argument, by using [function argument type
-inference](#Function argument type inference).
 For now, we'll pass the type argument explicitly.
 Type arguments are passed much like type parameters are declared: as a
 separate list of arguments.
@@ -754,7 +754,7 @@
 use type inference to avoid having to explicitly write out the type
-Go back to [the example](#Type parameters) of a call to the simple
+Go back to [the example](#Type-parameters) of a call to the simple
 `Print` function:
@@ -2018,7 +2018,7 @@
 ##### Defined composite types
-As [discussed above](#Type parameters in type lists), an extra type
+As [discussed above](#Type-parameters-in-type-lists), an extra type
 parameter is required for a function to take, as an argument, a
 defined type whose underlying type is a composite type, and to return
 the same defined type as a result.
@@ -2053,7 +2053,7 @@
-As [discussed above](#Type parameters in type lists), this can be
+As [discussed above](#Type-parameters-in-type-lists), this can be
 avoided by using an extra type parameter for `Map`, and using
 constraints that describe the required relationship between the slice
 and element types.
@@ -2134,7 +2134,7 @@
 Worse, there is no way to write such a constraint in general.
 In the particular case that both `T1` and `T2` can require some type
 list, then this function can be written as described earlier when
-discussing [type conversions using type lists](#Type conversions).
+discussing [type conversions using type lists](#Type-conversions).
 But, for example, there is no way to write a constraint for the case
 in which `T1` is an interface type and `T2` is a type that implements
 that interface.
@@ -2294,7 +2294,7 @@
 list, a type assertion or type switch would use the actual type
 argument, not the underlying type of the type argument (the difference
 is explained in the section on [identifying the matched predeclared
-type](#Identifying the matched predeclared type)).
 #### Comparison with Java