ldc/ddmd/hooks.d
Johan Engelen 5ffd34f7b6 Add LDC-specific traits for CTFE information about the target machine.
__traits(targetCPU) == "broadwell"
__traits(targetHasFeature, "sse2") == bool
2016-06-06 11:19:07 +02:00

19 lines
495 B
D

// Compiler implementation of the D programming language
// Copyright (c) 1999-2016 by Digital Mars
// All Rights Reserved
// http://www.digitalmars.com
// Distributed under the Boost Software License, Version 1.0.
// http://www.boost.org/LICENSE_1_0.txt
module ddmd.hooks;
import ddmd.dscope;
import ddmd.expression;
import gen.ldctraits;
/// Returns `null` when the __trait was not recognized.
Expression semanticTraitsHook(TraitsExp e, Scope* sc)
{
return semanticTraitsLDC(e, sc);
}