This will make your garbage disposal a super safe dream.
Dig a 3x1 trench. Place a 1x1 raising bridge in the one end of the bottom of the trench. Next, up on the level above, place a minecart stop set to dump into the trench on he same end as h bridge (b-C-S, then tap d until the direction is right). Build walls around the stop and the hole it dumps into above the bridge. Leave a 1 tile gap in the wall. In this gap place a pressure plate set to go off whenever a citizen of any weight steps on it. Connect the pressure plate to the bridge, place a wall next to the bridge in the trench. Now, finally, go to (h)auling, create a new route (can't remember the key), and create a new (s)top with the cursor on top of the track stop. Then press enter, enable the items that you want pulverised in the stockpile list that pops up, create a stockpile for those items near the trash compactor, and set a new (s)tockpile link back in the stop's menu. At the same time, delete all the departure conditions. If you followed that,you'll end up with
z0 z-1
+++++ OOOOO O - wall
+OpO+ OOOOO + - floor/stockpile
+OsO+ OOOOO p - pressure plate
+O.O+ OObOO s - track stop
+OOO+ OOOOO b - bridge
++▼++ OO▲OO ▲ - up ramp
+++++ OOOOO ▼ - down ramp
This, a compact trash compactor.
EDIT: this is naturally only for enemy dead, livestock, wildlife--that sort of thing. Your own dead dwarves should go in an underground, well secured vault, inside coffins.