diff --git a/lib/godoc/package.html b/lib/godoc/package.html
index e0370722110..ab9e521c349 100644
--- a/lib/godoc/package.html
+++ b/lib/godoc/package.html
@@ -3,6 +3,12 @@
Use of this source code is governed by a BSD-style
license that can be found in the LICENSE file.
-->
+
{{with .PDoc}}
{{if $.IsPkg}}
-
+
{{example_html "" $.Examples $.FSet}}
-
Index
+
Index
{{if .Consts}}
- - Constants
+ - Constants
{{end}}
{{if .Vars}}
- - Variables
+ - Variables
{{end}}
{{range .Funcs}}
{{$name_html := html .Name}}
@@ -59,12 +68,12 @@
{{end}}
{{end}}
{{if .Bugs}}
- - Bugs
+ - Bugs
{{end}}
{{if $.Examples}}
-
Examples
+
Examples
{{range $.Examples}}
- {{example_name .Name}}
@@ -84,14 +93,14 @@
{{end}}
{{with .Consts}}
- Constants
+ Constants
{{range .}}
{{node_html .Decl $.FSet}}
{{comment_html .Doc}}
{{end}}
{{end}}
{{with .Vars}}
- Variables
+ Variables
{{range .}}
{{node_html .Decl $.FSet}}
{{comment_html .Doc}}
@@ -147,7 +156,7 @@
{{end}}
{{with .Bugs}}
- Bugs
+ Bugs
{{range .}}
{{comment_html .}}
{{end}}
@@ -159,7 +168,7 @@
{{end}}
{{with .PList}}
- Other packages
+ Other packages
{{/* PList entries are strings - no need for FSet */}}
{{range .}}
@@ -171,7 +180,7 @@
{{with .Dirs}}
{{/* DirList entries are numbers and strings - no need for FSet */}}
{{if $.PDoc}}
-
Subdirectories
+ Subdirectories
{{else}}