Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Markdown code blocks part 2; migrate Nim Manual #20080

Merged
merged 2 commits into from
Jul 25, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 4 additions & 8 deletions doc/backends.md
Original file line number Diff line number Diff line change
Expand Up @@ -155,8 +155,7 @@ To wrap native code, take a look at the `c2nim tool <https://github.com/nim-lang
with the process of scanning and transforming header files into a Nim
interface.

C invocation example
~~~~~~~~~~~~~~~~~~~~
### C invocation example

Create a ``logic.c`` file with the following content:

Expand Down Expand Up @@ -194,8 +193,7 @@ could as well pass ``logic.o``) we could be passing switches to link any other
static C library.


JavaScript invocation example
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
### JavaScript invocation example

Create a ``host.html`` file with the following content:

Expand Down Expand Up @@ -251,8 +249,7 @@ The name `NimMain` can be influenced via the `--nimMainPrefix:prefix` switch.
Use `--nimMainPrefix:MyLib` and the function to call is named `MyLibNimMain`.


Nim invocation example from C
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
### Nim invocation example from C

Create a ``fib.nim`` file with the following content:

Expand Down Expand Up @@ -312,8 +309,7 @@ vary for each system. For instance, on Linux systems you will likely need to
use `-ldl`:option: too to link in required dlopen functionality.


Nim invocation example from JavaScript
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
### Nim invocation example from JavaScript

Create a ``mhost.html`` file with the following content:

Expand Down
Loading