将地图传递到导入的Golang包中的函数时出错

I need to send a map to a function declared in a imported package, and keep getting this error:

./main.go:21: cannot use m (type map[string]ticket) as type map[string]some_package.ticket in function argument

This is the code of main.go in golang GOPATH folder:

package main

import (    
        "time"
         sp "./some_package"
        )

type ticket struct {
  Timestamp int64
  Identification_number int
}
var m map[string]ticket


func main() {
  humans := 10
  m = make(map[string]ticket)
  m["ticket1"] = ticket{time.Now().Unix(), 1234}
  sp_ := sp.New(humans)
  sp_.SetTicket(m)
}

And this is the code of some_package.go in /some_package in golang GOPATH folder:

package some_package

type park struct{
  card map[string]ticket
  people int
}

type ticket struct {
  Timestamp int64
  Identification_number int
}

func (p *park) SetTicket(m map[string]ticket)(){

}

func New(humans int)(p *park){
  p.card = make(map[string]ticket)
  p.people = humans
  return p
}

How should I pass the value of the map to the imported package function or get the map value inside the function from the parent package? Is this even possible or is there a workaround?

Even though the two types are named the same and contain the same structure, they are not the same type. A type always belongs to a package, and those two types belong to different packages.

So you shouldn't copypaste the type ticket from some_package to main, but instead 1. export it to other packages by naming it in uppercase: type Ticket struct; and 2. use it from main like make(map[string]sp.Ticket).