<?xml version="1.0" encoding="utf-8" standalone="yes"?>
<oembed>
  <author_name>xtalco</author_name>
  <author_url>https://blog.hatena.ne.jp/xtalco/</author_url>
  <blog_title>新言語 Xtalを作る日記</blog_title>
  <blog_url>https://xtalco.hatenadiary.org/</blog_url>
  <categories>
  </categories>
  <description>もともと文字列の長さがsizeof(int)-1のものは、即値になるようにしてメモリ確保が起きないよう工夫していましたが、 今回、文字列リテラルを渡されて生成されたStringオブジェクトも即値になるようにしました。 void foo(){ StringPtr str = xnew&lt;String&gt;(XTAL_STRING(&quot;This is a pen.&quot;)); // 変数strに直接文字列リテラルへのポインタが埋め込まれている AnyPtr a = XTAL_STRING(&quot;Hello, World&quot;); // 変数aに直接文字列リテラルへのポインタが埋め込まれている }</description>
  <height>190</height>
  <html>&lt;iframe src=&quot;https://hatenablog-parts.com/embed?url=https%3A%2F%2Fxtalco.hatenadiary.org%2Fentry%2F20091226%2F1261838206&quot; title=&quot; 文字列リテラルを渡されて生成されたStringオブジェクトは、メモリ確保が起こらないようにした - 新言語 Xtalを作る日記&quot; class=&quot;embed-card embed-blogcard&quot; scrolling=&quot;no&quot; frameborder=&quot;0&quot; style=&quot;display: block; width: 100%; height: 190px; max-width: 500px; margin: 10px 0px;&quot;&gt;&lt;/iframe&gt;</html>
  <image_url></image_url>
  <provider_name>Hatena Blog</provider_name>
  <provider_url>https://hatena.blog</provider_url>
  <published>2009-12-26 23:36:46</published>
  <title> 文字列リテラルを渡されて生成されたStringオブジェクトは、メモリ確保が起こらないようにした</title>
  <type>rich</type>
  <url>https://xtalco.hatenadiary.org/entry/20091226/1261838206</url>
  <version>1.0</version>
  <width>100%</width>
</oembed>
