WEB-8397 Incorrect "element is not allowed here" inspection
(cherry picked from commit 3af18cf) CR-WS-126