Stocks in consumer staples companies fell, while makers of discretionary products were little changed as investors shifted into technology stocks ahead of key earnings reports.

Hasbro raised its full-year outlook after swinging to a profit and logging higher revenue in the second quarter, driven by continued strength in its Wizards of the Coast and digital-gaming segment.

Carl Icahn's company, Icahn Enterprises, has struck a deal to sell auto-service chain Pep Boys to private-equity owned Mavis Tire Express Services. Mavis will pay roughly $700 million in cash under the deal, the companies said.

3M increased its full-year targets as the conglomerate saw higher sales in safety and electronics. The maker of Post-It notes said it now expects adjusted earnings per share between $8.80 and $8.95 for the year, up from a previous range of $8.50 to $8.70. Utz Brands has agreed to be taken private by German salty snacks maker Intersnack Group at an enterprise value of about $2.9 billion. Utz said Intersnack will pay $14.25 a share in cash for the Hanover, Pa., company, a 91% premium to Monday's closing price of $7.45.

Kraft Heinz and Disney struck a deal that gives the food conglomerate a foothold in one of America's most enduring entertainment empires. Under the multiyear partnership, Disney will serve Kraft Heinz products at its properties throughout North America, and Kraft Heinz will be able to use Disney's characters on some goods in stores.