File: prism-ada.html

package info (click to toggle)
node-prismjs 1.30.0%2Bdfsg%2B~1.26.5-1
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid
  • size: 19,220 kB
  • sloc: javascript: 27,628; makefile: 9; sh: 7; awk: 4
file content (35 lines) | stat: -rw-r--r-- 806 bytes parent folder | download | duplicates (3)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
<h2>Strings</h2>
<pre><code>"foo ""bar"" baz"
"Multi-line strings are appended with a " &
"ampersand symbole."</code></pre>

<h2>Ada83 example</h2>
<pre><code>WITH ADA.TEXT_IO;

--  Comments look like this.

PROCEDURE TEST IS
BEGIN
   ADA.TEXT_IO.PUT_LINE ("Hello");   --  Comments look like this.
END TEST;</code></pre>

<h2>Ada 2012 full example</h2>
<pre><code>with Ada.Text_IO; Use Ada.Text_IO;

--  Comments look like this.
procedure Test is
   procedure Bah with
    Import        => True,   --  Shows the new aspect feature of the language.
    Convention    => C,
    External_Name => "bah";

   type Things is range 1 .. 10;
begin
   Put_Line ("Hello");   --  Comments look like this.

   Bah;  -- Call C function.

   for Index in Things'Range loop
      null;
   end loop;
end Test;</code></pre>