Commit Graph

14 Commits

Author SHA1 Message Date
why d578f9d32e * ext/syck/emitter.c (syck_scan_scalar): prevent indicators from
appearing alone or at the end of plain scalars. [ruby-core:5826]

* ext/syck/emitter.c (syck_emit_scalar): treat typed scalar nodes
  as complex keys.

* lib/syck.h: version 0.60.

* lib/yaml/basenode.rb (YAML::BaseNode#at): transform keys during
  key searches.

* ext/syck/rubyext.c: loading of binary-typed nodes.  prevent
  emission of plain strings that look like symbols, but which aren't.

* ext/syck/emitter.c (syck_emit): passing an int* value to the
  long* parameter causes unaligned access on LP64 systems.
  [ruby-dev:27161]


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@9242 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2005-09-20 06:50:20 +00:00
why f1827a2faf * lib/yaml.rb: reworking YAML::Stream to use the new
emitter.

* lib/yaml/stream.rb: ditto.

* lib/yaml/rubytypes.rb: added Object#yaml_new.

* lib/yaml/tag.rb: the tag_subclasses? method now
  shows up in the class.  allow taguri to be set using an accessor.
  continue support of Object#to_yaml_type.

* ext/syck/rubyext.c: new emitter code.  yaml_new and yaml_initialize
  get called, should they be present.  consolidated all the diaspora of internal
  node types into the family below YAML::Syck::Node -- Map,
  Seq, Scalar -- all of whom are SyckNode structs pointing to
  Ruby data.  moved Object#yaml_new into the node_import and made it the
  default behavior.  the target_class is always called wih yaml_new, prepended
  a parameter, which is the klass.  loaded nodes through GenericResolver show their style.
  new Resolver#tagurize converts type ids to taguris.

* ext/syck/implicit.re: were 'y' and 'n' seriously omitted??

* ext/syck/emitter.c: renovated emitter, walks the tree in advance.
  consolidated redundant block_styles struct into
  the scalar_style struct.  (this means loaded nodes can now
  be sent back to emitter and preserve at least its very basic
  formatting.)

* ext/syck/gram.c: headless documents of any kind allowed.

* ext/syck/node.c: new syck_replace_str methods and syck_empty_*
  methods for rewriting node contents, while keeping the ID
  and other setup info.  added syck_seq_assign.

* ext/syck/syck.h: reflect block_styles and new node functions.


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@9141 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2005-09-13 03:58:33 +00:00
why 2fa9a0b08c * lib/yaml/rubytypes.rb (to_yaml): added instance variable handling
for Ranges, Strings, Structs, Regexps.

* lib/yaml/rubytypes.rb (to_yaml_fold): new method for setting a
  String's flow style.

* lib/yaml.rb (YAML::object_maker): now uses Object.allocate.

* ext/syck/gram.c: fixed transfer methods on structs, broke it
  last commit.


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@6252 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2004-05-06 06:29:56 +00:00
why c76c3349e4 * ext/syck/bytecode.c: Checkin of YAML bytecode support.
* ext/syck/gram.c: Ditto.

* ext/syck/syck.c: Ditto.

* ext/syck/token.c: Ditto.

* ext/syck/handler.c: Ditto.

* ext/syck/handler.c: Now using 'tag' rather than 'taguri' in type URIs.

* ext/syck/rubyext.c: Ditto (on both counts).


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@4769 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2003-10-14 23:15:19 +00:00
why 360b0a015a * ext/syck/syck.h: Parser definition problems on HP-UX. [ruby-talk:79389]
* ext/syck/handler.c (syck_hdlr_get_anchor): Memory leak.

* ext/syck/syck.s (syck_io_file_read): Bad arguments to fread.

* ext/syck/rubyext.c: Tainting issues.


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@4414 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2003-08-19 16:38:02 +00:00
why 0a75581a37 * ext/syck/syck.h: Added 'syck' yacc prefixes.
* ext/syck/gram.c: ditto.

* ext/syck/token.c: ditto.

* ext/syck: Added ruby.h reference to source files.


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@4199 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2003-07-28 19:27:42 +00:00
why ae28f1b6b3 * ext/syck/gram.c: added grammar for certain empty sequence entries.
* ext/syck/handler.c, ext/syck/syck.c, ext/syck/syck.h: track bad anchors.

* ext/syck/token.c: added pause token, tag possible circular references.

* lib/yaml/rubytypes.rb: parsing YMD time as Date instance.

* ext/syck/rubyext.c: ditto. DomainType, PrivateType, BadAlias classes.


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@3954 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2003-06-17 16:55:54 +00:00
why 017d4ff10a * ext/syck/token.c: directives choked on a period.
* ext/syck/gram.y: anchors work above a collection. [ruby-core:1071]

* ext/syck/handler.c, ext/syck/syck.c: ensure a fresh strtable between
  parser iterations.


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@3905 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2003-06-05 04:43:05 +00:00
why 5d47fda3f8 * ext/syck/handler.c, ext/syck/syck.h: removed syck_fold_format().
* ext/syck/gram.c: flexibility for aliases and anchors.

* ext/syck/token.c: folding now handled in the tokenizer.


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@3880 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2003-05-29 23:33:10 +00:00
eban bee670e33a ext/syck/handler.c (syck_hdlr_add_alias): add cast to avoid warning.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@3788 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2003-05-13 16:25:41 +00:00
eban 43b1770ed6 * ext/syck/handler.c: add proper casts.
* ext/syck/syck.c: ditto.


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@3787 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2003-05-13 11:41:19 +00:00
why bd810795c5 * lib/yaml/rubytypes.rb: object and struct loading
* lib/yaml.rb: YAML::detect_implicit will discover typing for a Ruby string

* ext/syck/: Fixed portable comments, misuse of NULL and methods without return VALUEs.


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@3784 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2003-05-13 06:34:18 +00:00
why 4b25d0d2cb * ext/syck/gram.c ext/syck/handler.c ext/syck/implicit.c
ext/syck/node.c ext/syck/rubyext.c ext/syck/syck.c
  ext/syck/syck.h ext/syck/token.c: updated to Syck 0.27

* lib/yaml/loader.rb: new YAML::Loader class

* lib/yaml.rb: loading of type families leverages YAML::DefaultLoader


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@3778 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2003-05-10 19:55:18 +00:00
why 55f4dc4c9a Initial checkin of YAML substances.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@3772 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2003-05-09 21:25:50 +00:00