// ĠCopyright Ġ 2 0 0 0 - 2 0 2 1 ĠJetBrains Ġs . r . o . Ġand Ġcontributors . ĠUse Ġof Ġthis Ġsource Ġcode Ġis Ġgoverned Ġby Ġthe ĠApache Ġ 2 . 0 Ġlicense Ġthat Ġcan Ġbe Ġfound Ġin Ġthe ĠLICENSE Ġfile . Ċ Ċ package Ġorg . jetbrains . kotlin . idea . refactor ing . member Info Ċ Ċ import Ġcom . intellij . psi . Psi Named Element Ċ import Ġcom . intellij . refactor ing . class Members . Member Info Base Ċ import Ġcom . intellij . refactor ing . class Members . Member Info Model Ċ import Ġcom . intellij . refactor ing . util . class Members . Uses Dependency Member Info Model Ċ import Ġorg . jetbrains . kotlin . psi . Kt Class Or Object Ċ import Ġorg . jetbrains . kotlin . psi . Kt Named Declaration Ċ import Ġorg . jetbrains . kotlin . psi . Kt Object Declaration Ċ import Ġorg . jetbrains . kotlin . psi . psi Util . containing Class Or Object Ċ Ċ open Ġclass ĠKotlin Uses Dependency Member Info Model < T Ġ: ĠK t Named Declaration , ĠM Ġ: ĠMember Info Base < T >>( ĊĠĠĠ Ġklass : ĠK t Class Or Object , ĊĠĠĠ ĠsuperClass : ĠPsi Named Element ?, ĊĠĠĠ Ġrecursive : ĠBoolean Ċ ) Ġ: ĠUses Dependency Member Info Model < T , ĠPsi Named Element , ĠM >( klass , ĠsuperClass , Ġrecursive ) Ġ{ ĊĠĠĠ Ġoverride Ġfun Ġdo Check ( member Info : ĠM , Ġproblem : ĠInt ): ĠInt Ġ{ ĊĠĠĠĠĠĠĠ Ġval Ġmember Ġ= Ġmember Info . member ĊĠĠĠĠĠĠĠ Ġval Ġcontainer Ġ= Ġmember . containing Class Or Object ĊĠĠĠĠĠĠĠ Ġif Ġ( problem Ġ== ĠMember Info Model . ERROR ĊĠĠĠĠĠĠĠĠĠĠĠ Ġ&& Ġcontainer Ġis ĠK t Object Declaration ĊĠĠĠĠĠĠĠĠĠĠĠ Ġ&& Ġcontainer . is Companion () ĊĠĠĠĠĠĠĠĠĠĠĠ Ġ&& Ġcontainer . containing Class Or Object Ġ== Ġmy Class ĊĠĠĠĠĠĠĠ Ġ) Ġreturn ĠMember Info Model . WARNING ĊĊĠĠĠĠĠĠĠ Ġreturn Ġproblem ĊĠĠĠ Ġ} Ċ }