addStdSliceMaps adds std Slice and Map types to universe
()
| 22 | |
| 23 | // addStdSliceMaps adds std Slice and Map types to universe |
| 24 | func addStdSliceMaps() { |
| 25 | makeGoPackage() |
| 26 | gopk := goPackage.pkg |
| 27 | sltyps := []string{"int", "int64", "int32", "int16", "int8", "uint", "uint64", "uint32", "uint16", "uint8", "bool", "byte", "rune", "float64", "float32", "string", "error"} |
| 28 | for _, tn := range sltyps { |
| 29 | universe.addSliceType(gopk, nil, types.NewSlice(universe.sym(tn).gotyp), skType, "Slice_"+tn, "[]"+tn) |
| 30 | } |
| 31 | } |
| 32 | |
| 33 | // stdBasicTypes returns the basic int, float etc types as symbols |
| 34 | func stdBasicTypes() map[string]*symbol { |
no test coverage detected