  Gas expulsion is a central concept in some of the models for multiple
populations and the light-element anticorrelations in globular clusters. If the
star formation efficiency was around 30 per cent and the gas expulsion happened
on the crossing timescale, this process could expel preferentially stars born
with the chemical composition of the proto-cluster gas, while stars with
special composition born in the centre would remain bound. Recently, a sample
of extragalactic, gas-free, young massive clusters has been identified that has
the potential to test the conditions for gas expulsion. We compute a large
number of thin shell models, and calculate if the Rayleigh-Taylor instability
is able to disrupt the shell before it reaches the escape speed. We show that
the success of gas expulsion depends on the compactness index of a star cluster
C5, proportionate to stellar mass over half-mass radius. For given C5, a
certain critical, local star formation efficiency is required to remove the
rest of the gas. Common stellar feedback processes may not lead to gas
expulsion with significant loss of stars above C5 = 1. Considering pulsar winds
and hypernovae, the limit increases to C5 = 30. If successful, gas expulsion
generally takes place on the crossing timescale. Some observed young massive
clusters have 1 < C5 < 10 and are gas-free at 10 Myr. This suggests that gas
expulsion does not affect their stellar mass significantly, unless powerful
pulsar winds and hypernovae are common in such objects. By comparison to
observations, we show that C5 is a better predictor for the expression of
multiple populations than stellar mass. The best separation between star
clusters with and without multiple populations is achieved by a stellar
winds-based gas expulsion model, where gas expulsion would occur exclusively in
star clusters without multiple populations.
