[flang-commits] [PATCH] D93447: [Flang][openmp][openacc] Extend CheckNoBranching to handle branching provided by LabelEnforce.

Valentin Clement via Phabricator via flang-commits flang-commits at lists.llvm.org
Tue Jan 12 11:20:32 PST 2021


clementval added inline comments.


================
Comment at: flang/lib/Semantics/check-directive-structure.h:45
     currentStatementSourcePosition_ = statement.source;
+    if (statement.label.has_value()) {
+      labels_.insert(*statement.label);
----------------
klausler wrote:
> sameeranjoshi wrote:
> > clementval wrote:
> > > Braces should be removed for simple if
> > Was it a comment on fir-dev?
> > I think flang[1] allows and fir-dev follows llvm coding standard[2].
> > 
> > [1] https://github.com/llvm/llvm-project/blob/master/flang/docs/C%2B%2Bstyle.md#layout
> > [2] https://llvm.org/docs/CodingStandards.html#don-t-use-braces-on-simple-single-statement-bodies-of-if-else-loop-statements
> Please conform to the style used in the Fortran front-end; we always use braces for safety and future maintainability.
My bad :( 


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D93447



More information about the flang-commits mailing list