Update docs

This commit is contained in:
2025-12-24 22:04:03 +11:00
parent d15cd17f23
commit e0fb187a7c

View File

@@ -58,9 +58,8 @@ puts "You can print out anything with puts!"</code></pre>
<pre class="code"><code>x = 5<br>puts x</code></pre> <pre class="code"><code>x = 5<br>puts x</code></pre>
<p>Types are automatically inferred by Solstice.</p> <p>Types are automatically inferred by Solstice.</p>
<h3>Maths</h3> <h3>Maths</h3>
<p>Note: math is currently in beta. Order of Operations is harder to implement than I thought lol</p>
<p>You can use <code>+</code> (add), <code>-</code> (subtract), <code>*</code> (multiply), and <code>/</code> (divide) to do math.</p> <p>You can use <code>+</code> (add), <code>-</code> (subtract), <code>*</code> (multiply), and <code>/</code> (divide) to do math.</p>
<p>Math operations take two values on either side, and perform the operation.</p> <p>Math operations take two values on either side, and perform the operation. Order of operations is supported.</p>
<pre class="code"><code>x = 5 + 3<br>y = 10<br>puts x + y</code></pre> <pre class="code"><code>x = 5 + 3<br>y = 10<br>puts x + y</code></pre>
<h3>Control Flow and Equalities</h3> <h3>Control Flow and Equalities</h3>
<p>Solstice supports <code>if</code> and <code>while</code> statements, as well as the <code>==</code>, <code>!=</code>, <code>></code>, <code>>=</code>, <code><</code>, and <code><=</code> operations.</p> <p>Solstice supports <code>if</code> and <code>while</code> statements, as well as the <code>==</code>, <code>!=</code>, <code>></code>, <code>>=</code>, <code><</code>, and <code><=</code> operations.</p>