NEW YORK (TheStreet) -- Shares of Caterpillar (CAT) were soaring by 7.35% to $90.88 in early afternoon trading on Wednesday, after Republican candidate and U.S. infrastructure supporter Donald Trump beat out Democratic candidate Hillary Clinton in the U.S. presidential election on Tuesday. 

The construction equipment maker is benefiting from the anticipation that Trump will put funds toward U.S. infrastructure, TheStreet's Jim Cramer said on CNBC's "Squawk on the Street" this morning. Trump said he wants to spend $1 trillion on infrastructure.

Caterpillar recently said "China's better, U.S. is not good" so this infrastructure spend could make a "great situation" for the company, Cramer said. 

However, when trade wars begin and Europe takes a hit, people will be asking, "Why did I buy a machinery company in an atmosphere of Smoot-Hawley and tariffs?" Cramer pointed out. The Smoot-Hawley Tariff Act of 1930 increased import duties by as much as 50% to help protect U.S. farmers, but also inspired other countries to increase their own tariffs. 

It's "insanity" to buy Caterpillar at these levels because President Obama is still in office, so the infrastructure plans aren't happening tomorrow, he pointed out. However, a number of investors were short on this stock because it was a way "to play" the expected Clinton victory, which would have represented "business as usual."

Another example is United Rentals (URI), which is soaring by 14.23% to $86.67 this afternoon because infrastructure plans will require tractor rentals, Cramer said. While "I can make a case over the course of the next five months" that the stock will go up a lot, "I fear" that later this week when we're not talking as "granularly" about this, investors will wonder why they bought this stock. 

"I'm just trying to caution people if you buy something up 6%, there's going to be profit taking later in the afternoon by someone who's owned that dog [who's] going to say, 'Holy cow! Out of the kennel,'" Cramer said.  

Separately, TheStreet Ratings objectively rated this stock according to its "risk-adjusted" total return prospect over a 12-month investment horizon. Not based on the news in any given day, the rating may differ from Jim Cramer's view or that of this articles's author.

TheStreet Ratings team rates Caterpillar as a Hold with a ratings score of C. The primary factors that have impacted the team's rating are mixed - some indicating strength, some showing weaknesses, with little evidence to justify the expectation of either a positive or negative performance for this stock relative to most other stocks.

You can view the full analysis from the report here: CAT

CAT Chart CAT data by YCharts

More from Markets

Week Ahead: Trade Fears and Stress Tests Signal More Volatility To Come

Week Ahead: Trade Fears and Stress Tests Signal More Volatility To Come

Trump Takes Aim at Auto Imports; Markets End Mixed -- ICYMI

Trump Takes Aim at Auto Imports; Markets End Mixed -- ICYMI

Video: What Oprah's Content Partnership With Apple Means for the Rest of Tech

Video: What Oprah's Content Partnership With Apple Means for the Rest of Tech

REPLAY: Jim Cramer on the Markets, Oil, Starbucks, Tesla, Okta and Red Hat

REPLAY: Jim Cramer on the Markets, Oil, Starbucks, Tesla, Okta and Red Hat

Flashback Friday: The Market Movers

Flashback Friday: The Market Movers