[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[7220] parsetexi update
From: |
gavinsmith0123 |
Subject: |
[7220] parsetexi update |
Date: |
Sun, 12 Jun 2016 19:26:49 +0000 (UTC) |
Revision: 7220
http://svn.sv.gnu.org/viewvc/?view=rev&root=texinfo&revision=7220
Author: gavin
Date: 2016-06-12 19:26:48 +0000 (Sun, 12 Jun 2016)
Log Message:
-----------
parsetexi update
Modified Paths:
--------------
trunk/tp/parsetexi/Parsetexi.pm
trunk/tp/parsetexi/convert.c
trunk/tp/parsetexi/end_line.c
trunk/tp/parsetexi/parser.c
Modified: trunk/tp/parsetexi/Parsetexi.pm
===================================================================
--- trunk/tp/parsetexi/Parsetexi.pm 2016-06-12 16:27:52 UTC (rev 7219)
+++ trunk/tp/parsetexi/Parsetexi.pm 2016-06-12 19:26:48 UTC (rev 7220)
@@ -526,6 +526,7 @@
# Other values are treated at the moment as 'default'.
my $TEXINFO_XS = $ENV{'TEXINFO_XS'};
+$TEXINFO_XS = "required";
if (!defined($TEXINFO_XS)) {
$TEXINFO_XS = '';
}
Modified: trunk/tp/parsetexi/convert.c
===================================================================
--- trunk/tp/parsetexi/convert.c 2016-06-12 16:27:52 UTC (rev 7219)
+++ trunk/tp/parsetexi/convert.c 2016-06-12 19:26:48 UTC (rev 7220)
@@ -36,7 +36,7 @@
if (which > 0 && e->contents.list[which]->text.text)
return e->contents.list[which]->text.text;
}
- return "AAAAAAAAA";
+ return "";
}
/* Produce normalized node name recursively. IN_UC is non-zero if we are
@@ -49,6 +49,35 @@
/* Empty if ignored type, or ignored brace command, or has a misc arg or
misc
line arg argument. */
+ if (root->cmd == CM_anchor
+ || root->cmd == CM_footnote
+ || root->cmd == CM_shortcaption
+ || root->cmd == CM_caption
+ || root->cmd == CM_hyphenation
+ || root->type == ET_empty_line
+ || root->type == ET_empty_line_after_command
+ || root->type == ET_preamble
+ || root->type == ET_empty_spaces_after_command
+ || root->type == ET_spaces_at_end
+ || root->type == ET_empty_spaces_before_argument
+
+ || root->type == ET_empty_spaces_before_paragraph
+ || root->type == ET_space_at_end_menu_node
+ || root->type == ET_empty_spaces_after_close_brace
+ || root->type == ET_empty_space_at_end_def_bracketed)
+ {
+ ADD ("");
+ return;
+ }
+
+ if (root->args.number >= 1 // 287
+ && (args_child_by_index(root, 0)->type == ET_misc_line_arg
+ || args_child_by_index(root, 0)->type == ET_misc_arg))
+ {
+ ADD ("");
+ return;
+ }
+
if (root->text.end > 0)
{
char *p = root->text.text, *q;
Modified: trunk/tp/parsetexi/end_line.c
===================================================================
--- trunk/tp/parsetexi/end_line.c 2016-06-12 16:27:52 UTC (rev 7219)
+++ trunk/tp/parsetexi/end_line.c 2016-06-12 19:26:48 UTC (rev 7220)
@@ -848,12 +848,15 @@
/* TODO: Same as above re route_not_in_tree. */
ELEMENT *before, *after;
- before = new_element (ET_NONE);
- before->parent_type = route_not_in_tree;
- before->parent = node; // FIXME - try not to set this
- text_append_n (&before->text, e->text.text,
- closing_bracket - e->text.text);
- add_to_contents_as_array (manual, before);
+ if (closing_bracket > e->text.text)
+ {
+ before = new_element (ET_NONE);
+ before->parent_type = route_not_in_tree;
+ before->parent = node; // FIXME - try not to set this
+ text_append_n (&before->text, e->text.text,
+ closing_bracket - e->text.text);
+ add_to_contents_as_array (manual, before);
+ }
/* Skip ')' and any following whitespace.
Note that we don't manage to skip any multibyte
Modified: trunk/tp/parsetexi/parser.c
===================================================================
--- trunk/tp/parsetexi/parser.c 2016-06-12 16:27:52 UTC (rev 7219)
+++ trunk/tp/parsetexi/parser.c 2016-06-12 19:26:48 UTC (rev 7220)
@@ -1172,8 +1172,11 @@
Texinfo::Report::gdt we deliberately pass
in undefined values. */
ELEMENT *value_elt;
+
line_error ("undefined flag: %.*s", line - arg_start,
arg_start);
+
+ abort_empty_line (¤t, NULL);
value_elt = new_element (ET_NONE);
value_elt->cmd = CM_value;
text_append_n (&value_elt->text, arg_start,
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [7220] parsetexi update,
gavinsmith0123 <=