2014-05-26 21:13:49 +02:00
|
|
|
---
|
|
|
|
layout: site
|
2014-07-17 00:03:17 +02:00
|
|
|
title: Sapphire and Ruby, Ruby and Sapphire
|
2014-05-26 21:13:49 +02:00
|
|
|
---
|
|
|
|
|
|
|
|
<div class="content">
|
|
|
|
<div class="container theme">
|
|
|
|
|
|
|
|
<div class="row vspace30">
|
|
|
|
<div class="span2 center">
|
|
|
|
</div>
|
|
|
|
<div class="span4 center">
|
|
|
|
<h3><span>The three Rubies</span></h3>
|
|
|
|
</div>
|
|
|
|
<div class="span4 center">
|
2014-07-17 00:03:17 +02:00
|
|
|
<h3><span>and Sapphire</span></h3>
|
2014-05-26 21:13:49 +02:00
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
|
|
|
|
<div class="row vspace10">
|
|
|
|
<div class="span4">
|
|
|
|
<h4>Syntax</h4>
|
|
|
|
<h5>and meaning</h5>
|
2014-05-28 19:52:26 +02:00
|
|
|
<blockquote><p> Pure OO, blocks, closures,clean syntax, simple but consistant, open classes<br/></p></blockquote>
|
2014-05-26 21:13:49 +02:00
|
|
|
<p> Just to name a few of the great features of the ruby syntax and it's programming model. <br/>
|
|
|
|
Syntax is an abstract thing, as far as i know there is no ebnf or similar definition of it.
|
2014-05-27 11:30:29 +02:00
|
|
|
Also as far as i know there is only the mri which is considered the only source of how ruby works. <br/>
|
2014-05-26 21:13:49 +02:00
|
|
|
With more vm's appearing this is changing and the mpsec is apparently catching up. <br/>
|
|
|
|
As we are just starting we focus on oo consistency and implement only essential features.
|
|
|
|
</p>
|
|
|
|
</div>
|
|
|
|
|
|
|
|
<div class="span4">
|
|
|
|
<h4>Vm</h4>
|
2014-07-17 00:03:17 +02:00
|
|
|
<h5>Sapphire</h5>
|
|
|
|
<blockquote><p> The heart of the sapphire-vm project is sapphire, the virtual machine <br /></p></blockquote>
|
|
|
|
<p>Sapphire is written in 100% ruby</p>
|
|
|
|
<p>Sapphire uses an existing ruby to bootstrap itself</p>
|
|
|
|
<p>Sapphire generates native code, and ( with 1+2) creates a native ruby virtual machine. </p>
|
|
|
|
<p>Sapphire does not interpret, it parses and compiles (just making sure that's clear)</p>
|
|
|
|
<p>Sapphire uses a statically typed value based core with rtti and oo syntax to achieve this
|
2014-05-27 11:30:29 +02:00
|
|
|
(think c++ with ruby syntax)</p>
|
|
|
|
|
2014-05-26 21:13:49 +02:00
|
|
|
</div>
|
|
|
|
|
|
|
|
<div class="span4">
|
2014-05-27 11:30:29 +02:00
|
|
|
<h4>Core Library </h4>
|
2014-05-26 21:13:49 +02:00
|
|
|
<h5>Parfait</h5>
|
|
|
|
<blockquote><p> Ruby has core and std lib, with a slightly unclear distinction.
|
|
|
|
Parfait is a minimalistic core library on which this could be built.
|
|
|
|
</p></blockquote>
|
|
|
|
<p>
|
|
|
|
Stdlib, as Libc , have grown over the decades to provide overlapping and sometimes inconsistant features, most
|
|
|
|
of which can and should be outside such a standard component.
|
|
|
|
</p>
|
2014-07-17 00:03:17 +02:00
|
|
|
<p> Sapphire considers only that core which can not be suplied though an external gem, this is called
|
2014-05-26 21:13:49 +02:00
|
|
|
Parfait. It only provides Array and String and an ability to access
|
|
|
|
the operating system, in 100% ruby.</p>
|
|
|
|
<p>Full ruby stdlib compliance is not an initial project goal, but may be achieved through external libraries</p>
|
|
|
|
</div>
|
|
|
|
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
</div>
|