mirror of https://github.com/libAthena/athena.git
Fix last commit
This commit is contained in:
parent
644070d5f3
commit
066e3ae109
|
@ -190,10 +190,11 @@ class ATDNAEmitVisitor : public clang::RecursiveASTVisitor<ATDNAEmitVisitor> {
|
||||||
if (clang::AnnotateAttr* annot = clang::dyn_cast_or_null<clang::AnnotateAttr>(attr)) {
|
if (clang::AnnotateAttr* annot = clang::dyn_cast_or_null<clang::AnnotateAttr>(attr)) {
|
||||||
llvm::StringRef textRef = annot->getAnnotation();
|
llvm::StringRef textRef = annot->getAnnotation();
|
||||||
#if LLVM_VERSION_MAJOR >= 13
|
#if LLVM_VERSION_MAJOR >= 13
|
||||||
if (textRef.startswith_insensitive("rcrc32=")) {
|
if (textRef.startswith_insensitive("rcrc32="))
|
||||||
#else
|
#else
|
||||||
if (textRef.startswith_lower("rcrc32="))
|
if (textRef.startswith_lower("rcrc32="))
|
||||||
#endif
|
#endif
|
||||||
|
{
|
||||||
unsigned long num = strtoul(textRef.data() + 7, nullptr, 16);
|
unsigned long num = strtoul(textRef.data() + 7, nullptr, 16);
|
||||||
std::string tmpS;
|
std::string tmpS;
|
||||||
llvm::raw_string_ostream s(tmpS);
|
llvm::raw_string_ostream s(tmpS);
|
||||||
|
@ -341,7 +342,7 @@ class ATDNAEmitVisitor : public clang::RecursiveASTVisitor<ATDNAEmitVisitor> {
|
||||||
#if LLVM_VERSION_MAJOR >= 13
|
#if LLVM_VERSION_MAJOR >= 13
|
||||||
arg.print(context.getPrintingPolicy(), OS, false);
|
arg.print(context.getPrintingPolicy(), OS, false);
|
||||||
#else
|
#else
|
||||||
arg.print(context.getPrintingPolicy(), OS, false);
|
arg.print(context.getPrintingPolicy(), OS);
|
||||||
#endif
|
#endif
|
||||||
needsComma = true;
|
needsComma = true;
|
||||||
}
|
}
|
||||||
|
@ -359,10 +360,11 @@ class ATDNAEmitVisitor : public clang::RecursiveASTVisitor<ATDNAEmitVisitor> {
|
||||||
if (clang::AnnotateAttr* annot = clang::dyn_cast_or_null<clang::AnnotateAttr>(attr)) {
|
if (clang::AnnotateAttr* annot = clang::dyn_cast_or_null<clang::AnnotateAttr>(attr)) {
|
||||||
llvm::StringRef textRef = annot->getAnnotation();
|
llvm::StringRef textRef = annot->getAnnotation();
|
||||||
#if LLVM_VERSION_MAJOR >= 13
|
#if LLVM_VERSION_MAJOR >= 13
|
||||||
if (textRef.startswith_insensitive("specparms=")) {
|
if (textRef.startswith_insensitive("specparms="))
|
||||||
#else
|
#else
|
||||||
if (textRef.startswith_lower("specparms=")) {
|
if (textRef.startswith_lower("specparms="))
|
||||||
#endif
|
#endif
|
||||||
|
{
|
||||||
llvm::SmallVector<llvm::StringRef, 16> specParms;
|
llvm::SmallVector<llvm::StringRef, 16> specParms;
|
||||||
textRef.substr(10).split(specParms, ',');
|
textRef.substr(10).split(specParms, ',');
|
||||||
int numTuples = int(specParms.size()) / numParms;
|
int numTuples = int(specParms.size()) / numParms;
|
||||||
|
|
Loading…
Reference in New Issue