Yes but 40 is considered standard length of a pregnancy so how many weeks you are determines how far along you are, which is how your Dr is doing her calculations even if you won't be going to 40.
I can't go to 40 weeks I have to have a repeat c section
Different doctors see how many months pregnancy is differently. Just know that it is usually 40 weeks that you will be pregnant not the months.