Debian Codegraph @

examples/prism-ruby.html

raw symbols SCIP
1 <h2>Comments</h2>
2 <pre><code># This is a comment
3 =begin
4 Multi-line
5 comment
6 =end</code></pre>
7
8 <h2>Strings</h2>
9 <pre><code>"foo \"bar\" baz"
10 'foo \'bar\' baz'
11 &lt;&lt;STRING
12 here's some #{string} contents
13 STRING</code></pre>
14
15 <h2>Regular expressions</h2>
16 <pre><code>/foo?[ ]*bar/</code></pre>
17
18 <h2>Variables</h2>
19 <pre><code>$foo = 5;
20 class InstTest
21 def set_foo(n)
22 @foo = n
23 end
24 def set_bar(n)
25 @bar = n
26 end
27 end</code></pre>
28
29 <h2>Symbols</h2>
30 <pre><code>mystring = :steveT;</code></pre>
31
32 <h2>String Interpolation</h2>
33 <pre><code>"foo #{'bar'+my_variable}"</code></pre>