Keep in mind the number of variables here, even assuming the two foes are melee range apart.
Real life:
Like if I have my bow strung, in hand, no arrow out, you have a sword at your waist, we go for it, good odds you'll draw and skewer me.
If you have your sword out, and I have an arrow out, but not pulled, odds still are that you'd skewer me, as the action of the draw takes about as much time as a swing, if not less.
My opinion:
You can choose to shoot someone in melee.
You either get zero parry, or if the GM allows it, some significantly reduced parry (like 2:1 reduction)
If you parry, the GM should make break factor or breakage checks, as missile weapons are not meant to be used for parry.
Much like firing on someone from 50' off, it's a very offensive action, with poor defense. . . you better hope you get initiative, and you better hope your shot takes down anyone aiming to go to school on you with a melee weapon. (Anyone making a melee attack who doesn't declare 100% OB melee vs a foe in melee range with a bow in his hands is likely being way overcautious).
I can indeed get the logic of how a sling is not going to work in a press of people, but it won't work on someone 50' off if you're hemmed in at launch point. . .no reason you couldn't use a sling on someone 5' away assuming you have the clear space around you for it, though if they have half a brain they'll foul your wind up (though the rules are kind of sketchy on how you'd do that)
As a GM I'd allow it, it's just very, very risky. . .and I allow my players to take as much rope as they want to hang themselves. . .it's also possible to fire a bow while dangling upside down from a rope tied around your ankle, but I wouldn't suggest making "Archer Pinata!" a standard go-to plan.