Offensive foul: why doesn't the basket count?

The FIBA Interpretations contain example 33-2:

Example: A1 is in the air on the shot for a 3-point field goal. A1 extends his leg which contacts his defensive player B1.

The interpretation is as follows:

Interpretation: This is a foul by A1 for moving his leg outside the boundaries of his cylinder and contacting his defensive player B1.

Suppose the contact between the leg of A1 and the body of B1 occurs after the ball leaves the hand of A1 for the shot.

Let's further suppose that the ball enters the basket.

The interpretations don't say whether it counts or not.

Let's look at the rules.

Rule 16.1.1 says that:

A goal is made when a live ball enters the basket from above and remains within or passes through the basket entirely.

So the question becomes: was the ball live when it entered the basket?

Let's apply Rule 10.4:

The ball does not become dead and the goal counts if made when:

• The ball is in flight on a shot for a field goal and:
• A referee blows his whistle.

In this case, when the contact occurred, the ball was in flight on a shot for a field goal.

Then a referee blew his whistle (for the offensive foul).

Then it looks like "The ball does not become dead and the goal counts".

So it seems like the goal counts?

(I know the goal doesn't count, but I would like to know why, where it is written, and how the fact the the goal doesn't count squares with rule 10.4 and the concept of live and dead ball)

I also accept answers according to the NBA rules, for completeness, although this question is specifically focused on FIBA rules.

For NBA rules, this is trivial to answer. From the rulebook:

Section VII—Offensive Fouls

A personal foul assessed against an offensive player which is neither punching or flagrant shall be penalized in the following manner:

1. No points can be scored by the offensive team
2. The offending player is charged with a personal foul
3. The offending team is not charged with a team foul

EXCEPTION: Rule 3—Section I—a. No penalty free throws are awarded. 4. The ball is awarded to the offended team out-of-bounds on the sideline at the nearest spot where play was interrupted but no nearer the baseline than the free throw line

If the offensive player commits a penalty, no points can be scored, explicitly.

FIBA's rules are not clear on this in my mind, but I have never considered FIBA's rules to be clear on much of anything, despite their detail, so that doesn't surprise me.