]> mj.ucw.cz Git - libucw.git/commitdiff
Doc. system: fix ... in function parameters
authorMichal Vaner <vorner@ucw.cz>
Sat, 13 Sep 2008 10:42:53 +0000 (12:42 +0200)
committerMichal Vaner <vorner@ucw.cz>
Sat, 13 Sep 2008 10:42:53 +0000 (12:42 +0200)
Asciidoc tries to convert all ... strings into ellipsis character, which
is wrong in function parameters (it is 3 separate chars in reality,
besides this caused problems with xrefs, links, etc).

build/doc-defs
build/doc-extract

index 712968c319b4068c857bc4abd35ee95a2ade4b19..c69885837ffba39524782df9b0cb56ecaee910c3 100755 (executable)
@@ -43,6 +43,7 @@ foreach( sort { ( $groups{$a->[2]} <=> $groups{$b->[2]} ) or ( $a->[3] cmp $b->[
        $file =~ s/^\///;
        $file =~ s/\.[^.]+$//;
        $text =~ s/\(/!!PARENT_OPEN!!/g;
+       $text =~ s/(\.\.\.)/\\$1/g;
        print OUT "- <<$file:auto_$num,`$text`>>\n";
 }
 
index 8553af94a836f8a69046c28a7cd0dc8b30942d8a..072b9237c1ba0b1125e47aa08a93e1cc10184f00 100755 (executable)
@@ -52,7 +52,9 @@ sub formatNote( $$ ) {
        chomp $head;
        print OUT "[[auto_$id]]\n";
         my( $type, $semicolon, $name, $oneline ) = detect( $head );
+       $oneline =~ s/\s+$//;
         $head =~ s/;?\s*$/;/ if( $semicolon );
+       $head =~ s/(\.\.\.)/\\$1/g;
        if( $type eq 'function' ) {
                print OUT "!!f!$head!!!\n\n";
        } else {