What happened

Shares of Endo International plc (NASDAQ:ENDP), a pharmaceutical company selling branded and generic drugs, have gained about 16.4% as of 12:08 p.m. EDT during Tuesday's session. It's been a tough couple years for the stock, but Tuesday's earnings report contained what appears to be light at the end of a very dark tunnel.

So what

Although first-quarter sales of established products slid 32% lower than the same period last year, growth in the generic segment offset the losses. In particular, recently launched generics surged 198% to $334 million pushing total revenue for the first quarter 8% higher than the previous year period.

Pills stacked in the shape of an upward sloping chart on a pile of money.

Image source: Getty Images.

Investors are especially pleased to see Endo International successfully execute its generic growth strategy in light of potentially heavy losses to Opana ER revenue. In March, a majority of FDA advisory panel members agreed the popular painkiller's risks no longer outweigh its benefits. The Agency could have the drug pulled from the U.S. market, or require physicians to complete a risk mitigation program before continuing to prescribe the addictive painkiller. Either way, it looks like further losses ahead for Opana ER.

Now what

The good news is that Opana ER sales accounted for just 3.4% of Endo's total first-quarter revenue. Although this year's total revenue forecast of between $3.45 billion and $3.60 billion is a step down from $4.01 billion recorded last year, it looks like the top line has a chance to return to growth in the next couple years.

Management now expects to record between $3.45 to $3.75 per share in adjusted earnings from continuing operations. After a terrible stock price performance in 2016, Endo shares are trading at just 3.6 times the lower end of this year's adjusted earnings estimate. If the company can pull off a modest return to bottom-line growth, or simply tread water, investors scooping shares out of the bargain bin at recent prices could be in for market-thumping long-term gains.

This article represents the opinion of the writer, who may disagree with the “official” recommendation position of a Motley Fool premium advisory service. We’re motley! Questioning an investing thesis -- even one of our own -- helps us all think critically about investing and make decisions that help us become smarter, happier, and richer.