diff options
author | Behdad Esfahbod <behdad@behdad.org> | 2008-01-28 22:10:20 -0500 |
---|---|---|
committer | Behdad Esfahbod <behdad@behdad.org> | 2008-01-28 22:10:20 -0500 |
commit | 52cc603db1a805a0b3a8d7eba3171cd2785f10a7 (patch) | |
tree | fb3f36d4fc92f09afb3318d4315098d71d8aed10 /src/check-doc-syntax.sh | |
parent | b790c5a6bcdd890c16d21753407188ed200ce445 (diff) | |
download | cairo-52cc603db1a805a0b3a8d7eba3171cd2785f10a7.tar.gz |
[doc] Stricter syntax check for type names, update test
Diffstat (limited to 'src/check-doc-syntax.sh')
-rwxr-xr-x | src/check-doc-syntax.sh | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/src/check-doc-syntax.sh b/src/check-doc-syntax.sh index a7e8d5a3e..7b0908ff6 100755 --- a/src/check-doc-syntax.sh +++ b/src/check-doc-syntax.sh @@ -17,12 +17,13 @@ if grep "$enum_regexp" $FILES; then echo " sed -i 's@$enum_regexp@\\1%\\2@' *.h *.c *.cpp" fi -type_regexp='^\([/ ][*] .*[^#]\)\<\(cairo[0-9a-z_]*_t\>\)' +type_regexp='^[/ ][*]\( .*[^#]\| \)\<\(cairo[0-9a-z_]*_t\>\($\|[^:]$\|[^:].\)\)' if grep "$type_regexp" $FILES; then status=1 - echo Error: some type names in the docs are not prefixed by hash sign. - echo Fix this by running the following sed command as many times as needed: - echo " sed -i 's@$type_regexp@\\1#\\2@' *.h *.c *.cpp" + echo Error: some type names in the docs are not prefixed by hash sign, + echo neither are the only token in the doc line followed by collon. + echo Fix this by searching for the following regexp in the above files: + echo " '$type_regexp'" fi func_regexp='^\([/ ][*] .*[^#]\)\<\(cairo_[][<>/0-9a-z_]*\> \?[^][ <>(]\)' |