Clang: Difference between revisions
From wikinotes
(→Usage) |
No edit summary |
||
Line 7: | Line 7: | ||
clang example.c -o example_program | clang example.c -o example_program | ||
</syntaxhighlight> | </syntaxhighlight> | ||
= Debugger = | |||
<blockquote> | |||
See [[lldb]]. | |||
<syntaxhighlight lang="bash"> | |||
lldb python -- -c 'print("hi")' | |||
</syntaxhighlight> | |||
</blockquote><!-- Debugger --> |
Revision as of 01:04, 31 August 2021
Usage
## compile c++11 program
clang++ -std=c++11 -stdlib=libc++ example.cpp -o example_program
## compile c program
clang example.c -o example_program
Debugger
See lldb.
lldb python -- -c 'print("hi")'