[cfe-dev] How to try out -Wlifetime ?

Jonas Toth via cfe-dev cfe-dev at lists.llvm.org
Mon Nov 12 09:08:38 PST 2018


Hi,

you can try it out on `godbolt.org`, as there is a custom built there.

If you want to build yourself you should use
`https://github.com/mgehre/clang` (lifetime-branch) as the patches are
not upstreamed (yet).

Best, Jonas

Am 12.11.18 um 18:05 schrieb cen via cfe-dev:
> Hi
>
> I watched Herb's talk on Cppcon so I decided to try out the new
> lifetime feature. I cloned llvm and clang master from github mirror
> and built both locally.
>
> I tried to compile the first godbolt sample
> (https://godbolt.org/z/szJjnH) but no luck:
>
> clang -Wlifetime -lstdc++ b.cpp
> warning: unknown warning option '-Wlifetime'; did you mean
> '-Wdate-time'? [-Wunknown-warning-option]
> 1 warning generated.
>
>
> What am I doing wrong?
>
> _______________________________________________
> cfe-dev mailing list
> cfe-dev at lists.llvm.org
> http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-dev



More information about the cfe-dev mailing list