orosmatthew / hydrogen-cpp Goto Github PK
View Code? Open in Web Editor NEWA hobby programming language 🔥
License: MIT License
A hobby programming language 🔥
License: MIT License
I feel it'd probably be best because it will help when / if you add more functions (other than exit()
)
Loving the videos!
To show a very simple example:
Error message is "[Parse Error] Expected ;
on line 2" even tho the error is on line 4
when are we getting a new video, since the video rate of this series is very slow?
**let x = 1;
let y = x + 3;
if (x - 1) {
exit(1);
} elif (x - 1) {
exit(2);
}
exit(y);**
Program crashes in this example. Fixed by adding an empty else statement, but appears to have something to do with label mismatching.
When trying to compile the latest source, I get the following compiler error. I'm using WSL with Arch Linux on Windows 11.
[ 50%] Building CXX object CMakeFiles/hydro.dir/src/main.cpp.o
In file included from /mnt/c/Users/Gabriel/Documents/GitHub/hydrogen-cpp/src/main.cpp:7:
/mnt/c/Users/Gabriel/Documents/GitHub/hydrogen-cpp/src/./generation.hpp: In member function ‘void Generator::gen_term(const NodeTerm*)::TermVisitor::operator()(const NodeTermIdent*) const’:
/mnt/c/Users/Gabriel/Documents/GitHub/hydrogen-cpp/src/./generation.hpp:24:32: error: ‘find_if’ is not a member of ‘std’; did you mean ‘find’?
24 | auto it = std::find_if(gen.m_vars.cbegin(), gen.m_vars.cend(), [&](const Var& var) {
| ^~~~~~~
| find
/mnt/c/Users/Gabriel/Documents/GitHub/hydrogen-cpp/src/./generation.hpp: In member function ‘void Generator::gen_stmt(const NodeStmt*)::StmtVisitor::operator()(const NodeStmtLet*) const’:
/mnt/c/Users/Gabriel/Documents/GitHub/hydrogen-cpp/src/./generation.hpp:130:32: error: ‘find_if’ is not a member of ‘st ’; did you mean ‘find’?
130 | auto it = std::find_if(gen.m_vars.cbegin(), gen.m_vars.cend(), [&](const Var& var) {
| ^~~~~~~
| find
make[2]: *** [CMakeFiles/hydro.dir/build.make:76: CMakeFiles/hydro.dir/src/main.cpp.o] Error 1
make[1]: *** [CMakeFiles/Makefile2:83: CMakeFiles/hydro.dir/all] Error 2
make: *** [Makefile:91: all] Error 2
I haven't tried using older source code so far.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.