Encouraging data on corporate profit, the labor market and oil prices sent the Standard & Poor’s 500 index, the Nasdaq composite and the Dow Jones industrial average to record closing highs Thursday. This is the first time the benchmarks have closed at record highs on the same day since 1999.