Documentation
      ¶
    
    
  
    
  
    Overview ¶
Helper functions for doing value conversions.
Index ¶
- func AsString(x starlark.Value) (string, bool)
 - func AsStringOrStringList(x starlark.Value) ([]string, bool)
 - func SequenceToStringSlice(seq starlark.Sequence) ([]string, error)
 - func StringSliceToList(slice []string) *starlark.List
 - func ValueOrSequenceToSlice(v starlark.Value) []starlark.Value
 - func ValueToAbsPath(thread *starlark.Thread, v starlark.Value) (string, error)
 - func ValueToStringMap(v starlark.Value) (map[string]string, error)
 - type ImplicitStringer
 - type PathMaker
 
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func AsStringOrStringList ¶ added in v0.10.18
Unpack an argument that can either be expressed as a string or as a list of strings.
func SequenceToStringSlice ¶ added in v0.10.15
func StringSliceToList ¶ added in v0.10.22
func ValueOrSequenceToSlice ¶
If `v` is a `starlark.Sequence`, return a slice of its elements Otherwise, return it as a single-element slice For functions that take `Union[List[T], T]`
func ValueToAbsPath ¶ added in v0.10.15
Types ¶
type ImplicitStringer ¶ added in v0.10.18
type ImplicitStringer interface {
	ImplicitString() string
}
     Click to show internal directories. 
   Click to hide internal directories.