Commit 818045b6 by Jason Merrill Committed by Jason Merrill

input.c (sub_getch): Eventually give up and release the input file.

	* input.c (sub_getch): Eventually give up and release the input file.

	* decl.c (cp_finish_decl): If #p i/i, put inline statics in the
	right place.

From-SVN: r14923
parent 3e68fa83
Mon Aug 25 14:30:02 1997 Jason Merrill <jason@yorick.cygnus.com> Mon Aug 25 14:30:02 1997 Jason Merrill <jason@yorick.cygnus.com>
* input.c (sub_getch): Eventually give up and release the input file.
* decl.c (cp_finish_decl): If #p i/i, put inline statics in the
right place.
* call.c (joust): Tweak message. * call.c (joust): Tweak message.
Sat Aug 23 18:02:59 1997 Mark Mitchell <mmitchell@usa.net> Sat Aug 23 18:02:59 1997 Mark Mitchell <mmitchell@usa.net>
......
...@@ -6580,10 +6580,15 @@ cp_finish_decl (decl, init, asmspec_tree, need_pop, flags) ...@@ -6580,10 +6580,15 @@ cp_finish_decl (decl, init, asmspec_tree, need_pop, flags)
&& DECL_THIS_INLINE (current_function_decl) && DECL_THIS_INLINE (current_function_decl)
&& DECL_PUBLIC (current_function_decl)) && DECL_PUBLIC (current_function_decl))
{ {
if (DECL_INTERFACE_KNOWN (current_function_decl))
{
TREE_PUBLIC (decl) = 1;
DECL_EXTERNAL (decl) = DECL_EXTERNAL (current_function_decl);
}
/* We can only do this if we can use common or weak, and we /* We can only do this if we can use common or weak, and we
can't if it has been initialized and we don't support weak. */ can't if it has been initialized and we don't support weak. */
if (DECL_INITIAL (decl) == NULL_TREE else if (DECL_INITIAL (decl) == NULL_TREE
|| DECL_INITIAL (decl) == error_mark_node) || DECL_INITIAL (decl) == error_mark_node)
{ {
TREE_PUBLIC (decl) = 1; TREE_PUBLIC (decl) = 1;
DECL_COMMON (decl) = 1; DECL_COMMON (decl) = 1;
......
...@@ -158,7 +158,13 @@ sub_getch () ...@@ -158,7 +158,13 @@ sub_getch ()
if (input->offset >= input->length) if (input->offset >= input->length)
{ {
my_friendly_assert (putback_char == -1, 223); my_friendly_assert (putback_char == -1, 223);
return EOF; ++(input->offset);
if (input->offset - input->length < 64)
return EOF;
/* We must be stuck in an error-handling rule; give up. */
end_input ();
return getch ();
} }
return (unsigned char)input->str[input->offset++]; return (unsigned char)input->str[input->offset++];
} }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment