diff options
| author | Mauro Carvalho Chehab <mchehab@s-opensource.com> | 2016-08-30 19:20:57 -0400 |
|---|---|---|
| committer | Jonathan Corbet <corbet@lwn.net> | 2016-09-01 10:07:22 -0400 |
| commit | d37c43ce1975c1c3f28064bf3ebd2876e177bad8 (patch) | |
| tree | 8be76c9aeea2e1e994a1054617b37e308736b5c9 /scripts/kernel-doc | |
| parent | 7c142bfee6cbcd90b1847a708e22d461a1dfa38b (diff) | |
docs-rst: improve typedef parser
Improve the parser to handle typedefs like:
typedef bool v4l2_check_dv_timings_fnc(const struct v4l2_dv_timings *t, void *handle);
Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
Signed-off-by: Jonathan Corbet <corbet@lwn.net>
Diffstat (limited to 'scripts/kernel-doc')
| -rwxr-xr-x | scripts/kernel-doc | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/scripts/kernel-doc b/scripts/kernel-doc index d225e178aa1b..ad6d4e495f3f 100755 --- a/scripts/kernel-doc +++ b/scripts/kernel-doc | |||
| @@ -2190,7 +2190,9 @@ sub dump_typedef($$) { | |||
| 2190 | $x =~ s@/\*.*?\*/@@gos; # strip comments. | 2190 | $x =~ s@/\*.*?\*/@@gos; # strip comments. |
| 2191 | 2191 | ||
| 2192 | # Parse function prototypes | 2192 | # Parse function prototypes |
| 2193 | if ($x =~ /typedef\s+(\w+)\s*\(\*\s*(\w\S+)\s*\)\s*\((.*)\);/) { | 2193 | if ($x =~ /typedef\s+(\w+)\s*\(\*\s*(\w\S+)\s*\)\s*\((.*)\);/ || |
| 2194 | $x =~ /typedef\s+(\w+)\s*(\w\S+)\s*\s*\((.*)\);/) { | ||
| 2195 | |||
| 2194 | # Function typedefs | 2196 | # Function typedefs |
| 2195 | $return_type = $1; | 2197 | $return_type = $1; |
| 2196 | $declaration_name = $2; | 2198 | $declaration_name = $2; |
