Subversion-Projekte lars-tiefland.cienc

Revision

Details | Letzte Änderung | Log anzeigen | RSS feed

Revision Autor Zeilennr. Zeile
5 lars 1
<!doctype html>
2
<title>CodeMirror: Gas mode</title>
3
<meta charset="utf-8" />
4
<link rel=stylesheet href="../../doc/docs.css">
5
<link rel="stylesheet" href="../../lib/codemirror.css">
6
<script src="../../lib/codemirror.js"></script>
7
<script src="gas.js"></script>
8
<style>
9
    .CodeMirror {
10
        border: 2px inset #dee;
11
    }
12
</style>
13
<div id=nav>
14
    <a href="http://codemirror.net">
15
        <h1>CodeMirror</h1>
16
        <img id=logo src="../../doc/logo.png">
17
    </a>
18
    <ul>
19
        <li>
20
            <a href="../../index.html">Home</a>
21
            <li>
22
                <a href="../../doc/manual.html">Manual</a>
23
                <li>
24
                    <a href="https://github.com/codemirror/codemirror">Code</a>
25
    </ul>
26
    <ul>
27
        <li>
28
            <a href="../index.html">Language modes</a>
29
            <li>
30
                <a class=active href="#">Gas</a>
31
    </ul>
32
</div>
33
<article>
34
    <h2>Gas mode</h2>
35
    <form>
36
        <textarea id="code" name="code"> .syntax unified .global main /* * A * multi-line * comment. */ @ A single line comment. main: push {sp, lr} ldr r0, =message bl puts mov r0, #0 pop {sp, pc} message: .asciz "Hello world!
37
            <br />" </textarea>
38
    </form>
39
    <script>
40
        var editor = CodeMirror.fromTextArea(document.getElementById("code"),
41
        {
42
            lineNumbers: true,
43
            mode:
44
            {
45
                name: "gas",
46
                architecture: "ARMv6"
47
            },
48
        });
49
    </script>
50
    <p>Handles AT&amp;T assembler syntax (more specifically this handles the GNU Assembler (gas) syntax.) It takes a single optional configuration parameter: <code>architecture</code>, which can be one of <code>"ARM"</code>, <code>"ARMv6"</code> or <code>"x86"</code>.
51
        Including the parameter adds syntax for the registers and special directives for the supplied architecture.
52
        <p>
53
            <strong>MIME types defined:</strong> <code>text/x-gas</code></p>
54
</article>