Possible YAML bug with quoted symbols?

I don't think this is specific of yaml - it's done to say that your variable
name is a String that contains a ' or a " at the beginning and end , so
\"my_string\" or \'my_string\'
are Strings with quotes in them and not the same
as the Strings a="my_string" or a='my_string' .

Best regards,

Axel

Axel,

Thanks for replying, but I don't follow what you are saying here. I am using YAML to store objects in a database to later be retrieved and this marshaling or serialisation process must be bidirectional so whatever goes in comes out *exactly* the same, i.e.

      some_object == YAML.load(YAML.dump(some_object) # == is being used to mean the same as

and this doesn't appear to be the case when some_object is a quoted symbol :'some symbol'. If I were only dealing with symbols I could work around this, but the symbol is buried inside some object hierarchies. In this case I don't really care how YAML encodes the objects as long as it can be treated as text.

Dave.

ยทยทยท

On 7 Jun 2006, at 17:08, Nuralanur@aol.com wrote:

I don't think this is specific of yaml - it's done to say that your variable
name is a String that contains a ' or a " at the beginning and end , so
\"my_string\" or \'my_string\'
are Strings with quotes in them and not the same
as the Strings a="my_string" or a='my_string' .

Best regards,

Axel