How can FVector pretends as USTRUCT?

I played around more, I am even more confused. I wrote this function inside a blueprint function library:

UFUNCTION(BlueprintPure)
static FVector TestFunction(FVector Vec);

FVector UGameplayAttributesLibrary::TestFunction(FVector Vec) {
	return Vec.Projection();
}

It can take in an FVector. When I call this from Blueprint, it will take in the FVector that is given in NoExportTypes.h. That FVector does not have a Projection method, but Unreal somehow understands we are talking about the C++ Vector and does the conversion. Then I return an FVector, which is the C++ FVector, but it converts back to the blueprint FVector so that I can set it inside blueprint. This is probably what the reflection system is meant to do from the start, I just never saw a class/struct be defined in two different places and used simultaneously. Very interesting.