In a saucepan, heat milk, sugar, butter, and salt until small bubbles form. In a bowl, whisk together eggs, then add the warm milk mixture in a slow stream, whisking constantly. Layer the square pan with bread. Top with pears that have been peeled, cored, and cut into eighths. Pour the milk-egg mixture into the baking pan and sprinkle with cinnamon. Bake until golden, about 35 minutes. Top with Cheddar and bake until the cheese is melted, 5 to 10 minutes (optional). Serve warm.