llvm / llvm-project / 0c1b18f0f3e526da7dcbbd5a9e363dca85a90c95 / . / flang / test / Semantics / if_stmt03.f90

! RUN: %python %S/test_errors.py %s %flang_fc1 | |

! Check that non-logical expressions are not allowed. | |

! Check that non-scalar expressions are not allowed. | |

! TODO: Insure all non-logicals are prohibited. | |

LOGICAL, DIMENSION (2) :: B | |

!ERROR: Must have LOGICAL type, but is REAL(4) | |

IF (A) A = LOG (A) | |

!ERROR: Must be a scalar value, but is a rank-1 array | |

IF (B) A = LOG (A) | |

END |