// requires: firstType is not null // effects: Returns true iff firstType is assignable from secondType internal static bool IsAssignableFrom(EdmType firstType, EdmType secondType) { DebugCheck.NotNull(firstType); if (secondType == null) { return(false); } return(firstType.Equals(secondType) || IsSubtypeOf(secondType, firstType)); }
internal static bool IsAssignableFrom(EdmType firstType, EdmType secondType) { if (secondType == null) { return(false); } if (!firstType.Equals((object)secondType)) { return(Helper.IsSubtypeOf(secondType, firstType)); } return(true); }