/*
 * Generated by ./misc/optlib2c from optlib/man.ctags, Don't edit this manually.
 */
#include "general.h"
#include "parse.h"
#include "routines.h"
#include "field.h"
#include "xtag.h"


static void initializeManParser (const langType language CTAGS_ATTR_UNUSED)
{
}

extern parserDefinition* ManParser (void)
{
	static const char *const extensions [] = {
		"1",
		"2",
		"3",
		"4",
		"5",
		"6",
		"7",
		"8",
		"9",
		"3pm",
		"3stap",
		"7stap",
		NULL
	};

	static const char *const aliases [] = {
		NULL
	};

	static const char *const patterns [] = {
		NULL
	};

	static kindDefinition ManKindTable [] = {
		{
		  true, 't', "title", "titles",
		},
		{
		  true, 's', "section", "sections",
		},
	};
	static tagRegexTable ManTagRegexTable [] = {
		{"^\\.TH[[:space:]]{1,}\"([^\"]{1,})\".*", "\\1",
		"t", "{exclusive}{icase}{scope=push}", NULL, false},
		{"^\\.TH[[:space:]]{1,}([^[:space:]]{1,}).*", "\\1",
		"t", "{exclusive}{icase}{scope=push}", NULL, false},
		{"^\\.SH[[:space:]]{1,}\"([^\"]{1,})\".*", "\\1",
		"s", "{exclusive}{icase}{scope=ref}", NULL, false},
		{"^\\.SH[[:space:]]{1,}([^[:space:]]{1,}).*", "\\1",
		"s", "{exclusive}{icase}{scope=ref}", NULL, false},
	};


	parserDefinition* const def = parserNew ("Man");

	def->enabled       = true;
	def->extensions    = extensions;
	def->patterns      = patterns;
	def->aliases       = aliases;
	def->method        = METHOD_NOT_CRAFTED|METHOD_REGEX;
	def->useCork       = 1;
	def->kindTable     = ManKindTable;
	def->kindCount     = ARRAY_SIZE(ManKindTable);
	def->tagRegexTable = ManTagRegexTable;
	def->tagRegexCount = ARRAY_SIZE(ManTagRegexTable);
	def->initialize    = initializeManParser;

	return def;
}
