<?xml version="1.0" encoding="utf-8" standalone="yes"?>
<oembed>
  <author_name>zehnpaard</author_name>
  <author_url>https://blog.hatena.ne.jp/zehnpaard/</author_url>
  <blog_title>Arantium Maestum</blog_title>
  <blog_url>https://zehnpaard.hatenablog.com/</blog_url>
  <categories>
    <anon>OCaml</anon>
    <anon>継続</anon>
    <anon>言語処理系</anon>
  </categories>
  <description>前回に続いてCPS変換の話。 前回はパーサから帰ってくるExp.t型のASTを同じExp.t型のCPS形式になっているASTに変換してからインタプリタに実行させていた。 インタプリタが（特にビルトイン関数について）関数の最終引数を継続だと認識するようになったので、CPS変換前のASTはExp.t型なのに実行できないようになっていた（実行時エラーになる）。それだったらむしろ型をわけて、そもそもCPS変換前のASTをインタプリタに渡そうとするのはコンパイルエラーになるようにしたい。 ついでに ifの条件部分がsimpleならCPS変換しない 関数定義はsimpleな式として扱う の二点も一緒に実装…</description>
  <height>190</height>
  <html>&lt;iframe src=&quot;https://hatenablog-parts.com/embed?url=https%3A%2F%2Fzehnpaard.hatenablog.com%2Fentry%2F2020%2F07%2F07%2F194617&quot; title=&quot;型の違うCPS表現への変換 - Arantium Maestum&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>2020-07-07 19:46:17</published>
  <title>型の違うCPS表現への変換</title>
  <type>rich</type>
  <url>https://zehnpaard.hatenablog.com/entry/2020/07/07/194617</url>
  <version>1.0</version>
  <width>100%</width>
</oembed>
