summaryrefslogtreecommitdiffhomepage
diff options
context:
space:
mode:
-rw-r--r--src/CompilerKit/src/CodeGenerator+AssemblyFactory.cpp4
-rw-r--r--src/CompilerKit/src/Linkers/DynamicLinker64+PEF.cpp1
-rw-r--r--src/CompilerKit/src/Preprocessors/Preprocessor+Generic.cpp6
-rw-r--r--src/CompilerKit/test/Linkers/DynamicLinker64+MachO.test.cpp (renamed from src/CompilerKit/test/Linkers/DynamicLinker64+MachO.test.cc)0
-rw-r--r--src/CompilerKit/test/Linkers/DynamicLinker64+PEF.test.cpp (renamed from src/CompilerKit/test/Linkers/DynamicLinker64+PEF.test.cc)0
-rw-r--r--src/CompilerKit/test/Linkers/ck-linker-test-osx-posix.json2
-rw-r--r--src/CompilerKit/test/Linkers/ck-linker-test-pef-posix.json2
7 files changed, 7 insertions, 8 deletions
diff --git a/src/CompilerKit/src/CodeGenerator+AssemblyFactory.cpp b/src/CompilerKit/src/CodeGenerator+AssemblyFactory.cpp
index 2c5fde8..a2417ae 100644
--- a/src/CompilerKit/src/CodeGenerator+AssemblyFactory.cpp
+++ b/src/CompilerKit/src/CodeGenerator+AssemblyFactory.cpp
@@ -17,7 +17,7 @@
namespace CompilerKit {
///! @brief Compile for specific format (ELF, PEF, AE)
Int32 AssemblyFactory::Compile(STLString sourceFile, const Int32& arch) {
- if (sourceFile.length() < 1) return NECTAR_UNIMPLEMENTED;
+ if (sourceFile.length() == 0) return NECTAR_UNIMPLEMENTED;
if (!this->fMounted) return NECTAR_UNIMPLEMENTED;
if (arch != this->fMounted->Arch()) return NECTAR_INVALID_ARCH;
@@ -27,7 +27,7 @@ Int32 AssemblyFactory::Compile(STLString sourceFile, const Int32& arch) {
///! @brief mount assembly backend.
void AssemblyFactory::Mount(WeakRef<IAssembly> mount_ptr) {
- if (mount_ptr && !this->fMounted) {
+ if (mount_ptr.Leak() && !this->fMounted) {
this->fMounted = mount_ptr.Leak();
}
}
diff --git a/src/CompilerKit/src/Linkers/DynamicLinker64+PEF.cpp b/src/CompilerKit/src/Linkers/DynamicLinker64+PEF.cpp
index 476c7f7..c48bdb2 100644
--- a/src/CompilerKit/src/Linkers/DynamicLinker64+PEF.cpp
+++ b/src/CompilerKit/src/Linkers/DynamicLinker64+PEF.cpp
@@ -147,7 +147,6 @@ NECTAR_MODULE(DynamicLinker64PEF) {
kOutput.erase(kOutput.find(kPefExt), strlen(kPefExt));
kOutput += kPefDylibExt;
-
is_executable = false;
continue;
diff --git a/src/CompilerKit/src/Preprocessors/Preprocessor+Generic.cpp b/src/CompilerKit/src/Preprocessors/Preprocessor+Generic.cpp
index 49c2145..47df994 100644
--- a/src/CompilerKit/src/Preprocessors/Preprocessor+Generic.cpp
+++ b/src/CompilerKit/src/Preprocessors/Preprocessor+Generic.cpp
@@ -17,11 +17,11 @@
#define kMacroPrefix '#'
/// @author Amlal El Mahrouss (amlal@nekernel.org)
-/// @file Preprocessor+Generic.cc
+/// @file Preprocessor+Generic.cpp
/// @brief Nectar Preprocessor.
-typedef Int32 (*pp_parser_fn_t)(CompilerKit::STLString& line, std::ifstream& hdr_file,
- std::ofstream& pp_out);
+using pp_parser_fn_t = Int32 (*)(CompilerKit::STLString&, std::ifstream&,
+ std::ofstream&);
/////////////////////////////////////////////////////////////////////////////////////////
diff --git a/src/CompilerKit/test/Linkers/DynamicLinker64+MachO.test.cc b/src/CompilerKit/test/Linkers/DynamicLinker64+MachO.test.cpp
index f73d6fd..f73d6fd 100644
--- a/src/CompilerKit/test/Linkers/DynamicLinker64+MachO.test.cc
+++ b/src/CompilerKit/test/Linkers/DynamicLinker64+MachO.test.cpp
diff --git a/src/CompilerKit/test/Linkers/DynamicLinker64+PEF.test.cc b/src/CompilerKit/test/Linkers/DynamicLinker64+PEF.test.cpp
index 6c4d061..6c4d061 100644
--- a/src/CompilerKit/test/Linkers/DynamicLinker64+PEF.test.cc
+++ b/src/CompilerKit/test/Linkers/DynamicLinker64+PEF.test.cpp
diff --git a/src/CompilerKit/test/Linkers/ck-linker-test-osx-posix.json b/src/CompilerKit/test/Linkers/ck-linker-test-osx-posix.json
index 0f197d1..9c8578e 100644
--- a/src/CompilerKit/test/Linkers/ck-linker-test-osx-posix.json
+++ b/src/CompilerKit/test/Linkers/ck-linker-test-osx-posix.json
@@ -9,7 +9,7 @@
"/usr/include/"
],
"sources_path": [
- "DynamicLinker64+MachO.test.cc"
+ "DynamicLinker64+MachO.test.cpp"
],
"output_name": "LinkerTest.o",
"compiler_flags": [
diff --git a/src/CompilerKit/test/Linkers/ck-linker-test-pef-posix.json b/src/CompilerKit/test/Linkers/ck-linker-test-pef-posix.json
index 97e8604..1692e51 100644
--- a/src/CompilerKit/test/Linkers/ck-linker-test-pef-posix.json
+++ b/src/CompilerKit/test/Linkers/ck-linker-test-pef-posix.json
@@ -9,7 +9,7 @@
"/usr/include/"
],
"sources_path": [
- "DynamicLinker64+PEF64.test.cc"
+ "DynamicLinker64+PEF.test.cpp"
],
"output_name": "LinkerTest.o",
"compiler_flags": [