Skip to main content

Module package

Module package 

Source
Expand description

Newtypes distinguishing package names, version requirement strings, and concrete resolved versions.

PackageName, VersionReq, and ConcreteVersion wrap String to give these kinds of manifest and registry data their own types, so a function that expects one cannot accidentally be called with another. None of these types validate, trim, or normalize their contents: ecosystem-specific normalization (case folding, separator rewriting, etc.) belongs to EcosystemFormatter, not to these types. See each type’s documentation for details.

Structs§

ConcreteVersion
A concrete, resolved version string as returned by a registry.
InvalidPackageName
A package name that failed a PackageNaming::validate_package_name lint.
PackageName
A package/crate name as it appears in a manifest file.
VersionReq
A version requirement string as it appears in a manifest file.