Does pasta continue cooking after being drained if left in the pot?
Many people consider the "extra" steps overkill, but the classic method is to boil the pasta to al dente, not fully done, then quench it in cold water as you would with blanched vegetables to stop the cooking process and wash off any excess starch.  Then add the pasta back to sauce or other heating parts for the dish and let it heat back up to temperature.  This gets to the desired temp without over-cooking and much less clumping more easily.  

Using the hot pan, which I have done before, without the quenching will typically result in either not enough heat retained, or some areas over cooked, others allowed to cool, and sticky, starchy pasta all possible to likely.  I have done the finish heating when doing as simple of a "sauce" as a small amount of reserved starch water with salt, pepper and herbs and a touch of olive oil.  Just enough to keep the pasta lubricated and moving in a hot pan as it heats and evenly distributes the spices. You get your warm pasta without it being overcooked or uneven, sticky and clumped.