/
githubmirror
/
go
Обзор
Документация
Войти
/
githubmirror
/
go
Код
Запросы
0
Пакеты
0
Релизы
0
Аналитика
Безопасность
master
test/fixedbugs/issue44830.go
19 строк
372 B
Cuong Manh Le
cmd/compile: fix wrong package path for unsafe.Pointer
27 апр 2021, 04:16
27 апр 2021, 04:16
40254ec
Код
Авторство
О чём код?
// run // Copyright 2021 The Go Authors. All rights reserved. // Use of this source code is governed by a BSD-style // license that can be found in the LICENSE file. package main import ( "reflect" "unsafe" ) func main() { t := reflect.TypeOf(unsafe.Pointer(nil)) if pkgPath := t.PkgPath(); pkgPath != "unsafe" { panic("unexpected t.PkgPath(): " + pkgPath) } }