# File lib/rb-kqueue/native/flags.rb, line 106 def self.from_flag(prefix, flag) re = /^#{Regexp.quote prefix}_/ constants.each do |sym| c = sym.to_s next unless c =~ re return c.to_s.sub("#{prefix}_", "").downcase.to_sym if const_get(c) == flag end end