I wonder if something like this would work (assuming parameters are not null):
Pawel
return reference.Equals(definition) || string.Equals(reference.FullName, definition.FullName, StringComparison.InvariantCultureIgnoreCase);
In your code you are missing some cases - e.g. if reference.Version is null but definition.Version is not you would return true which would be not correct (checks for other name parts seem to have the same issue)?Pawel