support C
This commit is contained in:
+7
-5
@@ -3,11 +3,13 @@
|
||||
int main()
|
||||
{
|
||||
int* x;
|
||||
void* y;
|
||||
x = y;
|
||||
void* y = 0;
|
||||
|
||||
x = y; /* should only work on C */
|
||||
if(x == 0)
|
||||
{
|
||||
printf("C compilation OK!\n");
|
||||
}
|
||||
|
||||
char s[16];
|
||||
scanf("%s", s);
|
||||
printf("%s\n", s);
|
||||
return 0;
|
||||
}
|
||||
|
||||
@@ -1,3 +1,5 @@
|
||||
// Test cppipe functions
|
||||
|
||||
#include <cppipe/commands.hpp>
|
||||
|
||||
#include <sys/wait.h>
|
||||
@@ -26,7 +28,10 @@ int main(int argc, char* argv[])
|
||||
|
||||
string out2 = $(echo + "abc" + "def");
|
||||
if(auto len = out2.size(); len != 8)
|
||||
{
|
||||
cerr << "FAILURE: unexpected output length " << len << endl;
|
||||
exit(1);
|
||||
}
|
||||
|
||||
Cmd success("echo", "OK 1/11");
|
||||
Cmd fail("mkdir", ".");
|
||||
Reference in New Issue
Block a user