On Tue, Jun 2, 2009 at 10:33 AM, Sylvain Pointeau <sylvain.point...@gmail.com> wrote: > I didn't mean to program with sqlite in C++ ... > I just meant to introduce C++ inside SQLite instead of C... > I would like to understand why SQLite is programmed only in C ....
Definitively only DRH can answer. My speculation is -- because ANSI standard C is the cleanest, most portable language across all the variety of hardware/OS platforms to which SQLite is ported. It works, fast, quick, cheap as is evident by, well, by evidence. Why bother with something more complex, as unnecessary complexity is a sure recipe for disaster. > > Cheers, > Sylvain > > On Tue, Jun 2, 2009 at 5:15 PM, <logan.rat...@emerson.com> wrote: > >> One of the best and worst things about C++ is its ability to use C code >> (almost) transparently. Best because it allows you to use things like >> SQLite seamlessly in your C++ code. Worst because it allows some >> programming idioms that are in opposition to good object oriented >> design. But let's concentrate on the up-side. >> >> There are C++ wrappers to SQLite out there if you care to look for them, >> but depending upon the complexity of your application you may find you >> don't need them. It is easy to contain a SQLite connection inside a >> class object, easy to compose your queries in a std::string (or a >> CString depending on your environment and preferences) and fairly easy >> to get your query results into a container class. >> >> While I would never dream of starting from scratch on anything of the >> size and complexity of SQLite without C++, the STL, and probably Boost, >> I also would never advocate fixing something that ain't broke. As an >> applications programmer you can get all the advantages of C++ without >> any changes to SQLite as written. >> >> Just my $0.02 worth. >> >> Logan Ratner | Software Engineer | Gas Chromatographs >> Emerson Process Management | 5650 Brittmoore | Houston | TX | 77041 | >> USA >> T +1 713 839 9656 | F +1 713 827 3807 >> >> >> logan.rat...@emerson.com-----original Message----- >> From: sqlite-users-boun...@sqlite.org >> [mailto:sqlite-users-boun...@sqlite.org] On Behalf Of Sylvain Pointeau >> Sent: Tuesday, June 02, 2009 9:58 AM >> To: sqlite-users@sqlite.org >> Subject: [sqlite] sqlite programmed in C++ >> >> Hello, >> I would like to know if someone already though about to introduce C++ in >> SQLite? >> I just think about a minimal subset of C++ that will not make any >> performance penalty >> (like C with classes) >> >> is it a performance issue? >> is it a deployment/compiler issue? >> or any issue? >> >> Please don't make any aggressive reply, I am a very nice guy :-) >> >> Cheers, >> Sylvain >> _______________________________________________ >> sqlite-users mailing list >> sqlite-users@sqlite.org >> http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users >> _______________________________________________ >> sqlite-users mailing list >> sqlite-users@sqlite.org >> http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users >> > _______________________________________________ > sqlite-users mailing list > sqlite-users@sqlite.org > http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users > -- Puneet Kishor _______________________________________________ sqlite-users mailing list sqlite-users@sqlite.org http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users