Files

40 lines
799 B
Python
Raw Permalink Normal View History

2020-01-27 10:04:07 -08:00
load("//tools:defs.bzl", "go_library", "go_test")
2021-06-01 17:45:10 -07:00
load("//tools/go_generics:defs.bzl", "go_template", "go_template_instance")
2018-10-23 00:19:11 -07:00
package(
default_applicable_licenses = ["//:license"],
licenses = ["notice"],
)
2018-10-03 13:50:58 -07:00
2021-06-01 17:45:10 -07:00
go_template(
name = "generic_atomicptr",
srcs = ["generic_atomicptr_unsafe.go"],
types = [
"Value",
],
visibility = ["//:sandbox"],
)
2018-10-03 13:50:58 -07:00
go_template_instance(
name = "atomicptr_int",
2019-07-09 16:42:54 -07:00
out = "atomicptr_int_unsafe.go",
2018-10-03 13:50:58 -07:00
package = "atomicptr",
suffix = "Int",
2021-06-01 17:45:10 -07:00
template = ":generic_atomicptr",
2018-10-03 13:50:58 -07:00
types = {
"Value": "int",
},
)
go_library(
name = "atomicptr",
2019-07-09 16:42:54 -07:00
srcs = ["atomicptr_int_unsafe.go"],
2018-10-03 13:50:58 -07:00
)
go_test(
name = "atomicptr_test",
size = "small",
srcs = ["atomicptr_test.go"],
2020-01-27 10:04:07 -08:00
library = ":atomicptr",
2018-10-03 13:50:58 -07:00
)