confusing case behavior with a java static int

clojure

Solution

The `test-constant`s in a `case` expression are not evaluated. So your statement is testing whether the number `5` is the same as the symbol `java.awt.image.BufferedImage/TYPE_3BYTE_BGR`. Since they aren't, it falls through to the default clause.

Problem

I'm confused...this static value is equal to 5 ``` user> java.awt.image.BufferedImage/TYPE_3BYTE_BGR 5 ``` and a case statement should work like this ``` user> (case 5 5 "yes" "huh?") "yes" ``` but why does it work like this? Why doesn't it match? ``` user> (case java.awt.image.BufferedImage/TYPE_3BYTE_BGR java.awt.image.BufferedImage/TYPE_3BYTE_BGR "yes" "huh?") "huh?" ```

Original source