SemVer.parse constructor
SemVer.parse(
- String version
Parse a version string, throwing if it cannot be parsed.
Implementation
factory SemVer.parse(String version) {
final result = tryParse(version);
if (result == null) {
throw FormatException('Invalid semver: $version');
}
return result;
}