Yes, but I think what OP also needs to take into account is the fact that, while dwarf civs have reasonable overall populations, forts have around 200 dwarves, and that's if they are very prosperous. This means that the focus is on _very_ small groups (120 soldiers, constituting much more than half my fort population, is still tiny in global terms) of extremely elite fighters, who, in this game at least, are capable of smashing aside entire armies until they find someone of equal skill. Even when in the open and being fired at by 20+ elven/goblin/human bowmen or crossbowmen, the typical dwarven champion will doge, leap, block, and even bat the bolts out of the very air to close into melee.
On top of this, forts seem to have a lot of autonomy - hell, they currently don't even have to pay taxes back to the mountainhome, and can ignore the trade agreements if they want to. So it's reasonable to assume that individual units will pursue differing objectives depending on their home fort's orders, while still fitting under the overarching strategy of the dwarven general, but I guess that's a grand strategy issue.
I think that the square should be given a core of weaponlords/specialised melee fighters to respond to charges, and to deal with the eventuality of the entire enemy army just marching up to the formation with shields raised - sure, handaxes and small warhammers do the trick, but there really is nothing for morale like seeing your the men rank in front of you get split into small pieces by gigantic axes.
I know the original Spanish square eventually got rid of the melee core but the setting is slightly different - there simply aren't enough dwarves in a fighting unit (one fortress-worth of soldiers) to ensure that they won't get flanked, and when they do, having some specialised melee fighters to throw in the direction of the trouble would drastically increase the formation's survivability and potential for goblin murder.