Skip to content

Commit

Permalink
PKG: Restructure headers into base and extension
Browse files Browse the repository at this point in the history
  • Loading branch information
RUrlus committed Oct 22, 2023
1 parent 781a631 commit dbdb662
Show file tree
Hide file tree
Showing 29 changed files with 2,379 additions and 1,570 deletions.
12 changes: 12 additions & 0 deletions include/carma
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
/* carma: Bidirectional coverter of Numpy arrays and Armadillo objects
* Copyright (c) 2023 Ralph Urlus <rurlus.dev@gmail.com>
* All rights reserved. Use of this source code is governed by a
* Apache-2.0 license that can be found in the LICENSE file.
*/
#pragma once

#include <carma_bits/config.hpp>
// config should be included first
#include <carma_bits/converter_types.hpp>
#include <carma_bits/converters.hpp>
#include <carma_bits/version.hpp>
98 changes: 0 additions & 98 deletions include/carma.hpp

This file was deleted.

194 changes: 0 additions & 194 deletions include/carma_bits/array_view.hpp

This file was deleted.

35 changes: 35 additions & 0 deletions include/carma_bits/base/config.hpp
Original file line number Diff line number Diff line change
@@ -0,0 +1,35 @@
#pragma once

#include <carma_bits/internal/converter_types.hpp>
#ifndef CARMA_DEFAULT_MEMORY_ORDER
#define CARMA_DEFAULT_MEMORY_ORDER carma::ColumnOrder
#endif // CARMA_DEFAULT_MEMORY_ORDER

#ifdef CARMA_EXTRA_DEBUG
#include <carma_bits/base/converter_types.hpp>
#include <carma_bits/version.hpp>
#include <iostream>

namespace carma {
namespace anon {
class carma_config_debug_message {
public:
inline carma_config_debug_message() {
std::cout << "\n|----------------------------------------------------------|\n"
<< "| CARMA CONFIGURATION |"
<< "\n|----------------------------------------------------------|\n|\n";
std::cout << "| Carma version: " + carma_version().as_string() << "\n";
std::cout << "| Carma mode: base\n|\n";
std::cout << "| Default Numpy to Arma conversion config:\n"
<< "| ----------------------------------------\n"
<< "| * l-value converter: " << CopyInConverter::name_ << "\n"
<< "| * const l-value converter: " << CopyInConverter::name_ << "\n"
<< "| * memory_order_policy: " << CARMA_DEFAULT_MEMORY_ORDER::name_ << "\n";
std::cout << "|\n|----------------------------------------------------------|\n\n";
};
};

static const carma_config_debug_message carma_config_debug_message_print;
} // namespace anon
} // namespace carma
#endif // CARMA_EXTRA_DEBUG
Loading

0 comments on commit dbdb662

Please sign in to comment.