module Kramdown::Options

def self.simple_array_validator(val, name, size)

Additionally, the array is checked for the correct size.

- or an array.
- a comma separated string which is split into an array of values

parameter +val+ can be
Ensures that the option value +val+ for the option called +name+ is a valid array. The
def self.simple_array_validator(val, name, size)
  if String === val
    val = val.split(/,/)
  elsif !(Array === val)
    raise Kramdown::Error, "Invalid type #{val.class} for option #{name}"
  end
  if val.size != size
    raise Kramdown::Error, "Option #{name} needs exactly #{size} values"
  end
  val
end