Date: Sun, 29 Dec 2013 09:22:07 -0800 From: Matthew Fleming <mdf@FreeBSD.org> To: Joe Nosay <superbisquit@gmail.com> Cc: FreeBSD Hackers <freebsd-hackers@freebsd.org> Subject: Re: template example Message-ID: <CAMBSHm9qu=Q6gkeHip7BwzyCYjzs8Dgkb3DBzP1-_iFDkMADzA@mail.gmail.com> In-Reply-To: <CA%2BWntOs8wae8eYk0nTjTRHExewgi5ymMD6a-pDuFcShvDrwb5Q@mail.gmail.com> References: <CA%2BWntOv-jWRUkZ6jqg3DLrt-RTAAGMtKb5FJC6A6rZ1bsk213Q@mail.gmail.com> <FF822AF7-F72D-47BE-9A36-737F928A6995@kientzle.com> <CA%2BWntOtLh_1UTHad85JTUGzZg_GN307Di788dxN7nscj%2B9qE6w@mail.gmail.com> <CA%2BWntOs8wae8eYk0nTjTRHExewgi5ymMD6a-pDuFcShvDrwb5Q@mail.gmail.com>
next in thread | previous in thread | raw e-mail | index | archive | help
On Sun, Dec 29, 2013 at 9:11 AM, Joe Nosay <superbisquit@gmail.com> wrote: > On Sat, Dec 28, 2013 at 10:44 PM, Joe Nosay <superbisquit@gmail.com> > wrote: > > > > > > > > > On Sat, Dec 28, 2013 at 3:52 AM, Tim Kientzle <tim@kientzle.com> wrote: > > > >> > >> On Dec 27, 2013, at 7:41 PM, Joe Nosay <superbisquit@gmail.com> wrote: > >> > >> > The standard "Hello World!" doesn't seem to work. > >> > >> Which one? Share the program you=92re trying to compile and what err= ors > >> you=92re seeing. > >> > >> Tim > >> > >> > >> > > > > Thanks @Alfred_Perlstein it worked with that example using clang > > -fsyntax-only h.cpp > > > > a.out is the file. > > > > > Trying a different approach with ::: > #include <iostream> > > #include <stdlib.h> > > int > main(int Argc, char **Argv) > { > int rv; > > rv =3D system("echo 'ls /tmp' " && " echo blee bble blle "); > If this is exactly what you compiled, that's the equivalent of: rv =3D system(1); The two strings count as "true" and && is logical and. I'd expect this to crash when running. Maybe you meant: rv =3D system("echo 'ls /tmp' && echo blee bble blle"); Cheers, matthew
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?CAMBSHm9qu=Q6gkeHip7BwzyCYjzs8Dgkb3DBzP1-_iFDkMADzA>