diff --git a/clang/include/clang/AST/StmtOpenMP.h b/clang/include/clang/AST/StmtOpenMP.h index 2725747e051e7..6216433915357 100644 --- a/clang/include/clang/AST/StmtOpenMP.h +++ b/clang/include/clang/AST/StmtOpenMP.h @@ -994,7 +994,7 @@ class OMPLoopTransformationDirective : public OMPLoopBasedDirective { unsigned getNumAssociatedLoops() const { return getLoopsNumber(); } /// Return the number of loops generated by this loop transformation. - unsigned getNumGeneratedLoops() { return NumGeneratedLoops; } + unsigned getNumGeneratedLoops() const { return NumGeneratedLoops; } /// Get the de-sugared statements after the loop transformation. ///