On 11-10-17 11:45, Emilio Cobos Álvarez wrote:
> Hi,
> 
> I'm adding a header to the build, and I'm wondering: Can we use pragma once?
> 
> I don't see it anywhere in the build except third-party paths and:
> 
>   dom/svg/nsISVGPoint.h
>   xpcom/io/nsAnonymousTemporaryFile.h
> 
> So I'm not sure if it's because it's somehow prohibited or not
> recommended, or just because of inertia.

It's covered in our Coding Style:
https://developer.mozilla.org/en-US/docs/Mozilla/Developer_guide/Coding_Style#CC_practices

The #pragma is non-standard (though fairly widely supported), but the
"portable" way is recognized as equivalent for several compilers. It
actually seems MSVC is the only one that we (still) use that doesn't
know about the equivalence.

-- 
GCP
_______________________________________________
dev-platform mailing list
dev-platform@lists.mozilla.org
https://lists.mozilla.org/listinfo/dev-platform

Reply via email to