ChuanqiXu marked 8 inline comments as done.
ChuanqiXu added inline comments.


================
Comment at: clang/docs/CPlusPlus20Modules.rst:316-317
+
+Currently Clang would accept the above example. But it may produce surprising 
results if the
+debugging code depends on consistent use of ``NDEBUG`` also in other 
translation units.
+
----------------
h-vetinari wrote:
> I realized afterwards that it's the inverse - debugging code might depend on 
> the _absence_  of `NDEBUG` which switches of debug stuff.
From my experience, `NDEBUG` is used more frequently in practice. We generally 
write:

```C++
#ifndef NDEBUG
...
#endif
```

I guess this might not be a big deal.


CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D131062/new/

https://reviews.llvm.org/D131062

_______________________________________________
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Reply via email to