Set vs list

Fixes 1228caae9e5f525abed6061001121fbb670716a6

I just came across the solution by chance and fixed it. In general, where can I find the definitions and documentation for functions like stdenv.lib.optional?