Debian Codegraph @

lib/expr/extype.c

raw
1 /*************************************************************************
2 * Copyright (c) 2011 AT&T Intellectual Property
3 * All rights reserved. This program and the accompanying materials
4 * are made available under the terms of the Eclipse Public License v1.0
5 * which accompanies this distribution, and is available at
6 * https://www.eclipse.org/legal/epl-v10.html
7 *
8 * Contributors: Details at https://graphviz.org
9 *************************************************************************/
10
11 /*
12 * Glenn Fowler
13 * AT&T Research
14 *
15 * expression library C program generator
16 */
17
18 #include "config.h"
19
20 #include <expr/exlib.h>
21
22 /*
23 * return C type name for type
24 */
25
26 char *extype(long int type) {
27 switch (type)
28 {
29 case FLOATING:
30 return "double";
31 case STRING:
32 return "char*";
33 case UNSIGNED:
34 return "uintmax_t";
35 }
36 return "intmax_t";
37 }