"all of its spoil shall you take for yourself": I might think that their spoil should be forbidden; it is, therefore, written "its spoil shall you take for yourself, and you shall eat the spoil of your foes."

(Devarim 20:15) "Thus shall you do to all the cities that are distant": The distant ones (i.e., those not of the seven nations) are subsumed in this law (to spare the women and children), but those that are near (i.e., the seven nations) are not subsumed in this law.