The Dow Jones Industrial Average and the S&P 500 both topped all-time highs on Tuesday.

The S&P rose 0.2 percent to break its previous high of 2,484.04, its first record close since July 26. Meanwhile, the 30-stock Dow index rose by 50 points, buoyed by strong gains for Apple and Goldman Sachs.

Chief market strategist at FBN Securities Jeremy Klein told CNBC that Apple's continued success was helping drive the strong earnings. "Apple is just running. I think it's dragging the broader market higher," he said. "You're seeing a bid in yields, which is, in turn, giving financials a boost."

ADVERTISEMENT

Tech stocks have contributed greatly to the stock market this year, rising over 20 percent.

Second-quarter earnings have grown by 10.1 percent, exceeding S&P Capital IQ predicted earnings of 6.2 percent. The Nasdaq composite grew by 0.2 percent.

With the Dow, S&P and Nasdaq all topping record highs over the summer and growing by more than 10 percent, some market experts are concerned about an impending pullback.

"There's sort of a vacuum" in the market currently, Chaikin Analytics CEO Marc Chaikin told CNBC. "We're banging up against resistance and there's a lot of people on vacation. In this type of environment, bad news tends to send the market lower."