HomePhabricator

[Flang][OpenMP] Add semantic checks for OpenMP Private clause.

Authored by praveen on Nov 30 2020, 8:35 AM.

Description

[Flang][OpenMP] Add semantic checks for OpenMP Private clause.

Add the semantic checks for the OpenMP 4.5 - 2.15.3.3 Private clause.

  1. Pointers with the INTENT(IN) attribute may not appear in a private clause.
  2. Variables that appear in namelist statements may not appear in a private clause. A flag 'InNamelist' is added to the Symbol::Flag to identify the symbols in Namelist statemnts.

Test cases : omp-private01.f90, omp-private02.f90

Reviewed By: kiranchandramohan

Differential Revision: https://reviews.llvm.org/D90210