Although this is messy, I think this is code compliant.
My code reference would be NEC 2014, section 312.8 but would have to comply with 312.8 (1 thru 3)
312.8 (NEC 2014)
The wiring space of enclosures for switches or overcurrent
devices shall be permitted for conductors feeding through,
spliced, or tapping off to other enclosures, switches, or overcurrent
devices where all of the following conditions are met:
(1) The total of all conductors installed at any cross section of
the wiring space does not exceed 40 percent of the crosssectional
area of that space.
(2) The total area of all conductors, splices, and taps installed
at any cross section of the wiring space does not exceed
75 percent of the cross-sectional area of that space.
(3) A warning label complying with 110.21(B) is applied to the
enclosure that identifies the closest disconnecting means
for any feed-through conductors.