A Systematic Comparison of Syllogistic Reasoning in Humans and Language Models