Sherlock says, "Once you've ruled out the impossible, whatever remains, however improbable, must be true," after which Watson calls him "Spock." In "Star Trek VI: The Undiscovered Country," Spock uses the same line. This is extremely metaphysical in-joke, because the character Spock learned the line from the original Sherlock novels written in the 1890s.