Symbolism, Imagery, Allegory
One of the most enduring images of pirates we have is that they carry parrots. Maybe it's the name: parrot, pirate; pirate, parrot. And maybe it's that parrots symbolize trips to distant climes and strange lands. (You definitely don't find many parrots native to England.) But the real role of this particular parrot, Captain Flint, is to allow Long John Silver to meditate on good and evil.
Long John Silver isn't just a pirate; he is a pirate-philosopher. He points out that Captain Flint the parrot is completely innocent (after all, it's a parrot; how evil can it be?). Still, she swears a blue streak. The problem with poor Captain Flint is that she's been tainted by her upbringing and associates. It would appear that one of the moral lessons of the novel is that the only way to stay morally pure in this world is to stay out of dangerous situations in the first place. Be that as it may, if we all did our best to avoid any appearance of impropriety, we would never get to go on treasure hunts. So there's a subtle conflict in the novel between what's ethical and what's fun. After all, we're reading Treasure Island precisely because everyone in it is at least a little morally ambiguous. (For more on moral ambiguity in the novel, check out our section, "What's Up With the Ending?")