uni

University stuff
git clone git://git.christosmarg.xyz/uni-assignments.git
Log | Files | Refs | README | LICENSE

commit 4e68566c991af6d3891351aa68fb8f387ce1f7f8
parent 25833cc23feb2b216114abd719e6487d6a8172ba
Author: Christos Margiolis <christos@margiolis.net>
Date:   Mon,  8 Jun 2020 20:22:32 +0300

minor changes

Diffstat:
Massignment-2.2-classes/classes.cpp | 2+-
Massignment-2.3-operoverloading/src/student.hpp | 2+-
Massignment-2.4-inheritance/bin/inheritance | 0
Massignment-2.4-inheritance/obj/app.o | 0
Massignment-2.4-inheritance/obj/appsystem.o | 0
Massignment-2.4-inheritance/obj/errlog.o | 0
Massignment-2.4-inheritance/obj/game.o | 0
Massignment-2.4-inheritance/obj/main.o | 0
Massignment-2.4-inheritance/obj/manufacturer.o | 0
Massignment-2.4-inheritance/obj/review.o | 0
Massignment-2.4-inheritance/src/appsystem.hpp | 8++++----
Massignment-2.4-inheritance/src/errlog.cpp | 2+-
Massignment-2.4-inheritance/src/errlog.hpp | 2+-
Massignment-2.5-spreadsheets/bin/spreadsheets | 0
Massignment-2.5-spreadsheets/obj/datahandler.o | 0
Massignment-2.5-spreadsheets/obj/errlog.o | 0
Massignment-2.5-spreadsheets/obj/main.o | 0
Massignment-2.5-spreadsheets/obj/xstring.o | 0
18 files changed, 8 insertions(+), 8 deletions(-)

diff --git a/assignment-2.2-classes/classes.cpp b/assignment-2.2-classes/classes.cpp @@ -82,7 +82,7 @@ Student::get_name() const } /* - * The function below are marked as constexpr just so they + * The functions below are marked as constexpr just so they * can be computed at compile time since everything is hardcoded. */ constexpr const char * diff --git a/assignment-2.3-operoverloading/src/student.hpp b/assignment-2.3-operoverloading/src/student.hpp @@ -33,7 +33,7 @@ class Student Student operator= (const Student& s); /* - * The function below are marked as constexpr just so they + * The functions below are marked as constexpr just so they * can be computed at compile time since everything is hardcoded. */ constexpr bool operator== (const Student& s) const {return this->semester == s.semester;} diff --git a/assignment-2.4-inheritance/bin/inheritance b/assignment-2.4-inheritance/bin/inheritance Binary files differ. diff --git a/assignment-2.4-inheritance/obj/app.o b/assignment-2.4-inheritance/obj/app.o Binary files differ. diff --git a/assignment-2.4-inheritance/obj/appsystem.o b/assignment-2.4-inheritance/obj/appsystem.o Binary files differ. diff --git a/assignment-2.4-inheritance/obj/errlog.o b/assignment-2.4-inheritance/obj/errlog.o Binary files differ. diff --git a/assignment-2.4-inheritance/obj/game.o b/assignment-2.4-inheritance/obj/game.o Binary files differ. diff --git a/assignment-2.4-inheritance/obj/main.o b/assignment-2.4-inheritance/obj/main.o Binary files differ. diff --git a/assignment-2.4-inheritance/obj/manufacturer.o b/assignment-2.4-inheritance/obj/manufacturer.o Binary files differ. diff --git a/assignment-2.4-inheritance/obj/review.o b/assignment-2.4-inheritance/obj/review.o Binary files differ. diff --git a/assignment-2.4-inheritance/src/appsystem.hpp b/assignment-2.4-inheritance/src/appsystem.hpp @@ -27,11 +27,11 @@ class AppSystem template<typename T> void import_data(const char *fpath); template<typename T> void export_data(const char *fpath); template<typename T> void call( - const std::string& appname, + std::string&& appname, const T element, void (App::*setter)(T)); template<typename T, class U> void cast_call( - const std::string& appname, + std::string&& appname, const T element, void (U::*setter)(T)); void removebad(const Manufacturer *manf); @@ -270,7 +270,7 @@ AppSystem::exists(const std::vector<T *>& vec, const T *element) * It's ugly. */ template<typename T> void -AppSystem::call(const std::string& appname, const T element, void (App::*setter)(T)) +AppSystem::call(std::string&& appname, const T element, void (App::*setter)(T)) { for (auto&& app : apps) if (app->get_name() == appname) @@ -283,7 +283,7 @@ AppSystem::call(const std::string& appname, const T element, void (App::*setter) * dynamic casting everytime would be pointless. */ template<typename T, class U> void -AppSystem::cast_call(const std::string& appname, const T element, void (U::*setter)(T)) +AppSystem::cast_call(std::string&& appname, const T element, void (U::*setter)(T)) { for (auto&& app : apps) if (U *o = dynamic_cast<U *>(app)) diff --git a/assignment-2.4-inheritance/src/errlog.cpp b/assignment-2.4-inheritance/src/errlog.cpp @@ -9,7 +9,7 @@ ErrLog::fclear() const } void -ErrLog::write(const std::string& str) const +ErrLog::write(std::string&& str) const { std::ofstream f; f.open(fpath, std::ios_base::app); diff --git a/assignment-2.4-inheritance/src/errlog.hpp b/assignment-2.4-inheritance/src/errlog.hpp @@ -13,7 +13,7 @@ class ErrLog ErrLog() = default; void fclear() const; - void write(const std::string& str) const; + void write(std::string&& str) const; }; #endif /* ERRLOG_HPP */ diff --git a/assignment-2.5-spreadsheets/bin/spreadsheets b/assignment-2.5-spreadsheets/bin/spreadsheets Binary files differ. diff --git a/assignment-2.5-spreadsheets/obj/datahandler.o b/assignment-2.5-spreadsheets/obj/datahandler.o Binary files differ. diff --git a/assignment-2.5-spreadsheets/obj/errlog.o b/assignment-2.5-spreadsheets/obj/errlog.o Binary files differ. diff --git a/assignment-2.5-spreadsheets/obj/main.o b/assignment-2.5-spreadsheets/obj/main.o Binary files differ. diff --git a/assignment-2.5-spreadsheets/obj/xstring.o b/assignment-2.5-spreadsheets/obj/xstring.o Binary files differ.