(ps map[string]*package_file_cache)
| 442 | } |
| 443 | |
| 444 | func update_packages(ps map[string]*package_file_cache) { |
| 445 | // initiate package cache update |
| 446 | done := make(chan bool) |
| 447 | for _, p := range ps { |
| 448 | go func(p *package_file_cache) { |
| 449 | defer func() { |
| 450 | if err := recover(); err != nil { |
| 451 | print_backtrace(err) |
| 452 | done <- false |
| 453 | } |
| 454 | }() |
| 455 | p.update_cache() |
| 456 | done <- true |
| 457 | }(p) |
| 458 | } |
| 459 | |
| 460 | // wait for its completion |
| 461 | for _ = range ps { |
| 462 | if !<-done { |
| 463 | panic("One of the package cache updaters panicked") |
| 464 | } |
| 465 | } |
| 466 | } |
| 467 | |
| 468 | func collect_type_alias_methods(d *decl) map[string]*decl { |
| 469 | if d == nil || d.is_visited() || !d.is_alias() { |
no test coverage detected