[all-commits] [llvm/llvm-project] 8a221a: [Flang][OpenMP] Push context when parsing DECLARE ...

Jack Styles via All-commits all-commits at lists.llvm.org
Mon Jul 7 01:57:36 PDT 2025


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: 8a221a585ca70dede85f191992a0364e43cfdbf0
      https://github.com/llvm/llvm-project/commit/8a221a585ca70dede85f191992a0364e43cfdbf0
  Author: Jack Styles <jack.styles at arm.com>
  Date:   2025-07-07 (Mon, 07 Jul 2025)

  Changed paths:
    M flang/lib/Semantics/resolve-directives.cpp
    M flang/test/Parser/OpenMP/declare-variant.f90

  Log Message:
  -----------
  [Flang][OpenMP] Push context when parsing DECLARE VARIANT (#147075)

Basic parsing and semantics support for Declare Variant was added in
#130578. However, this did not include variant of `Pre` and `Post`
within `OmpAttributeVisitor`. This meant that when a function in the
class tried to get the context using `GetContext`, Flang would crash as
the context was empty. To ensure this is possible, such as when
resolving names as part of the `uniform` clause in the `simd` directive,
the context is now pushed within `OmpAttributeVisitor` when parsing a
`DECLARE VARIANT` directive.

Fixes #145222



To unsubscribe from these emails, change your notification settings at https://github.com/llvm/llvm-project/settings/notifications


More information about the All-commits mailing list