Help us shape the future of Go! Take the 2026 Go Developer Survey

ptr

package
v0.70.0 Latest Latest
Warning

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

Go to latest
Published: Oct 31, 2024 License: Apache-2.0 Imports: 4 Imported by: 0

Documentation

Overview

Package ptr provides utilities for pointer operations using storage layer paths.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Ptr

func Ptr(data interface{}, path storage.Path) (interface{}, error)

func ValidateASTArrayIndex added in v0.70.0

func ValidateASTArrayIndex(arr *ast.Array, s string, path storage.Path) (int, error)

func ValidateArrayIndex

func ValidateArrayIndex(arr []interface{}, s string, path storage.Path) (int, error)

func ValidateArrayIndexForWrite added in v0.39.0

func ValidateArrayIndexForWrite(arr []interface{}, s string, i int, path storage.Path) (int, error)

ValidateArrayIndexForWrite also checks that `s` is a valid way to address an array element like `ValidateArrayIndex`, but returns a `resource_conflict` error if it is not.

func ValuePtr added in v0.70.0

func ValuePtr(data ast.Value, path storage.Path) (ast.Value, error)

Types

This section is empty.

Jump to

Keyboard shortcuts

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