# File ext/RMagick/extconf.rb, line 13 def have_enum_value(enum, value, headers=nil, &b) checking_for "#{enum}.#{value}" do if try_compile("\#{COMMON_HEADERS}\n\#{cpp_include(headers)}\n/*top*/\nint main() { \#{enum} t = \#{value}; t = t; return 0; }\n", &b) $defs.push(format("-DHAVE_ENUM_%s", value.upcase)) true else false end end end