
JSCPP, a simple C++ interpreter written in JavaScript - turrini
https://github.com/felixhao28/JSCPP
======
blueline
also relevant is cling, made by the folks at CERN

[https://github.com/root-project/cling](https://github.com/root-project/cling)

[https://root.cern.ch/cling](https://root.cern.ch/cling)

~~~
mortdeus
this is neat. I noticed that with this we get Read–eval–print loop for C++.
Which would make it really useful in an ide like light table.

------
Areading314
A similar project, also good for educating but within a jupyter notebook for
c++

[https://github.com/QuantStack/xeus-cling](https://github.com/QuantStack/xeus-
cling)

------
omegote
* A subset of C++.

~~~
ashleyn
I was going to say, "Jesus Christ did one guy actually manage to write a fully
standards-conformant C++ parser?"

~~~
userbinator
I know of one guy who did, as well as inventing the D language, and he also
visits HN and posts semi-regularly ---
[http://walterbright.com/](http://walterbright.com/)

------
mulle_nat
A _simple_ C++ interpreter is an oxymoron.

~~~
tntn
It's c++ without the "object-oriented features," so that could be fairly
simple.

~~~
userbinator
That's called C.

~~~
hellofunk
C is C++ minus object-oriented features, increased type-safety, template meta-
programming, lambdas, and many more features.

~~~
hossbeast
Right, the useless cruft that makes your program impossible to read, let alone
reason about

~~~
goatlover
Is this the cruft that gets reinvented in C whenever the project grows complex
enough?

Something like: any sufficiently complicated C program contains an ad-hoc,
informally-specified, bug-ridden, slow implementation of half of C++'s
features.

------
blt
Couldn't find in readme if templates are supported.

~~~
FartyMcFarter
It doesn't even support structs/classes.

edit: Templated functions don't work either.

------
wemdyjreichert
But why? Most js engines (or at least V8) are written in c++.

