bpo-44063: set the missing end locations on the compiler (GH-25956) (#25972) (cherry picked from commit b2ec37a7224318d466e0877790ed740ce8b4867d) Co-authored-by: Batuhan Taskaya <isidentical@gmail.com>