Stocks ended higher Wednesday as Wall Street looks past uncertainty about Brexit and worries about Boeing after the United States became the latest country to ground the 737 Max 8.