diff --git a/.github/workflows/c-cpp.yml b/.github/workflows/c-cpp.yml index 44e699a..e92d96e 100644 --- a/.github/workflows/c-cpp.yml +++ b/.github/workflows/c-cpp.yml @@ -2,7 +2,7 @@ name: C/C++ CI on: push: - branches: [ "development" ] + branches: [ "development", "master" ] pull_request: branches: [ "development", "master" ] workflow_dispatch: diff --git a/src/identifiers/output.hpp b/src/identifiers/output.hpp index bc48a2a..985d1c7 100644 --- a/src/identifiers/output.hpp +++ b/src/identifiers/output.hpp @@ -10,14 +10,14 @@ void output(vector::iterator it, ifstream &file) { } // If the next token is a string, print the string else { - string result = string(_this.substr(1, strlen(_this.c_str()) - 2)); - // Replace underscores with spaces - for (int i = 0; i <= result.size(); i++) { - if (result[i] == '_') { - cout << ' '; - continue; + string result = _this; + for (int index = 2; ; index++) { + if (result[result.length() - 1] == '"') { + cout << result.substr(1, result.length() - 2); + return; } - cout << result[i]; + string __this = *(it + index); + result += (" " + __this); } } } \ No newline at end of file diff --git a/src/init.hpp b/src/init.hpp index 929f061..306dce4 100644 --- a/src/init.hpp +++ b/src/init.hpp @@ -16,7 +16,7 @@ using namespace std; #pragma GCC std("c++11") // Version of the program -const string _VERSION_ = "b1.15.00"; +const string _VERSION_ = "v1.16.00"; // Buffer size const int _BUFFER_SIZE_ = 1024; // split function diff --git a/src/update.hpp b/src/update.hpp index 490b9cf..5ce968e 100644 --- a/src/update.hpp +++ b/src/update.hpp @@ -27,8 +27,8 @@ string execute(const char *command) { // update function void update() { // get version number from https://junlang.imjcj.eu.org/VERSION - string result = execute("curl -s https://junlang.imjcj.eu.org/VERSION_DEVE"); - result = result.substr(49); + string result = execute("curl -s https://junlang.imjcj.eu.org/VERSION"); + result = result.substr(44); // compare version number with _VERSION_ if (result != _VERSION_) { cout << "Warning: Please update: \"https://junlang.imjcj.eu.org\"" << endl; diff --git a/tests/test1/test.jun b/tests/test1/test.jun index 47ccf7d..e5a088d 100644 --- a/tests/test1/test.jun +++ b/tests/test1/test.jun @@ -1,7 +1,7 @@ -output "Hello_world!" -output "Hello_world!" +output "Hello world!" +output "Hello world!" wrap -output "Hello_world!" +output "Hello world!" set a 50 set a 50 output a