//===- ADTExtras.h - Extra ADTs for use in MLIR -----------------*- C++ -*-===// // // Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions. // See https://llvm.org/LICENSE.txt for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // //===----------------------------------------------------------------------===// #ifndef MLIR_SUPPORT_ADTEXTRAS_H #define MLIR_SUPPORT_ADTEXTRAS_H #include "mlir/Support/LLVM.h" #include "llvm/ADT/ArrayRef.h" #include "llvm/ADT/SmallVector.h" namespace mlir { //===----------------------------------------------------------------------===// // CopyOnWriteArrayRef<T> //===----------------------------------------------------------------------===// // A wrapper around an ArrayRef<T> that copies to a SmallVector<T> on // modification. This is for use in the mlir::<Type>::Builders. template <typename T> class CopyOnWriteArrayRef { … }; } // namespace mlir #endif