Ignore:
Timestamp:
Jul 20, 2015, 3:43:57 PM (4 years ago)
Author:
nmedfort
Message:

Added optional CMake command -DDISABLE_PREGENERATED_UCD_FUNCTIONS.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • icGREP/icgrep-devel/icgrep/re/re_compiler.cpp

    r4685 r4686  
    2222#include <pablo/codegenstate.h>
    2323#include <UCD/ucd_compiler.hpp>
     24#include <UCD/resolve_properties.h>
     25#ifndef DISABLE_PREGENERATED_UCD_FUNCTIONS
    2426#include <UCD/precompiled_properties.h>
    25 #include <UCD/resolve_properties.h>
     27#endif
    2628#include <assert.h>
    2729#include <stdexcept>
     
    4042static cl::opt<bool> DisableUnicodeLineBreak("disable-unicode-linebreak", cl::init(false),
    4143                     cl::desc("disable Unicode line breaks - use LF only"), cl::cat(fREcompilationOptions));
     44#ifndef DISABLE_PREGENERATED_UCD_FUNCTIONS
    4245static cl::opt<bool> DisablePregeneratedUnicode("disable-pregenerated-unicode", cl::init(false),
    4346                     cl::desc("disable use of pregenerated Unicode character class sets"), cl::cat(fREcompilationOptions));
     47#endif
    4448using namespace pablo;
    4549
     
    269273    }
    270274    else if (name->getType() == Name::Type::UnicodeProperty) {
     275        #ifndef DISABLE_PREGENERATED_UCD_FUNCTIONS
    271276        if (DisablePregeneratedUnicode) {
     277        #endif
    272278            UCD::UCDCompiler ucdCompiler(mCCCompiler);
    273279            var = ucdCompiler.generateWithDefaultIfHierarchy(UCD::resolveUnicodeSet(name), pb);
    274         }
    275         else {
     280        #ifndef DISABLE_PREGENERATED_UCD_FUNCTIONS
     281        } else {
    276282            const UCD::ExternalProperty & ep = UCD::resolveExternalProperty(name->getFunctionName());
    277283            var = pb.createCall(Prototype::Create(name->getFunctionName(), std::get<1>(ep), std::get<2>(ep), std::get<3>(ep), std::get<0>(ep)), mCCCompiler.getBasisBits());
    278284        }
     285        #endif
    279286    }
    280287    else {
Note: See TracChangeset for help on using the changeset viewer.