[ADT] Fix for ImmutableMapRef
authorAdam Balogh <adam.balogh@ericsson.com>
Thu, 15 Oct 2020 13:07:48 +0000 (15:07 +0200)
committerAdam Balogh <adam.balogh@ericsson.com>
Wed, 21 Oct 2020 10:13:20 +0000 (12:13 +0200)
commita6336eab0c507b665dda63fa9db1292a2cdee409
treefe4ad04c18f2b60956b21a625299c5b3826b8e07
parente86a70ce3defd7df85ac13879da815025ffa50a3
[ADT] Fix for ImmutableMapRef

The `Root` member of `ImmutableMapRef` was changed recently from a plain
pointer to `IntrusiveRefCntPtr`. However, the `Profile` member function
was not adjusted. This results in comilation error whenever the
`Profile` method is used on an `ImmutableMapRef`. This patch fixes this
issue and also adds unit tests for `ImmutableMapRef`.

Differential Revision: https://reviews.llvm.org/D89486
llvm/include/llvm/ADT/ImmutableMap.h
llvm/unittests/ADT/ImmutableMapTest.cpp