ducktype iteration to allow "for var in dict::JuMPDict"