Module utils

Module utils 

Source

Structs§

InvalidTranslationTemplateSyntaxError

Functions§

are_function_signatures_equals
Returns true if the function signature of func_a and func_b are equals
combine_arguments_without_argument_separators
Returns a new Vec where all Argument separator values in arguments_list are stripped.
combine_data_objects
This functions combines a list of DataObjectRefs into a single DataObjectRef
compare_versions_components
Returns the order of version_a and version_b
compare_versions_str
Returns the order of version_a and version_b or None if at least one version is invalid
format_translation_template
Returns a formatted template translation
format_translation_template_pluralization
Return a formatted translation with the correct pluralization
format_translation_template_pluralization_with_template
Returns a formatted translation with the correct pluralization and additional template values (the count template value will be overridden)
get_most_restrictive_function
Returns the most restrictive function for the provided arguments or None if no function signature matches the arguments
get_most_restrictive_function_index
Returns the overloaded function index of the most restrictive function for the provided arguments or None if no function signature matches the arguments
get_most_restrictive_function_signature_index
Returns the index of the most restrictive function for the provided arguments or None if no function signature matches the arguments
get_version_components
Returns the version as a tuple or None if the version is invalid
is_callable
Returns true if the call operator is defined for the provided DataObjectRef else false
is_member_access_allowed
Returns true if the member access operator is defined for the provided DataObjectRef else false
none_to_lang_void
This function converts an OptionDataObjectRef to a DataObjectRef
separate_arguments_with_argument_separators
Returns a new Vec where all arguments are separated with Argument separator values.
wrap_index
Converts negative indices to positive indices (e.g. -1 => len - 1 => last element)
wrap_index_allow_len
Converts negative indices to positive indices (e.g. -1 => len - 1 => last element)