This section is empty.
\n") + } else { + fmt.wprintln(w, "")
+ fmt.wprintf(w, "%s :: ", name)
+ tn := base_type(types[e.type])
+ write_type(writer, tn, {.Allow_Indent})
+ fmt.wprintln(w, "")
case .Procedure:
fmt.wprint(w, "")
fmt.wprintf(w, "%s :: ", name)
- write_type(w, files[e.pos.file].pkg, types[e.type], nil)
+ write_type(writer, types[e.type], nil)
where_clauses := array(e.where_clauses)
if len(where_clauses) != 0 {
io.write_string(w, " where ")
@@ -583,8 +726,12 @@ write_pkg :: proc(w: io.Writer, path: string, pkg: ^doc.Pkg) {
print_entities :: proc(w: io.Writer, title: string, entities: []^doc.Entity) {
fmt.wprintf(w, "%s
\n", title)
fmt.wprintln(w, ``)
- for e in entities {
- print_entity(w, e)
+ if len(entities) == 0 {
+ io.write_string(w, "This section is empty.
\n")
+ } else {
+ for e in entities {
+ print_entity(w, e)
+ }
}
fmt.wprintln(w, " ")
}