xref: /titanic_51/usr/src/cmd/mandoc/att.c (revision 260e9a87725c090ba5835b1f9f0b62fa2f96036f)
1*260e9a87SYuri Pankov /*	$Id: att.c,v 1.13 2014/11/28 18:57:31 schwarze Exp $ */
295c635efSGarrett D'Amore /*
395c635efSGarrett D'Amore  * Copyright (c) 2009 Kristaps Dzonsons <kristaps@bsd.lv>
495c635efSGarrett D'Amore  *
595c635efSGarrett D'Amore  * Permission to use, copy, modify, and distribute this software for any
695c635efSGarrett D'Amore  * purpose with or without fee is hereby granted, provided that the above
795c635efSGarrett D'Amore  * copyright notice and this permission notice appear in all copies.
895c635efSGarrett D'Amore  *
995c635efSGarrett D'Amore  * THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
1095c635efSGarrett D'Amore  * WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
1195c635efSGarrett D'Amore  * MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
1295c635efSGarrett D'Amore  * ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
1395c635efSGarrett D'Amore  * WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
1495c635efSGarrett D'Amore  * ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
1595c635efSGarrett D'Amore  * OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
1695c635efSGarrett D'Amore  */
1795c635efSGarrett D'Amore #include "config.h"
1895c635efSGarrett D'Amore 
19*260e9a87SYuri Pankov #include <sys/types.h>
2095c635efSGarrett D'Amore #include <string.h>
2195c635efSGarrett D'Amore 
2295c635efSGarrett D'Amore #include "mdoc.h"
2395c635efSGarrett D'Amore #include "libmdoc.h"
2495c635efSGarrett D'Amore 
2595c635efSGarrett D'Amore #define LINE(x, y) \
26*260e9a87SYuri Pankov 	if (0 == strcmp(p, x)) return(y)
27*260e9a87SYuri Pankov 
2895c635efSGarrett D'Amore 
2995c635efSGarrett D'Amore const char *
3095c635efSGarrett D'Amore mdoc_a2att(const char *p)
3195c635efSGarrett D'Amore {
3295c635efSGarrett D'Amore 
33*260e9a87SYuri Pankov 	LINE("v1",	"Version\\~1 AT&T UNIX");
34*260e9a87SYuri Pankov 	LINE("v2",	"Version\\~2 AT&T UNIX");
35*260e9a87SYuri Pankov 	LINE("v3",	"Version\\~3 AT&T UNIX");
36*260e9a87SYuri Pankov 	LINE("v4",	"Version\\~4 AT&T UNIX");
37*260e9a87SYuri Pankov 	LINE("v5",	"Version\\~5 AT&T UNIX");
38*260e9a87SYuri Pankov 	LINE("v6",	"Version\\~6 AT&T UNIX");
39*260e9a87SYuri Pankov 	LINE("v7",	"Version\\~7 AT&T UNIX");
40*260e9a87SYuri Pankov 	LINE("32v",	"Version\\~32V AT&T UNIX");
41*260e9a87SYuri Pankov 	LINE("III",	"AT&T System\\~III UNIX");
42*260e9a87SYuri Pankov 	LINE("V",	"AT&T System\\~V UNIX");
43*260e9a87SYuri Pankov 	LINE("V.1",	"AT&T System\\~V Release\\~1 UNIX");
44*260e9a87SYuri Pankov 	LINE("V.2",	"AT&T System\\~V Release\\~2 UNIX");
45*260e9a87SYuri Pankov 	LINE("V.3",	"AT&T System\\~V Release\\~3 UNIX");
46*260e9a87SYuri Pankov 	LINE("V.4",	"AT&T System\\~V Release\\~4 UNIX");
4795c635efSGarrett D'Amore 
4895c635efSGarrett D'Amore 	return(NULL);
4995c635efSGarrett D'Amore }
50