#include<iostream>
#include<cstdlib>
#include<cstring>
#include<cstdio>
using namespace std;
class Book{
public:
int a;
int b;
};
int main()
{
Book b1;
b1.a = 10;
b1.b = 20;
cout<< b1.a << " " <<b1.b;
}
when we compile the above code with
clang++ test.cc -o a.exe
and run a.exe perfectly. But when we compile the same program with
clang++ test.cc -emit-llvm -S -o a.exe
and now, when we launch it, the program is going crazy, having started ntvdm.exe(you can see it in the process explorer), and the command line starts to behave strangely.
Software Stack:
clang version 2.9 (tags/RELEASE_29/final)
Target: i386-pc-mingw32
Thread model: posix
source
share