You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
34 lines
466 B
34 lines
466 B
package a
|
|
|
|
import (
|
|
"unsafe"
|
|
)
|
|
|
|
type Collection struct {
|
|
root unsafe.Pointer
|
|
}
|
|
|
|
type nodeLoc struct{}
|
|
|
|
type slice []int
|
|
|
|
type maptype map[int]int
|
|
|
|
func MakePrivateCollection() *Collection {
|
|
return &Collection{
|
|
root: unsafe.Pointer(&nodeLoc{}),
|
|
}
|
|
}
|
|
|
|
func MakePrivateCollection2() *Collection {
|
|
return &Collection{
|
|
root: unsafe.Pointer(&slice{}),
|
|
}
|
|
}
|
|
func MakePrivateCollection3() *Collection {
|
|
return &Collection{
|
|
root: unsafe.Pointer(&maptype{}),
|
|
}
|
|
}
|
|
|