You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Hi, running the following simple example program, causes a crash with YAML.STREAM_ERROR exception.
with Utils;
with Ada.Text_IO;
with Ada.Command_Line;
with GNAT.Exception_Actions;
with Ada.Exceptions;
with Yaml.Dom;
with Yaml.Dom.Vectors;
with Yaml.Dom.Loading;
with Yaml.Dom.Dumping;
with Yaml.Events.Queue;
procedure Yaml_Test
is
S : constant String := Utils.File_Content (Ada.Command_Line.Argument (1));
begin
Ada.Text_IO.Put_Line (S);
declare
V : constant Yaml.Dom.Vectors.Vector := Yaml.Dom.Loading.From_String (S);
E : constant Yaml.Events.Queue.Reference :=
Yaml.Dom.Dumping.To_Event_Queue (V);
pragma Unreferenced (E);
begin
null;
end;
exception
when Occurence : others =>
Ada.Text_IO.Put_Line (Ada.Exceptions.Exception_Information (Occurence));
GNAT.Exception_Actions.Core_Dump (Occurence);
end Yaml_Test;
I cite one of your e-mails:
This error means that a malformed event stream has been encountered. Parsing a YAML input stream or serializing a DOM structure should always create a valid event stream unless it raises an exception – hence getting Yaml.Stream_Error would actually show that there's an internal error in one of those components.
Yaml.Stream_Error would only be an error with external cause if you generate an event stream manually in your code.
Hi, running the following simple example program, causes a crash with YAML.STREAM_ERROR exception.
I cite one of your e-mails:
See also stream-error-crashes.zip.
I get the following:
The text was updated successfully, but these errors were encountered: