nocopy

package
v0.0.0-...-537076f Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jan 18, 2025 License: Apache-2.0 Imports: 0 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type NoCopy

type NoCopy struct{}

NoCopy 结构体中只要引入此类型就会提示no copy错误 代码运行时不会报错 执行 go vet no_copy.go 会提示错误 关键是因为有了 MyType::Lock() 和 MyType::Unlock()方法 noCopy这个名字不重要

func (*NoCopy) Lock

func (*NoCopy) Lock()

func (*NoCopy) Unlock

func (*NoCopy) Unlock()

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL