arkanoid87 / futhark

Automatic wrapping of C headers in Nim
MIT License
0 stars 0 forks source link

How to discriminate between importc and importcpp when namespaces are in place #4

Open arkanoid87 opened 1 year ago

arkanoid87 commented 1 year ago
short myFunction(short a, short b, short c){
    return a+b+c;
}

VS

namespace outer {
    namespace inner {
        short myFunction(short a, short b, short c){
            return a+b+c;
        }
    }
}

funcDecl.get.getCursorLanguage returns CXLanguage_C in both cases

arkanoid87 commented 1 year ago

using namespace tokens count as ugly fallback for now