mirror of
https://github.com/usatiuk/ficus.git
synced 2025-10-29 00:27:52 +01:00
c++ is cool but the libs are 10MB
This commit is contained in:
@@ -5,5 +5,5 @@ target_link_libraries(init syscalls_interface)
|
||||
|
||||
target_include_directories(init PRIVATE ${CMAKE_CURRENT_SOURCE_DIR})
|
||||
|
||||
add_executable(hello2 hello2.cpp)
|
||||
add_executable(hello2 hello2.c)
|
||||
|
||||
|
||||
6
src/test/hello2.c
Normal file
6
src/test/hello2.c
Normal file
@@ -0,0 +1,6 @@
|
||||
#include <stdio.h>
|
||||
|
||||
|
||||
int main() {
|
||||
printf("Hi!\n");
|
||||
}
|
||||
@@ -1,18 +0,0 @@
|
||||
#include <iostream>
|
||||
|
||||
void badfn() {
|
||||
throw std::runtime_error("oops");
|
||||
}
|
||||
|
||||
int main() {
|
||||
std::cout << "hi" << std::endl;
|
||||
try {
|
||||
std::cout << "try" << std::endl;
|
||||
badfn();
|
||||
std::cout << "ok" << std::endl;
|
||||
} catch (std::exception &e) {
|
||||
std::cout << "huh" << std::endl;
|
||||
std::cout << e.what() << std::endl;
|
||||
}
|
||||
std::cout << "fin" << std::endl;
|
||||
}
|
||||
Reference in New Issue
Block a user