He didn't turn into a book case, but a book case as a sort of representation of multi dimensional space was a part of the movie, yes.
And the infinite book case is a shout out to Borges, right?
It’s the one where Matt Damon gets stuck on another planet.
No not that one.
Not that one either.
New Fermi estimation interview question just dropped: are there more movies where Matt Damon is stuck on a planet, or movies where Tom Hanks plays a captain?
You could ask Daniel Defoe or the cast of Gilligan's Island.
Is the third movie supposed to be Elysium?
Not turned into, he got put into a projection of a higher-dimensional space at the location of his daughter's bookcase some time in the past.