Lines Matching defs:directive
1 //===-- lib/Semantics/check-directive-structure.h ---------------*- C++ -*-===//
10 // directive language.
32 // directive.
33 // typename D is the directive enumeration.
37 parser::CharBlock sourcePosition, D directive,
41 currentDirective_{directive}, numDoConstruct_{0} {}
162 // directive
172 // an OpenMP/OpenACC directive
177 // typename D is the directive enumeration.
192 : directiveSource{source}, directive{d} {}
196 D directive;
238 void SetContextDirectiveSource(const parser::CharBlock &directive) {
239 GetContext().directiveSource = directive;
242 void SetContextDirectiveEnum(D dir) { GetContext().directive = dir; }
319 if (it->directive == dir) {
353 void CheckNoBranching(const parser::Block &block, D directive,
361 // Check if a clause is allowed on a directive. Returns true if is and
390 virtual llvm::StringRef getDirectiveName(D directive) { return ""; };
402 const parser::Block &block, D directive,
405 context_, directiveSource, directive, ContextDirectiveAsFortran()};
423 "directive"_err_en_US,
431 // Check that at least one clause is attached to the directive.
437 "At least one clause is required on the %s directive"_err_en_US,
456 // directive.
472 "At least one of %s clause should appear on the %s directive"_port_en_US,
477 "At least one of %s clause must appear on the %s directive"_err_en_US,
487 getDirectiveName(GetContext().directive).str());
490 // Check that clauses present on the directive are allowed clauses.
501 "%s clause is not allowed on the %s directive and will be ignored"_port_en_US,
506 "%s clause is not allowed on the %s directive"_err_en_US,
516 "At most one %s clause can appear on the %s directive"_err_en_US,
531 "same %s directive"_err_en_US,
559 "Clause %s is not allowed if clause %s appears on the %s directive"_err_en_US,
575 "At most one %s clause can appear on the %s directive or in group separated by the %s clause"_err_en_US,
600 "Clause %s is not allowed if clause %s appears on the %s directive"_err_en_US,
611 "Clause %s is not allowed if clause %s appears on the %s directive"_err_en_US,
648 .Say(endSource, "Unmatched %s directive"_err_en_US,
650 .Attach(beginSource, "Does not match directive"_en_US);