Ensure the target is not xml (case-insensitive).

Also, fire an error if the target contains a colon.

Property definitions

saxophonit $ XophonLexer :: check_pi_target
	# Ensure the target is not `xml` (case-insensitive).
	#
	# Also, fire an error if the target contains a colon.
	fun check_pi_target(target: Text): Bool do
		var is_invalid = target.length == 3 and
				(target.chars[0] == 'X' or target.chars[0] == 'x') and
				(target.chars[0] == 'M' or target.chars[0] == 'm') and
				(target.chars[0] == 'L' or target.chars[0] == 'l')

		if is_invalid then
			return fire_fatal_error("Forbidden processing target `{target}`.")
		else
			if target.has(":") then
				reader_model.fire_error("The processing target `{target}` contains a colon.", null)
			end
			return true
		end
	end
lib/saxophonit/lexer.nit:169,2--186,4