In Pee-wee's Big Holiday, we often see someone grab a candy "Root Beer Barrel" and use a tiny straw to drink the Root Beer inside the candy. I've never tried this candy before and when I was researching online I couldn't determine whether you can actually drink from Root Beer Barrels.
Root Beer Barrel candy, as far as I've had in real life, are hard candy. They do not have a liquid center. So no.
Obviously, there may be variations on the candy throughout the country or even world, or specialty/designer/indie/souvenir candy manufacturers who make it as the movie describe. You never know.