#include <hunspell/hunspell.hxx>
#include <iostream>


int main() {
    // Initialize Hunspell with the dictionary files using the defined path
    const char* affFile = DICTIONARY_DIR "/en_US.aff"; // Path to the .aff file
    const char* dicFile = DICTIONARY_DIR "/en_US.dic"; // Path to the .dic file

    Hunspell spell (affFile, dicFile);

    std::cout << "Please enter one word:" << std::endl;
    std::string word;
    std::cin >> word;

    if (spell.spell(word.c_str()) == 0) {
            std::cout << "Spelling Error!";
    } else { 
            std::cout << "Correct Spelling!";
    }

    return 0;
}
