Files
Nim/tinyc.html
github-actions[bot] ef3d9e7b38 Deploy to GitHub pages
2025-12-28 15:55:52 +00:00

541 lines
49 KiB
HTML

<?xml version="1.0" encoding="utf-8" ?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "https://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<!-- This file is generated by Nim. -->
<html xmlns="https://www.w3.org/1999/xhtml" xml:lang="en" lang="en" data-theme="auto">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>std/tinyc</title>
<!-- Google fonts -->
<link href='https://fonts.googleapis.com/css?family=Lato:400,600,900' rel='stylesheet' type='text/css'/>
<link href='https://fonts.googleapis.com/css?family=Source+Code+Pro:400,500,600' rel='stylesheet' type='text/css'/>
<!-- Favicon -->
<link rel="shortcut icon" href="data:image/x-icon;base64,AAABAAEAEBAAAAEAIABoBAAAFgAAACgAAAAQAAAAIAAAAAEAIAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAD///8A////AP///wD///8A////AP///wD///8A////AP///wD///8A////AP///wD///8A////AP///wD///8A////AP///wD///8A////AP///wD///8A////AAAAAAUAAAAF////AP///wD///8A////AP///wD///8A////AP///wD///8A////AAAAAAIAAABbAAAAlQAAAKIAAACbAAAAmwAAAKIAAACVAAAAWwAAAAL///8A////AP///wD///8A////AAAAABQAAADAAAAAYwAAAA3///8A////AP///wD///8AAAAADQAAAGMAAADAAAAAFP///wD///8A////AP///wAAAACdAAAAOv///wD///8A////AP///wD///8A////AP///wD///8AAAAAOgAAAJ3///8A////AP///wAAAAAnAAAAcP///wAAAAAoAAAASv///wD///8A////AP///wAAAABKAAAAKP///wAAAABwAAAAJ////wD///8AAAAAgQAAABwAAACIAAAAkAAAAJMAAACtAAAAFQAAABUAAACtAAAAkwAAAJAAAACIAAAAHAAAAIH///8A////AAAAAKQAAACrAAAAaP///wD///8AAAAARQAAANIAAADSAAAARf///wD///8AAAAAaAAAAKsAAACk////AAAAADMAAACcAAAAnQAAABj///8A////AP///wAAAAAYAAAAGP///wD///8A////AAAAABgAAACdAAAAnAAAADMAAAB1AAAAwwAAAP8AAADpAAAAsQAAAE4AAAAb////AP///wAAAAAbAAAATgAAALEAAADpAAAA/wAAAMMAAAB1AAAAtwAAAOkAAAD/AAAA/wAAAP8AAADvAAAA3gAAAN4AAADeAAAA3gAAAO8AAAD/AAAA/wAAAP8AAADpAAAAtwAAAGUAAAA/AAAA3wAAAP8AAAD/AAAA/wAAAP8AAAD/AAAA/wAAAP8AAAD/AAAA/wAAAP8AAADfAAAAPwAAAGX///8A////AAAAAEgAAADtAAAAvwAAAL0AAADGAAAA7wAAAO8AAADGAAAAvQAAAL8AAADtAAAASP///wD///8A////AP///wD///8AAAAAO////wD///8A////AAAAAIcAAACH////AP///wD///8AAAAAO////wD///8A////AP///wD///8A////AP///wD///8A////AP///wD///8A////AP///wD///8A////AP///wD///8A////AP///wD///8A////AP///wD///8A////AP///wD///8A////AP///wD///8A////AP///wD///8A////AP///wD///8A//8AAP//AAD4HwAA7/cAAN/7AAD//wAAoYUAAJ55AACf+QAAh+EAAAAAAADAAwAA4AcAAP5/AAD//wAA//8AAA=="/>
<link rel="icon" type="image/png" sizes="32x32" href="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAYAAABzenr0AAAABmJLR0QA/wD/AP+gvaeTAAAACXBIWXMAAA3XAAAN1wFCKJt4AAAAB3RJTUUH4QQQEwksSS9ZWwAAAk1JREFUWMPtll2ITVEUx39nn/O7Y5qR8f05wtCUUr6ZIS++8pEnkZInPImneaCQ5METNdOkeFBKUhMPRIkHKfEuUZSUlGlKPN2TrgfncpvmnntnmlEyq1Z7t89/rf9a6+y99oZxGZf/XeIq61EdtgKXgdXA0xrYAvBjOIF1AI9zvjcC74BSpndrJPkBWDScTF8Aa4E3wDlgHbASaANmVqlcCnwHvgDvgVfAJ+AikAAvgfVZwLnSVZHZaOuKoQi3ZOMi4NkYkpe1p4J7A8BpYAD49hfIy/oqG0+hLomiKP2L5L+1ubn5115S+3OAn4EnwBlgMzCjyt6ZAnQCJ4A7wOs88iRJHvw50HoujuPBoCKwHWiosy8MdfZnAdcHk8dxXFJ3VQbQlCTJvRBCGdRbD4M6uc5glpY3eAihpN5S5w12diSEcCCEcKUO4ljdr15T76ur1FDDLIQQ3qv71EdDOe3Kxj3leRXyk+pxdWnFWod6Wt2bY3de3aSuUHcPBVimHs7mK9WrmeOF6lR1o9qnzskh2ar2qm1qizpfXaPeVGdlmGN5pb09qMxz1Xb1kLqgzn1RyH7JUXW52lr5e/Kqi9qpto7V1atuUzfnARrV7jEib1T76gG2qxdGmXyiekkt1GswPTtek0aBfJp6YySGBfWg2tPQ0FAYgf1stUfdmdcjarbYJEniKIq6gY/Aw+zWHAC+p2labGpqiorFYgGYCEzN7oQdQClN07O1/EfDyGgC0ALMBdYAi4FyK+4H3gLPsxfR1zRNi+NP7nH5J+QntnXe5B5mpfQAAAAASUVORK5CYII=">
<!-- CSS -->
<link rel="stylesheet" type="text/css" href="nimdoc.out.css?v=2.3.1">
<!-- JS -->
<script type="text/javascript" src="dochack.js?v=2.3.1"></script>
</head>
<body>
<div class="document" id="documentId">
<div class="container">
<h1 class="title">std/tinyc</h1>
<div class="row">
<div class="three columns">
<div class="theme-select-wrapper">
<label for="theme-select">Theme:&nbsp;</label>
<select id="theme-select" onchange="setTheme(this.value)">
<option value="auto">🌗 Match OS</option>
<option value="dark">🌑 Dark</option>
<option value="light">🌕 Light</option>
</select>
</div>
<div id="global-links">
<ul class="simple-boot">
<li><a href="manual.html">Manual</a></li>
<li><a href="lib.html">Standard library</a></li>
<li> <a id="indexLink" href="theindex.html">Index</a></li>
<li><a href="compiler/theindex.html">Compiler docs</a></li>
<li><a href="https://nim-lang.github.io/fusion/theindex.html">Fusion docs</a></li>
<li><a href="https://nim-lang.github.io/Nim/">devel</a>, <a href="https://nim-lang.org/documentation.html">stable</a></li>
</ul>
</div>
<div id="searchInputDiv">
Search: <input type="search" id="searchInput"
oninput="search()" />
</div>
<ul class="simple simple-toc" id="toc-list">
<li>
<details open>
<summary><a class="reference reference-toplevel" href="#7" id="57">Types</a></summary>
<ul class="simple simple-toc-section">
<li><a class="reference" href="#ErrorFunc" title="ErrorFunc = proc (opaque: pointer; msg: cstring) {.cdecl.}">ErrorFunc</a></li>
<li><a class="reference" href="#PccState" title="PccState = ptr CcState">PccState</a></li>
</ul>
</details>
</li>
<li>
<details open>
<summary><a class="reference reference-toplevel" href="#10" id="60">Consts</a></summary>
<ul class="simple simple-toc-section">
<li><a class="reference" href="#OutputDll" title="OutputDll: cint = 3">OutputDll</a></li>
<li><a class="reference" href="#OutputExe" title="OutputExe: cint = 2">OutputExe</a></li>
<li><a class="reference" href="#OutputMemory" title="OutputMemory: cint = 1">OutputMemory</a></li>
<li><a class="reference" href="#OutputObj" title="OutputObj: cint = 4">OutputObj</a></li>
<li><a class="reference" href="#OutputPreprocess" title="OutputPreprocess: cint = 5">OutputPreprocess</a></li>
</ul>
</details>
</li>
<li>
<details open>
<summary><a class="reference reference-toplevel" href="#12" id="62">Procs</a></summary>
<ul class="simple simple-toc-section">
<ul class="simple nested-toc-section">addFile
<li><a class="reference" href="#addFile%2CPccState%2Ccstring" title="addFile(s: PccState; filename: cstring): cint">addFile(s: PccState; filename: cstring): cint</a></li>
</ul>
<ul class="simple nested-toc-section">addIncludePath
<li><a class="reference" href="#addIncludePath%2CPccState%2Ccstring" title="addIncludePath(s: PccState; pathname: cstring)">addIncludePath(s: PccState; pathname: cstring)</a></li>
</ul>
<ul class="simple nested-toc-section">addLibrary
<li><a class="reference" href="#addLibrary%2CPccState%2Ccstring" title="addLibrary(s: PccState; libraryname: cstring): cint">addLibrary(s: PccState; libraryname: cstring): cint</a></li>
</ul>
<ul class="simple nested-toc-section">addLibraryPath
<li><a class="reference" href="#addLibraryPath%2CPccState%2Ccstring" title="addLibraryPath(s: PccState; pathname: cstring): cint">addLibraryPath(s: PccState; pathname: cstring): cint</a></li>
</ul>
<ul class="simple nested-toc-section">addSymbol
<li><a class="reference" href="#addSymbol%2CPccState%2Ccstring%2Cpointer" title="addSymbol(s: PccState; name: cstring; val: pointer): cint">addSymbol(s: PccState; name: cstring; val: pointer): cint</a></li>
</ul>
<ul class="simple nested-toc-section">addSysincludePath
<li><a class="reference" href="#addSysincludePath%2CPccState%2Ccstring" title="addSysincludePath(s: PccState; pathname: cstring)">addSysincludePath(s: PccState; pathname: cstring)</a></li>
</ul>
<ul class="simple nested-toc-section">closeCCState
<li><a class="reference" href="#closeCCState%2CPccState" title="closeCCState(s: PccState)">closeCCState(s: PccState)</a></li>
</ul>
<ul class="simple nested-toc-section">compileString
<li><a class="reference" href="#compileString%2CPccState%2Ccstring" title="compileString(s: PccState; buf: cstring): cint">compileString(s: PccState; buf: cstring): cint</a></li>
</ul>
<ul class="simple nested-toc-section">defineSymbol
<li><a class="reference" href="#defineSymbol%2CPccState%2Ccstring%2Ccstring" title="defineSymbol(s: PccState; sym, value: cstring)">defineSymbol(s: PccState; sym, value: cstring)</a></li>
</ul>
<ul class="simple nested-toc-section">getSymbol
<li><a class="reference" href="#getSymbol%2CPccState%2Ccstring" title="getSymbol(s: PccState; name: cstring): pointer">getSymbol(s: PccState; name: cstring): pointer</a></li>
</ul>
<ul class="simple nested-toc-section">openCCState
<li><a class="reference" href="#openCCState" title="openCCState(): PccState">openCCState(): PccState</a></li>
</ul>
<ul class="simple nested-toc-section">outputFile
<li><a class="reference" href="#outputFile%2CPccState%2Ccstring" title="outputFile(s: PccState; filename: cstring): cint">outputFile(s: PccState; filename: cstring): cint</a></li>
</ul>
<ul class="simple nested-toc-section">relocate
<li><a class="reference" href="#relocate%2CPccState%2Cpointer" title="relocate(s: PccState; p: pointer): cint">relocate(s: PccState; p: pointer): cint</a></li>
</ul>
<ul class="simple nested-toc-section">run
<li><a class="reference" href="#run%2CPccState%2Ccint%2CcstringArray" title="run(s: PccState; argc: cint; argv: cstringArray): cint">run(s: PccState; argc: cint; argv: cstringArray): cint</a></li>
</ul>
<ul class="simple nested-toc-section">setErrorFunc
<li><a class="reference" href="#setErrorFunc%2CPccState%2Cpointer%2CErrorFunc" title="setErrorFunc(s: PccState; errorOpaque: pointer; errorFun: ErrorFunc)">setErrorFunc(s: PccState; errorOpaque: pointer; errorFun: ErrorFunc)</a></li>
</ul>
<ul class="simple nested-toc-section">setLibPath
<li><a class="reference" href="#setLibPath%2CPccState%2Ccstring" title="setLibPath(s: PccState; path: cstring)">setLibPath(s: PccState; path: cstring)</a></li>
</ul>
<ul class="simple nested-toc-section">setOptions
<li><a class="reference" href="#setOptions%2CPccState%2Ccstring" title="setOptions(s: PccState; options: cstring)">setOptions(s: PccState; options: cstring)</a></li>
</ul>
<ul class="simple nested-toc-section">setOutputType
<li><a class="reference" href="#setOutputType%2CPccState%2Ccint" title="setOutputType(s: PccState; outputType: cint): cint">setOutputType(s: PccState; outputType: cint): cint</a></li>
</ul>
<ul class="simple nested-toc-section">undefineSymbol
<li><a class="reference" href="#undefineSymbol%2CPccState%2Ccstring" title="undefineSymbol(s: PccState; sym: cstring)">undefineSymbol(s: PccState; sym: cstring)</a></li>
</ul>
</ul>
</details>
</li>
</ul>
</div>
<div class="nine columns" id="content">
<a href="https://github.com/nim-lang/Nim/tree/devel/lib/wrappers/tinyc.nim#L1" class="link-seesrc" target="_blank">Source</a>&nbsp;&nbsp;
<a href="https://github.com/nim-lang/Nim/edit/devel/lib/wrappers/tinyc.nim#L1" class="link-seesrc" target="_blank" >Edit</a>&nbsp;&nbsp;
<div id="tocRoot"></div>
<p class="module-desc"></p>
<div class="section" id="7">
<h1><a class="toc-backref" href="#7">Types</a></h1>
<dl class="item">
<div id="ErrorFunc">
<dt><pre><a href="tinyc.html#ErrorFunc"><span class="Identifier">ErrorFunc</span></a> <span class="Other">=</span> <span class="Keyword">proc</span> <span class="Other">(</span><span class="Identifier">opaque</span><span class="Other">:</span> <a href="system.html#pointer"><span class="Identifier">pointer</span></a><span class="Other">;</span> <span class="Identifier">msg</span><span class="Other">:</span> <a href="system.html#cstring"><span class="Identifier">cstring</span></a><span class="Other">)</span> {.<span class="Identifier">cdecl</span>.}</pre></dt>
<dd>
<a href="https://github.com/nim-lang/Nim/tree/devel/lib/wrappers/tinyc.nim#L14" class="link-seesrc" target="_blank">Source</a>&nbsp;&nbsp;
<a href="https://github.com/nim-lang/Nim/edit/devel/lib/wrappers/tinyc.nim#L14" class="link-seesrc" target="_blank" >Edit</a>&nbsp;&nbsp;
</dd>
</div>
<div id="PccState">
<dt><pre><a href="tinyc.html#PccState"><span class="Identifier">PccState</span></a> <span class="Other">=</span> <span class="Keyword">ptr</span> <span class="Identifier">CcState</span></pre></dt>
<dd>
<a href="https://github.com/nim-lang/Nim/tree/devel/lib/wrappers/tinyc.nim#L12" class="link-seesrc" target="_blank">Source</a>&nbsp;&nbsp;
<a href="https://github.com/nim-lang/Nim/edit/devel/lib/wrappers/tinyc.nim#L12" class="link-seesrc" target="_blank" >Edit</a>&nbsp;&nbsp;
</dd>
</div>
</dl>
</div>
<div class="section" id="10">
<h1><a class="toc-backref" href="#10">Consts</a></h1>
<dl class="item">
<div id="OutputDll">
<dt><pre><a href="tinyc.html#OutputDll"><span class="Identifier">OutputDll</span></a><span class="Other">:</span> <a href="ctypes.html#cint"><span class="Identifier">cint</span></a> <span class="Other">=</span> <span class="DecNumber">3</span></pre></dt>
<dd>
dynamic library
<a href="https://github.com/nim-lang/Nim/tree/devel/lib/wrappers/tinyc.nim#L65" class="link-seesrc" target="_blank">Source</a>&nbsp;&nbsp;
<a href="https://github.com/nim-lang/Nim/edit/devel/lib/wrappers/tinyc.nim#L65" class="link-seesrc" target="_blank" >Edit</a>&nbsp;&nbsp;
</dd>
</div>
<div id="OutputExe">
<dt><pre><a href="tinyc.html#OutputExe"><span class="Identifier">OutputExe</span></a><span class="Other">:</span> <a href="ctypes.html#cint"><span class="Identifier">cint</span></a> <span class="Other">=</span> <span class="DecNumber">2</span></pre></dt>
<dd>
executable file
<a href="https://github.com/nim-lang/Nim/tree/devel/lib/wrappers/tinyc.nim#L64" class="link-seesrc" target="_blank">Source</a>&nbsp;&nbsp;
<a href="https://github.com/nim-lang/Nim/edit/devel/lib/wrappers/tinyc.nim#L64" class="link-seesrc" target="_blank" >Edit</a>&nbsp;&nbsp;
</dd>
</div>
<div id="OutputMemory">
<dt><pre><a href="tinyc.html#OutputMemory"><span class="Identifier">OutputMemory</span></a><span class="Other">:</span> <a href="ctypes.html#cint"><span class="Identifier">cint</span></a> <span class="Other">=</span> <span class="DecNumber">1</span></pre></dt>
<dd>
output will be ran in memory (no output file) (default)
<a href="https://github.com/nim-lang/Nim/tree/devel/lib/wrappers/tinyc.nim#L62" class="link-seesrc" target="_blank">Source</a>&nbsp;&nbsp;
<a href="https://github.com/nim-lang/Nim/edit/devel/lib/wrappers/tinyc.nim#L62" class="link-seesrc" target="_blank" >Edit</a>&nbsp;&nbsp;
</dd>
</div>
<div id="OutputObj">
<dt><pre><a href="tinyc.html#OutputObj"><span class="Identifier">OutputObj</span></a><span class="Other">:</span> <a href="ctypes.html#cint"><span class="Identifier">cint</span></a> <span class="Other">=</span> <span class="DecNumber">4</span></pre></dt>
<dd>
object file
<a href="https://github.com/nim-lang/Nim/tree/devel/lib/wrappers/tinyc.nim#L66" class="link-seesrc" target="_blank">Source</a>&nbsp;&nbsp;
<a href="https://github.com/nim-lang/Nim/edit/devel/lib/wrappers/tinyc.nim#L66" class="link-seesrc" target="_blank" >Edit</a>&nbsp;&nbsp;
</dd>
</div>
<div id="OutputPreprocess">
<dt><pre><a href="tinyc.html#OutputPreprocess"><span class="Identifier">OutputPreprocess</span></a><span class="Other">:</span> <a href="ctypes.html#cint"><span class="Identifier">cint</span></a> <span class="Other">=</span> <span class="DecNumber">5</span></pre></dt>
<dd>
preprocessed file (used internally)
<a href="https://github.com/nim-lang/Nim/tree/devel/lib/wrappers/tinyc.nim#L67" class="link-seesrc" target="_blank">Source</a>&nbsp;&nbsp;
<a href="https://github.com/nim-lang/Nim/edit/devel/lib/wrappers/tinyc.nim#L67" class="link-seesrc" target="_blank" >Edit</a>&nbsp;&nbsp;
</dd>
</div>
</dl>
</div>
<div class="section" id="12">
<h1><a class="toc-backref" href="#12">Procs</a></h1>
<dl class="item">
<div id="addFile-procs-all">
<div id="addFile,PccState,cstring">
<dt><pre><span class="Keyword">proc</span> <a href="#addFile%2CPccState%2Ccstring"><span class="Identifier">addFile</span></a><span class="Other">(</span><span class="Identifier">s</span><span class="Other">:</span> <a href="tinyc.html#PccState"><span class="Identifier">PccState</span></a><span class="Other">;</span> <span class="Identifier">filename</span><span class="Other">:</span> <a href="system.html#cstring"><span class="Identifier">cstring</span></a><span class="Other">)</span><span class="Other">:</span> <a href="ctypes.html#cint"><span class="Identifier">cint</span></a> {.<span class="Identifier">cdecl</span><span class="Other">,</span>
<span class="Identifier">importc</span><span class="Other">:</span> <span class="StringLit">&quot;tcc_add_file&quot;</span><span class="Other">,</span> <span><span class="Other pragmadots">...</span></span><span class="pragmawrap"><span class="Identifier">raises</span><span class="Other">:</span> <span class="Other">[</span><span class="Other">]</span><span class="Other">,</span> <span class="Identifier">tags</span><span class="Other">:</span> <span class="Other">[</span><span class="Other">]</span><span class="Other">,</span> <span class="Identifier">forbids</span><span class="Other">:</span> <span class="Other">[</span><span class="Other">]</span></span>.}</pre></dt>
<dd>
add a file (either a C file, dll, an object, a library or an ld script). Return -1 if error.
<a href="https://github.com/nim-lang/Nim/tree/devel/lib/wrappers/tinyc.nim#L49" class="link-seesrc" target="_blank">Source</a>&nbsp;&nbsp;
<a href="https://github.com/nim-lang/Nim/edit/devel/lib/wrappers/tinyc.nim#L49" class="link-seesrc" target="_blank" >Edit</a>&nbsp;&nbsp;
</dd>
</div>
</div>
<div id="addIncludePath-procs-all">
<div id="addIncludePath,PccState,cstring">
<dt><pre><span class="Keyword">proc</span> <a href="#addIncludePath%2CPccState%2Ccstring"><span class="Identifier">addIncludePath</span></a><span class="Other">(</span><span class="Identifier">s</span><span class="Other">:</span> <a href="tinyc.html#PccState"><span class="Identifier">PccState</span></a><span class="Other">;</span> <span class="Identifier">pathname</span><span class="Other">:</span> <a href="system.html#cstring"><span class="Identifier">cstring</span></a><span class="Other">)</span> {.<span class="Identifier">cdecl</span><span class="Other">,</span>
<span class="Identifier">importc</span><span class="Other">:</span> <span class="StringLit">&quot;tcc_add_include_path&quot;</span><span class="Other">,</span> <span><span class="Other pragmadots">...</span></span><span class="pragmawrap"><span class="Identifier">raises</span><span class="Other">:</span> <span class="Other">[</span><span class="Other">]</span><span class="Other">,</span> <span class="Identifier">tags</span><span class="Other">:</span> <span class="Other">[</span><span class="Other">]</span><span class="Other">,</span> <span class="Identifier">forbids</span><span class="Other">:</span> <span class="Other">[</span><span class="Other">]</span></span>.}</pre></dt>
<dd>
add include path
<a href="https://github.com/nim-lang/Nim/tree/devel/lib/wrappers/tinyc.nim#L31" class="link-seesrc" target="_blank">Source</a>&nbsp;&nbsp;
<a href="https://github.com/nim-lang/Nim/edit/devel/lib/wrappers/tinyc.nim#L31" class="link-seesrc" target="_blank" >Edit</a>&nbsp;&nbsp;
</dd>
</div>
</div>
<div id="addLibrary-procs-all">
<div id="addLibrary,PccState,cstring">
<dt><pre><span class="Keyword">proc</span> <a href="#addLibrary%2CPccState%2Ccstring"><span class="Identifier">addLibrary</span></a><span class="Other">(</span><span class="Identifier">s</span><span class="Other">:</span> <a href="tinyc.html#PccState"><span class="Identifier">PccState</span></a><span class="Other">;</span> <span class="Identifier">libraryname</span><span class="Other">:</span> <a href="system.html#cstring"><span class="Identifier">cstring</span></a><span class="Other">)</span><span class="Other">:</span> <a href="ctypes.html#cint"><span class="Identifier">cint</span></a> {.<span class="Identifier">cdecl</span><span class="Other">,</span>
<span class="Identifier">importc</span><span class="Other">:</span> <span class="StringLit">&quot;tcc_add_library&quot;</span><span class="Other">,</span> <span><span class="Other pragmadots">...</span></span><span class="pragmawrap"><span class="Identifier">raises</span><span class="Other">:</span> <span class="Other">[</span><span class="Other">]</span><span class="Other">,</span> <span class="Identifier">tags</span><span class="Other">:</span> <span class="Other">[</span><span class="Other">]</span><span class="Other">,</span> <span class="Identifier">forbids</span><span class="Other">:</span> <span class="Other">[</span><span class="Other">]</span></span>.}</pre></dt>
<dd>
the library name is the same as the argument of the '-l' option
<a href="https://github.com/nim-lang/Nim/tree/devel/lib/wrappers/tinyc.nim#L77" class="link-seesrc" target="_blank">Source</a>&nbsp;&nbsp;
<a href="https://github.com/nim-lang/Nim/edit/devel/lib/wrappers/tinyc.nim#L77" class="link-seesrc" target="_blank" >Edit</a>&nbsp;&nbsp;
</dd>
</div>
</div>
<div id="addLibraryPath-procs-all">
<div id="addLibraryPath,PccState,cstring">
<dt><pre><span class="Keyword">proc</span> <a href="#addLibraryPath%2CPccState%2Ccstring"><span class="Identifier">addLibraryPath</span></a><span class="Other">(</span><span class="Identifier">s</span><span class="Other">:</span> <a href="tinyc.html#PccState"><span class="Identifier">PccState</span></a><span class="Other">;</span> <span class="Identifier">pathname</span><span class="Other">:</span> <a href="system.html#cstring"><span class="Identifier">cstring</span></a><span class="Other">)</span><span class="Other">:</span> <a href="ctypes.html#cint"><span class="Identifier">cint</span></a> {.<span class="Identifier">cdecl</span><span class="Other">,</span>
<span class="Identifier">importc</span><span class="Other">:</span> <span class="StringLit">&quot;tcc_add_library_path&quot;</span><span class="Other">,</span> <span><span class="Other pragmadots">...</span></span><span class="pragmawrap"><span class="Identifier">raises</span><span class="Other">:</span> <span class="Other">[</span><span class="Other">]</span><span class="Other">,</span> <span class="Identifier">tags</span><span class="Other">:</span> <span class="Other">[</span><span class="Other">]</span><span class="Other">,</span> <span class="Identifier">forbids</span><span class="Other">:</span> <span class="Other">[</span><span class="Other">]</span></span>.}</pre></dt>
<dd>
equivalent to -Lpath option
<a href="https://github.com/nim-lang/Nim/tree/devel/lib/wrappers/tinyc.nim#L73" class="link-seesrc" target="_blank">Source</a>&nbsp;&nbsp;
<a href="https://github.com/nim-lang/Nim/edit/devel/lib/wrappers/tinyc.nim#L73" class="link-seesrc" target="_blank" >Edit</a>&nbsp;&nbsp;
</dd>
</div>
</div>
<div id="addSymbol-procs-all">
<div id="addSymbol,PccState,cstring,pointer">
<dt><pre><span class="Keyword">proc</span> <a href="#addSymbol%2CPccState%2Ccstring%2Cpointer"><span class="Identifier">addSymbol</span></a><span class="Other">(</span><span class="Identifier">s</span><span class="Other">:</span> <a href="tinyc.html#PccState"><span class="Identifier">PccState</span></a><span class="Other">;</span> <span class="Identifier">name</span><span class="Other">:</span> <a href="system.html#cstring"><span class="Identifier">cstring</span></a><span class="Other">;</span> <span class="Identifier">val</span><span class="Other">:</span> <a href="system.html#pointer"><span class="Identifier">pointer</span></a><span class="Other">)</span><span class="Other">:</span> <a href="ctypes.html#cint"><span class="Identifier">cint</span></a> {.<span class="Identifier">cdecl</span><span class="Other">,</span>
<span class="Identifier">importc</span><span class="Other">:</span> <span class="StringLit">&quot;tcc_add_symbol&quot;</span><span class="Other">,</span> <span><span class="Other pragmadots">...</span></span><span class="pragmawrap"><span class="Identifier">raises</span><span class="Other">:</span> <span class="Other">[</span><span class="Other">]</span><span class="Other">,</span> <span class="Identifier">tags</span><span class="Other">:</span> <span class="Other">[</span><span class="Other">]</span><span class="Other">,</span> <span class="Identifier">forbids</span><span class="Other">:</span> <span class="Other">[</span><span class="Other">]</span></span>.}</pre></dt>
<dd>
add a symbol to the compiled program
<a href="https://github.com/nim-lang/Nim/tree/devel/lib/wrappers/tinyc.nim#L81" class="link-seesrc" target="_blank">Source</a>&nbsp;&nbsp;
<a href="https://github.com/nim-lang/Nim/edit/devel/lib/wrappers/tinyc.nim#L81" class="link-seesrc" target="_blank" >Edit</a>&nbsp;&nbsp;
</dd>
</div>
</div>
<div id="addSysincludePath-procs-all">
<div id="addSysincludePath,PccState,cstring">
<dt><pre><span class="Keyword">proc</span> <a href="#addSysincludePath%2CPccState%2Ccstring"><span class="Identifier">addSysincludePath</span></a><span class="Other">(</span><span class="Identifier">s</span><span class="Other">:</span> <a href="tinyc.html#PccState"><span class="Identifier">PccState</span></a><span class="Other">;</span> <span class="Identifier">pathname</span><span class="Other">:</span> <a href="system.html#cstring"><span class="Identifier">cstring</span></a><span class="Other">)</span> {.<span class="Identifier">cdecl</span><span class="Other">,</span>
<span class="Identifier">importc</span><span class="Other">:</span> <span class="StringLit">&quot;tcc_add_sysinclude_path&quot;</span><span class="Other">,</span> <span><span class="Other pragmadots">...</span></span><span class="pragmawrap"><span class="Identifier">raises</span><span class="Other">:</span> <span class="Other">[</span><span class="Other">]</span><span class="Other">,</span> <span class="Identifier">tags</span><span class="Other">:</span> <span class="Other">[</span><span class="Other">]</span><span class="Other">,</span> <span class="Identifier">forbids</span><span class="Other">:</span> <span class="Other">[</span><span class="Other">]</span></span>.}</pre></dt>
<dd>
add in system include path
<a href="https://github.com/nim-lang/Nim/tree/devel/lib/wrappers/tinyc.nim#L35" class="link-seesrc" target="_blank">Source</a>&nbsp;&nbsp;
<a href="https://github.com/nim-lang/Nim/edit/devel/lib/wrappers/tinyc.nim#L35" class="link-seesrc" target="_blank" >Edit</a>&nbsp;&nbsp;
</dd>
</div>
</div>
<div id="closeCCState-procs-all">
<div id="closeCCState,PccState">
<dt><pre><span class="Keyword">proc</span> <a href="#closeCCState%2CPccState"><span class="Identifier">closeCCState</span></a><span class="Other">(</span><span class="Identifier">s</span><span class="Other">:</span> <a href="tinyc.html#PccState"><span class="Identifier">PccState</span></a><span class="Other">)</span> {.<span class="Identifier">importc</span><span class="Other">:</span> <span class="StringLit">&quot;tcc_delete&quot;</span><span class="Other">,</span> <span class="Identifier">cdecl</span><span class="Other">,</span> <span><span class="Other pragmadots">...</span></span><span class="pragmawrap"><span class="Identifier">raises</span><span class="Other">:</span> <span class="Other">[</span><span class="Other">]</span><span class="Other">,</span>
<span class="Identifier">tags</span><span class="Other">:</span> <span class="Other">[</span><span class="Other">]</span><span class="Other">,</span> <span class="Identifier">forbids</span><span class="Other">:</span> <span class="Other">[</span><span class="Other">]</span></span>.}</pre></dt>
<dd>
free a TCC compilation context
<a href="https://github.com/nim-lang/Nim/tree/devel/lib/wrappers/tinyc.nim#L19" class="link-seesrc" target="_blank">Source</a>&nbsp;&nbsp;
<a href="https://github.com/nim-lang/Nim/edit/devel/lib/wrappers/tinyc.nim#L19" class="link-seesrc" target="_blank" >Edit</a>&nbsp;&nbsp;
</dd>
</div>
</div>
<div id="compileString-procs-all">
<div id="compileString,PccState,cstring">
<dt><pre><span class="Keyword">proc</span> <a href="#compileString%2CPccState%2Ccstring"><span class="Identifier">compileString</span></a><span class="Other">(</span><span class="Identifier">s</span><span class="Other">:</span> <a href="tinyc.html#PccState"><span class="Identifier">PccState</span></a><span class="Other">;</span> <span class="Identifier">buf</span><span class="Other">:</span> <a href="system.html#cstring"><span class="Identifier">cstring</span></a><span class="Other">)</span><span class="Other">:</span> <a href="ctypes.html#cint"><span class="Identifier">cint</span></a> {.<span class="Identifier">cdecl</span><span class="Other">,</span>
<span class="Identifier">importc</span><span class="Other">:</span> <span class="StringLit">&quot;tcc_compile_string&quot;</span><span class="Other">,</span> <span><span class="Other pragmadots">...</span></span><span class="pragmawrap"><span class="Identifier">raises</span><span class="Other">:</span> <span class="Other">[</span><span class="Other">]</span><span class="Other">,</span> <span class="Identifier">tags</span><span class="Other">:</span> <span class="Other">[</span><span class="Other">]</span><span class="Other">,</span> <span class="Identifier">forbids</span><span class="Other">:</span> <span class="Other">[</span><span class="Other">]</span></span>.}</pre></dt>
<dd>
compile a string containing a C source. Return non zero if error.
<a href="https://github.com/nim-lang/Nim/tree/devel/lib/wrappers/tinyc.nim#L54" class="link-seesrc" target="_blank">Source</a>&nbsp;&nbsp;
<a href="https://github.com/nim-lang/Nim/edit/devel/lib/wrappers/tinyc.nim#L54" class="link-seesrc" target="_blank" >Edit</a>&nbsp;&nbsp;
</dd>
</div>
</div>
<div id="defineSymbol-procs-all">
<div id="defineSymbol,PccState,cstring,cstring">
<dt><pre><span class="Keyword">proc</span> <a href="#defineSymbol%2CPccState%2Ccstring%2Ccstring"><span class="Identifier">defineSymbol</span></a><span class="Other">(</span><span class="Identifier">s</span><span class="Other">:</span> <a href="tinyc.html#PccState"><span class="Identifier">PccState</span></a><span class="Other">;</span> <span class="Identifier">sym</span><span class="Other">,</span> <span class="Identifier">value</span><span class="Other">:</span> <a href="system.html#cstring"><span class="Identifier">cstring</span></a><span class="Other">)</span> {.<span class="Identifier">cdecl</span><span class="Other">,</span>
<span class="Identifier">importc</span><span class="Other">:</span> <span class="StringLit">&quot;tcc_define_symbol&quot;</span><span class="Other">,</span> <span><span class="Other pragmadots">...</span></span><span class="pragmawrap"><span class="Identifier">raises</span><span class="Other">:</span> <span class="Other">[</span><span class="Other">]</span><span class="Other">,</span> <span class="Identifier">tags</span><span class="Other">:</span> <span class="Other">[</span><span class="Other">]</span><span class="Other">,</span> <span class="Identifier">forbids</span><span class="Other">:</span> <span class="Other">[</span><span class="Other">]</span></span>.}</pre></dt>
<dd>
define preprocessor symbol 'sym'. Can put optional value
<a href="https://github.com/nim-lang/Nim/tree/devel/lib/wrappers/tinyc.nim#L39" class="link-seesrc" target="_blank">Source</a>&nbsp;&nbsp;
<a href="https://github.com/nim-lang/Nim/edit/devel/lib/wrappers/tinyc.nim#L39" class="link-seesrc" target="_blank" >Edit</a>&nbsp;&nbsp;
</dd>
</div>
</div>
<div id="getSymbol-procs-all">
<div id="getSymbol,PccState,cstring">
<dt><pre><span class="Keyword">proc</span> <a href="#getSymbol%2CPccState%2Ccstring"><span class="Identifier">getSymbol</span></a><span class="Other">(</span><span class="Identifier">s</span><span class="Other">:</span> <a href="tinyc.html#PccState"><span class="Identifier">PccState</span></a><span class="Other">;</span> <span class="Identifier">name</span><span class="Other">:</span> <a href="system.html#cstring"><span class="Identifier">cstring</span></a><span class="Other">)</span><span class="Other">:</span> <a href="system.html#pointer"><span class="Identifier">pointer</span></a> {.<span class="Identifier">cdecl</span><span class="Other">,</span>
<span class="Identifier">importc</span><span class="Other">:</span> <span class="StringLit">&quot;tcc_get_symbol&quot;</span><span class="Other">,</span> <span><span class="Other pragmadots">...</span></span><span class="pragmawrap"><span class="Identifier">raises</span><span class="Other">:</span> <span class="Other">[</span><span class="Other">]</span><span class="Other">,</span> <span class="Identifier">tags</span><span class="Other">:</span> <span class="Other">[</span><span class="Other">]</span><span class="Other">,</span> <span class="Identifier">forbids</span><span class="Other">:</span> <span class="Other">[</span><span class="Other">]</span></span>.}</pre></dt>
<dd>
return symbol value or NULL if not found
<a href="https://github.com/nim-lang/Nim/tree/devel/lib/wrappers/tinyc.nim#L101" class="link-seesrc" target="_blank">Source</a>&nbsp;&nbsp;
<a href="https://github.com/nim-lang/Nim/edit/devel/lib/wrappers/tinyc.nim#L101" class="link-seesrc" target="_blank" >Edit</a>&nbsp;&nbsp;
</dd>
</div>
</div>
<div id="openCCState-procs-all">
<div id="openCCState">
<dt><pre><span class="Keyword">proc</span> <a href="#openCCState"><span class="Identifier">openCCState</span></a><span class="Other">(</span><span class="Other">)</span><span class="Other">:</span> <a href="tinyc.html#PccState"><span class="Identifier">PccState</span></a> {.<span class="Identifier">importc</span><span class="Other">:</span> <span class="StringLit">&quot;tcc_new&quot;</span><span class="Other">,</span> <span class="Identifier">cdecl</span><span class="Other">,</span> <span><span class="Other pragmadots">...</span></span><span class="pragmawrap"><span class="Identifier">raises</span><span class="Other">:</span> <span class="Other">[</span><span class="Other">]</span><span class="Other">,</span> <span class="Identifier">tags</span><span class="Other">:</span> <span class="Other">[</span><span class="Other">]</span><span class="Other">,</span>
<span class="Identifier">forbids</span><span class="Other">:</span> <span class="Other">[</span><span class="Other">]</span></span>.}</pre></dt>
<dd>
create a new TCC compilation context
<a href="https://github.com/nim-lang/Nim/tree/devel/lib/wrappers/tinyc.nim#L16" class="link-seesrc" target="_blank">Source</a>&nbsp;&nbsp;
<a href="https://github.com/nim-lang/Nim/edit/devel/lib/wrappers/tinyc.nim#L16" class="link-seesrc" target="_blank" >Edit</a>&nbsp;&nbsp;
</dd>
</div>
</div>
<div id="outputFile-procs-all">
<div id="outputFile,PccState,cstring">
<dt><pre><span class="Keyword">proc</span> <a href="#outputFile%2CPccState%2Ccstring"><span class="Identifier">outputFile</span></a><span class="Other">(</span><span class="Identifier">s</span><span class="Other">:</span> <a href="tinyc.html#PccState"><span class="Identifier">PccState</span></a><span class="Other">;</span> <span class="Identifier">filename</span><span class="Other">:</span> <a href="system.html#cstring"><span class="Identifier">cstring</span></a><span class="Other">)</span><span class="Other">:</span> <a href="ctypes.html#cint"><span class="Identifier">cint</span></a> {.<span class="Identifier">cdecl</span><span class="Other">,</span>
<span class="Identifier">importc</span><span class="Other">:</span> <span class="StringLit">&quot;tcc_output_file&quot;</span><span class="Other">,</span> <span><span class="Other pragmadots">...</span></span><span class="pragmawrap"><span class="Identifier">raises</span><span class="Other">:</span> <span class="Other">[</span><span class="Other">]</span><span class="Other">,</span> <span class="Identifier">tags</span><span class="Other">:</span> <span class="Other">[</span><span class="Other">]</span><span class="Other">,</span> <span class="Identifier">forbids</span><span class="Other">:</span> <span class="Other">[</span><span class="Other">]</span></span>.}</pre></dt>
<dd>
output an executable, library or object file. DO NOT call tcc_relocate() before.
<a href="https://github.com/nim-lang/Nim/tree/devel/lib/wrappers/tinyc.nim#L85" class="link-seesrc" target="_blank">Source</a>&nbsp;&nbsp;
<a href="https://github.com/nim-lang/Nim/edit/devel/lib/wrappers/tinyc.nim#L85" class="link-seesrc" target="_blank" >Edit</a>&nbsp;&nbsp;
</dd>
</div>
</div>
<div id="relocate-procs-all">
<div id="relocate,PccState,pointer">
<dt><pre><span class="Keyword">proc</span> <a href="#relocate%2CPccState%2Cpointer"><span class="Identifier">relocate</span></a><span class="Other">(</span><span class="Identifier">s</span><span class="Other">:</span> <a href="tinyc.html#PccState"><span class="Identifier">PccState</span></a><span class="Other">;</span> <span class="Identifier">p</span><span class="Other">:</span> <a href="system.html#pointer"><span class="Identifier">pointer</span></a><span class="Other">)</span><span class="Other">:</span> <a href="ctypes.html#cint"><span class="Identifier">cint</span></a> {.<span class="Identifier">cdecl</span><span class="Other">,</span> <span class="Identifier">importc</span><span class="Other">:</span> <span class="StringLit">&quot;tcc_relocate&quot;</span><span class="Other">,</span>
<span><span class="Other pragmadots">...</span></span><span class="pragmawrap"><span class="Identifier">raises</span><span class="Other">:</span> <span class="Other">[</span><span class="Other">]</span><span class="Other">,</span> <span class="Identifier">tags</span><span class="Other">:</span> <span class="Other">[</span><span class="Other">]</span><span class="Other">,</span> <span class="Identifier">forbids</span><span class="Other">:</span> <span class="Other">[</span><span class="Other">]</span></span>.}</pre></dt>
<dd>
copy code into memory passed in by the caller and do all relocations (needed before using tcc_get_symbol()). returns -1 on error and required size if ptr is NULL
<a href="https://github.com/nim-lang/Nim/tree/devel/lib/wrappers/tinyc.nim#L95" class="link-seesrc" target="_blank">Source</a>&nbsp;&nbsp;
<a href="https://github.com/nim-lang/Nim/edit/devel/lib/wrappers/tinyc.nim#L95" class="link-seesrc" target="_blank" >Edit</a>&nbsp;&nbsp;
</dd>
</div>
</div>
<div id="run-procs-all">
<div id="run,PccState,cint,cstringArray">
<dt><pre><span class="Keyword">proc</span> <a href="#run%2CPccState%2Ccint%2CcstringArray"><span class="Identifier">run</span></a><span class="Other">(</span><span class="Identifier">s</span><span class="Other">:</span> <a href="tinyc.html#PccState"><span class="Identifier">PccState</span></a><span class="Other">;</span> <span class="Identifier">argc</span><span class="Other">:</span> <a href="ctypes.html#cint"><span class="Identifier">cint</span></a><span class="Other">;</span> <span class="Identifier">argv</span><span class="Other">:</span> <a href="ctypes.html#cstringArray"><span class="Identifier">cstringArray</span></a><span class="Other">)</span><span class="Other">:</span> <a href="ctypes.html#cint"><span class="Identifier">cint</span></a> {.<span class="Identifier">cdecl</span><span class="Other">,</span>
<span class="Identifier">importc</span><span class="Other">:</span> <span class="StringLit">&quot;tcc_run&quot;</span><span class="Other">,</span> <span><span class="Other pragmadots">...</span></span><span class="pragmawrap"><span class="Identifier">raises</span><span class="Other">:</span> <span class="Other">[</span><span class="Other">]</span><span class="Other">,</span> <span class="Identifier">tags</span><span class="Other">:</span> <span class="Other">[</span><span class="Other">]</span><span class="Other">,</span> <span class="Identifier">forbids</span><span class="Other">:</span> <span class="Other">[</span><span class="Other">]</span></span>.}</pre></dt>
<dd>
link and run main() function and return its value. DO NOT call tcc_relocate() before.
<a href="https://github.com/nim-lang/Nim/tree/devel/lib/wrappers/tinyc.nim#L90" class="link-seesrc" target="_blank">Source</a>&nbsp;&nbsp;
<a href="https://github.com/nim-lang/Nim/edit/devel/lib/wrappers/tinyc.nim#L90" class="link-seesrc" target="_blank" >Edit</a>&nbsp;&nbsp;
</dd>
</div>
</div>
<div id="setErrorFunc-procs-all">
<div id="setErrorFunc,PccState,pointer,ErrorFunc">
<dt><pre><span class="Keyword">proc</span> <a href="#setErrorFunc%2CPccState%2Cpointer%2CErrorFunc"><span class="Identifier">setErrorFunc</span></a><span class="Other">(</span><span class="Identifier">s</span><span class="Other">:</span> <a href="tinyc.html#PccState"><span class="Identifier">PccState</span></a><span class="Other">;</span> <span class="Identifier">errorOpaque</span><span class="Other">:</span> <a href="system.html#pointer"><span class="Identifier">pointer</span></a><span class="Other">;</span> <span class="Identifier">errorFun</span><span class="Other">:</span> <a href="tinyc.html#ErrorFunc"><span class="Identifier">ErrorFunc</span></a><span class="Other">)</span> {.
<span class="Identifier">cdecl</span><span class="Other">,</span> <span class="Identifier">importc</span><span class="Other">:</span> <span class="StringLit">&quot;tcc_set_error_func&quot;</span><span class="Other">,</span> <span><span class="Other pragmadots">...</span></span><span class="pragmawrap"><span class="Identifier">raises</span><span class="Other">:</span> <span class="Other">[</span><span class="Other">]</span><span class="Other">,</span> <span class="Identifier">tags</span><span class="Other">:</span> <span class="Other">[</span><span class="Other">]</span><span class="Other">,</span> <span class="Identifier">forbids</span><span class="Other">:</span> <span class="Other">[</span><span class="Other">]</span></span>.}</pre></dt>
<dd>
set error/warning display callback
<a href="https://github.com/nim-lang/Nim/tree/devel/lib/wrappers/tinyc.nim#L22" class="link-seesrc" target="_blank">Source</a>&nbsp;&nbsp;
<a href="https://github.com/nim-lang/Nim/edit/devel/lib/wrappers/tinyc.nim#L22" class="link-seesrc" target="_blank" >Edit</a>&nbsp;&nbsp;
</dd>
</div>
</div>
<div id="setLibPath-procs-all">
<div id="setLibPath,PccState,cstring">
<dt><pre><span class="Keyword">proc</span> <a href="#setLibPath%2CPccState%2Ccstring"><span class="Identifier">setLibPath</span></a><span class="Other">(</span><span class="Identifier">s</span><span class="Other">:</span> <a href="tinyc.html#PccState"><span class="Identifier">PccState</span></a><span class="Other">;</span> <span class="Identifier">path</span><span class="Other">:</span> <a href="system.html#cstring"><span class="Identifier">cstring</span></a><span class="Other">)</span> {.<span class="Identifier">cdecl</span><span class="Other">,</span>
<span class="Identifier">importc</span><span class="Other">:</span> <span class="StringLit">&quot;tcc_set_lib_path&quot;</span><span class="Other">,</span> <span><span class="Other pragmadots">...</span></span><span class="pragmawrap"><span class="Identifier">raises</span><span class="Other">:</span> <span class="Other">[</span><span class="Other">]</span><span class="Other">,</span> <span class="Identifier">tags</span><span class="Other">:</span> <span class="Other">[</span><span class="Other">]</span><span class="Other">,</span> <span class="Identifier">forbids</span><span class="Other">:</span> <span class="Other">[</span><span class="Other">]</span></span>.}</pre></dt>
<dd>
set CONFIG_TCCDIR at runtime
<a href="https://github.com/nim-lang/Nim/tree/devel/lib/wrappers/tinyc.nim#L105" class="link-seesrc" target="_blank">Source</a>&nbsp;&nbsp;
<a href="https://github.com/nim-lang/Nim/edit/devel/lib/wrappers/tinyc.nim#L105" class="link-seesrc" target="_blank" >Edit</a>&nbsp;&nbsp;
</dd>
</div>
</div>
<div id="setOptions-procs-all">
<div id="setOptions,PccState,cstring">
<dt><pre><span class="Keyword">proc</span> <a href="#setOptions%2CPccState%2Ccstring"><span class="Identifier">setOptions</span></a><span class="Other">(</span><span class="Identifier">s</span><span class="Other">:</span> <a href="tinyc.html#PccState"><span class="Identifier">PccState</span></a><span class="Other">;</span> <span class="Identifier">options</span><span class="Other">:</span> <a href="system.html#cstring"><span class="Identifier">cstring</span></a><span class="Other">)</span> {.<span class="Identifier">cdecl</span><span class="Other">,</span>
<span class="Identifier">importc</span><span class="Other">:</span> <span class="StringLit">&quot;tcc_set_options&quot;</span><span class="Other">,</span> <span><span class="Other pragmadots">...</span></span><span class="pragmawrap"><span class="Identifier">raises</span><span class="Other">:</span> <span class="Other">[</span><span class="Other">]</span><span class="Other">,</span> <span class="Identifier">tags</span><span class="Other">:</span> <span class="Other">[</span><span class="Other">]</span><span class="Other">,</span> <span class="Identifier">forbids</span><span class="Other">:</span> <span class="Other">[</span><span class="Other">]</span></span>.}</pre></dt>
<dd>
set a options
<a href="https://github.com/nim-lang/Nim/tree/devel/lib/wrappers/tinyc.nim#L26" class="link-seesrc" target="_blank">Source</a>&nbsp;&nbsp;
<a href="https://github.com/nim-lang/Nim/edit/devel/lib/wrappers/tinyc.nim#L26" class="link-seesrc" target="_blank" >Edit</a>&nbsp;&nbsp;
</dd>
</div>
</div>
<div id="setOutputType-procs-all">
<div id="setOutputType,PccState,cint">
<dt><pre><span class="Keyword">proc</span> <a href="#setOutputType%2CPccState%2Ccint"><span class="Identifier">setOutputType</span></a><span class="Other">(</span><span class="Identifier">s</span><span class="Other">:</span> <a href="tinyc.html#PccState"><span class="Identifier">PccState</span></a><span class="Other">;</span> <span class="Identifier">outputType</span><span class="Other">:</span> <a href="ctypes.html#cint"><span class="Identifier">cint</span></a><span class="Other">)</span><span class="Other">:</span> <a href="ctypes.html#cint"><span class="Identifier">cint</span></a> {.<span class="Identifier">cdecl</span><span class="Other">,</span>
<span class="Identifier">importc</span><span class="Other">:</span> <span class="StringLit">&quot;tcc_set_output_type&quot;</span><span class="Other">,</span> <span><span class="Other pragmadots">...</span></span><span class="pragmawrap"><span class="Identifier">raises</span><span class="Other">:</span> <span class="Other">[</span><span class="Other">]</span><span class="Other">,</span> <span class="Identifier">tags</span><span class="Other">:</span> <span class="Other">[</span><span class="Other">]</span><span class="Other">,</span> <span class="Identifier">forbids</span><span class="Other">:</span> <span class="Other">[</span><span class="Other">]</span></span>.}</pre></dt>
<dd>
set output type. MUST BE CALLED before any compilation
<a href="https://github.com/nim-lang/Nim/tree/devel/lib/wrappers/tinyc.nim#L69" class="link-seesrc" target="_blank">Source</a>&nbsp;&nbsp;
<a href="https://github.com/nim-lang/Nim/edit/devel/lib/wrappers/tinyc.nim#L69" class="link-seesrc" target="_blank" >Edit</a>&nbsp;&nbsp;
</dd>
</div>
</div>
<div id="undefineSymbol-procs-all">
<div id="undefineSymbol,PccState,cstring">
<dt><pre><span class="Keyword">proc</span> <a href="#undefineSymbol%2CPccState%2Ccstring"><span class="Identifier">undefineSymbol</span></a><span class="Other">(</span><span class="Identifier">s</span><span class="Other">:</span> <a href="tinyc.html#PccState"><span class="Identifier">PccState</span></a><span class="Other">;</span> <span class="Identifier">sym</span><span class="Other">:</span> <a href="system.html#cstring"><span class="Identifier">cstring</span></a><span class="Other">)</span> {.<span class="Identifier">cdecl</span><span class="Other">,</span>
<span class="Identifier">importc</span><span class="Other">:</span> <span class="StringLit">&quot;tcc_undefine_symbol&quot;</span><span class="Other">,</span> <span><span class="Other pragmadots">...</span></span><span class="pragmawrap"><span class="Identifier">raises</span><span class="Other">:</span> <span class="Other">[</span><span class="Other">]</span><span class="Other">,</span> <span class="Identifier">tags</span><span class="Other">:</span> <span class="Other">[</span><span class="Other">]</span><span class="Other">,</span> <span class="Identifier">forbids</span><span class="Other">:</span> <span class="Other">[</span><span class="Other">]</span></span>.}</pre></dt>
<dd>
undefine preprocess symbol 'sym'
<a href="https://github.com/nim-lang/Nim/tree/devel/lib/wrappers/tinyc.nim#L43" class="link-seesrc" target="_blank">Source</a>&nbsp;&nbsp;
<a href="https://github.com/nim-lang/Nim/edit/devel/lib/wrappers/tinyc.nim#L43" class="link-seesrc" target="_blank" >Edit</a>&nbsp;&nbsp;
</dd>
</div>
</div>
</dl>
</div>
</div>
</div>
<div class="twelve-columns footer">
<span class="nim-sprite"></span>
<br>
<small style="color: var(--hint);">Made with Nim. Generated: 2025-12-28 15:55:34 UTC</small>
</div>
</div>
</div>
<script defer data-domain="nim-lang.org" src="https://plausible.io/js/plausible.js"></script>
</body>
</html>