blob: 7f7c5b635d0b15700e8a1397cf4f075e9c79be9e (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
|
/* $NetBSD: opt_ta.c,v 1.6 2023/05/15 20:50:37 rillig Exp $ */
/*
* Tests for the option '-ta', which assumes that all identifiers that end in
* '_t' are type names. This mainly affects declarations and expressions
* containing type casts.
*/
//indent input
void
example(void *arg)
{
int mult = (unknown_type_name) * arg;
int cast = (unknown_type_name_t) * arg;
}
//indent end
//indent run -ta
void
example(void *arg)
{
int mult = (unknown_type_name) * arg;
int cast = (unknown_type_name_t)*arg;
}
//indent end
|