From: Kurt Stephens Date: 2011-11-08T00:30:43+09:00 Subject: [ruby-core:40816] [ruby-trunk - Feature #5578] Embedded YAML for Ruby 2.0 Issue #5578 has been updated by Kurt Stephens. Why does YAML need first class status? Define a constructor on the YAML module, and use interpolating heredoc. require 'pp' require 'yaml' def YAML.[]str; YAML.load(str); end x = YAML[<<"..."] a: 1 b: 2 c: #{ 1 + 1 } ... pp x And it's generic enough for other encodings: xml = XML[<<"end"] text end etc. ---------------------------------------- Feature #5578: Embedded YAML for Ruby 2.0 http://redmine.ruby-lang.org/issues/5578 Author: Thomas Sawyer Status: Open Priority: Normal Assignee: Category: Target version: 2.0.0 Way cool would be support for embedded YAML. data = --- a: 1 b: 2 c: 3 ... -- http://redmine.ruby-lang.org