<commit_before>#ifndef SOLAIRE_STRING_HPP
#define SOLAIRE_STRING_HPP

//Copyright 2015 <NAME>
//
//Licensed under the Apache License, Version 2.0 (the "License");
//you may not use this file except in compliance with the License.
//You may obtain a copy of the License at
//
//    http://www.apache.org/licenses/LICENSE-2.0
//
//Unless required by applicable law or agreed to in writing, software
//distributed under the License is distributed on an "AS IS" BASIS,
//WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
//See the License for the specific language governing permissions and
//limitations under the License.

// Contact :
// Email             : <EMAIL>
// GitHub repository : https://github.com/SolaireLibrary/SolaireCPP

/*!
	\file String.hpp
	\brief
	\author
	Created			: <NAME>
	Last modified	: <NAME>
	\date
	Created			: 10th December 2015
	Last Modified	: 15th January 2016
*/

#include "Solaire/Core/Container.hpp"

namespace Solaire {

    template<class T>
	using StringConstant = StaticContainer<T>;

    template<class T>
	SOLAIRE_EXPORT_INTERFACE String : public List<T> {
    public:
        SOLAIRE_EXPORT_CALL ~String() throw() {}

        template<size_t LENGTH>
        String<T>& operator+=(const T(&aString)[LENGTH]) throw() {
            for(int32_t i = 0; i < LENGTH; ++i) this->pushBack(aString[i]);
            return *this;
        };

        String<T>& operator+=(const T aValue) throw() {
            this->pushBack(aValue);
            return *this;
        };

        String<T>& operator+=(const StringConstant<T>& aString) throw() {
            const int32_t length = aString.size();
            for(int32_t i = 0; i < length; ++i) this->pushBack(aString[i]);
            return *this;
        };

        String<T>& operator+=(int8_t aValue) throw() {
            return operator+=(static_cast<int32_t>(aValue));
        };

        String<T>& operator+=(int16_t aValue) throw() {
            return operator+=(static_cast<int32_t>(aValue));
        };

        String<T>& operator+=(int32_t aValue) throw() {
            char buf[32];
            int i = 30;
            for(i; aValue && i ; --i, aValue /= 10) buf[i] = "0123456789abcdef"[aValue % 10];
            for(i; i <= 30; ++i) this->pushBack(buf[i]);
            return *this;
        };

        String<T>& operator+=(int64_t aValue) throw() {
            //! \bug Values outside range of int32_t are lost
            return operator+=(static_cast<int32_t>(aValue));
        };

        String<T>& operator+=(uint8_t aValue) throw() {
            return operator+=(static_cast<int32_t>(aValue));
        };

        String<T>& operator+=(uint16_t aValue) throw() {
            return operator+=(static_cast<int32_t>(aValue));
        };

        String<T>& operator+=(uint32_t aValue) throw() {
            //! \bug Values outside range of int32_t are lost
            return operator+=(static_cast<int32_t>(aValue));
        };

        String<T>& operator+=(uint64_t aValue) throw() {
            //! \bug Values outside range of int32_t are lost
            return operator+=(static_cast<int32_t>(aValue));
        };

	};
<commit_msg>Added functionality to int to string conversion<commit_after>#ifndef SOLAIRE_STRING_HPP
#define SOLAIRE_STRING_HPP

//Copyright 2015 <NAME>
//
//Licensed under the Apache License, Version 2.0 (the "License");
//you may not use this file except in compliance with the License.
//You may obtain a copy of the License at
//
//    http://www.apache.org/licenses/LICENSE-2.0
//
//Unless required by applicable law or agreed to in writing, software
//distributed under the License is distributed on an "AS IS" BASIS,
//WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
//See the License for the specific language governing permissions and
//limitations under the License.

// Contact :
// Email             : <EMAIL>
// GitHub repository : https://github.com/SolaireLibrary/SolaireCPP

/*!
	\file String.hpp
	\brief
	\author
	Created			: <NAME>
	Last modified	: <NAME>
	\date
	Created			: 10th December 2015
	Last Modified	: 15th January 2016
*/

#include "Solaire/Core/Container.hpp"

namespace Solaire {

    template<class T>
	using StringConstant = StaticContainer<T>;

	namespace Implementation {
        static constexpr char STRING_NUMERIC_CHARS[] = "0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZ";
	}

    template<class T>
	SOLAIRE_EXPORT_INTERFACE String : public List<T> {
    public:
        SOLAIRE_EXPORT_CALL ~String() throw() {}

        template<size_t LENGTH>
        String<T>& operator+=(const T(&aString)[LENGTH]) throw() {
            for(int32_t i = 0; i < LENGTH; ++i) this->pushBack(aString[i]);
            return *this;
        };

        String<T>& operator+=(const T aValue) throw() {
            this->pushBack(aValue);
            return *this;
        };

        String<T>& operator+=(const StringConstant<T>& aString) throw() {
            const int32_t length = aString.size();
            for(int32_t i = 0; i < length; ++i) this->pushBack(aString[i]);
            return *this;
        };

        String<T>& operator+=(int8_t aValue) throw() {
            return operator+=(static_cast<uint32_t>(aValue));
        };

        String<T>& operator+=(int16_t aValue) throw() {
            return operator+=(static_cast<uint32_t>(aValue));
        };

        String<T>& operator+=(int32_t aValue) throw() {
            //! \bug Values outside range of uint32_t are lost
            return operator+=(static_cast<uint32_t>(aValue));
        };

        String<T>& operator+=(int64_t aValue) throw() {
            //! \bug Values outside range of uint32_t are lost
            return operator+=(static_cast<uint32_t>(aValue));
        };

        String<T>& operator+=(uint8_t aValue) throw() {
            return operator+=(static_cast<uint32_t>(aValue));
        };

        String<T>& operator+=(uint16_t aValue) throw() {
            return operator+=(static_cast<uint32_t>(aValue));
        };

        template<const uint32_t BASE = 10, const char* CHARACTERS = Implementation::STRING_NUMERIC_CHARS>
        String<T>& operator+=(uint32_t aValue) throw() {
            char buf[32];
            uint32_t i = 30;
            for(i; aValue && i ; --i, aValue /= BASE) buf[i] = CHARACTERS[aValue % BASE];
            for(i; i <= 30; ++i) this->pushBack(buf[i]);
            return *this;
        }

        String<T>& operator+=(uint64_t aValue) throw() {
            //! \bug Values outside range of uint32_t are lost
            return operator+=(static_cast<uint32_t>(aValue));
        };

	};

{'fraction_non_alphanumeric': 0.1309217496594521, 'fraction_numerical': 0.0251248675647041, 'mean_word_length': 2.52991452991453, 'pattern_counts': {'":': 0, '<': 66, '<?xml version=': 0, '>': 68, 'https://': 2, 'lorem ipsum': 0, 'www.': 2, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '2951721', 'n_tokens_mistral': 2186, 'n_tokens_neox': 2001, 'n_words': 543}