cornelius / libkode

C++ code generation library
8 stars 11 forks source link

Implement #pragma once guard generation to headers (fixed #29) #35

Closed martonmiklos closed 3 years ago

martonmiklos commented 3 years ago

Title says almost all: now it is going to be possible to generate headers having #pragma once based include.

dfaure-kdab commented 3 years ago

I'm even wondering if this should be configurable at all?

AFAIK #pragma once is supported everywhere nowadays, for a long time.

martonmiklos commented 3 years ago

I'm even wondering if this should be configurable at all?

AFAIK #pragma once is supported everywhere nowadays, for a long time.

That's true. KODE/kxml_compiler wise I think we are fine with generating #pragma once (at least I am). If KDSoap/kdwsdl2cpp wise you have no objections I am happy to refactor this PR.

dfaure-kdab commented 3 years ago

Yep, I have no objection. All compilers support it (gcc since 3.4, so the C++11 requirement forces it to support it).

martonmiklos commented 3 years ago

Yep, I have no objection. All compilers support it (gcc since 3.4, so the C++11 requirement forces it to support it).

Deal! May I ask for a re-review?