<div dir="ltr"><div class="gmail_extra"><div class="gmail_quote">On Wed, Feb 19, 2014 at 5:41 PM, Yunzhong Gao <span dir="ltr"><<a href="mailto:Yunzhong_Gao@playstation.sony.com" target="_blank">Yunzhong_Gao@playstation.sony.com</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><br>
  A coding style question:<br>
<br>
  It seems that CGRecordLowering is exposing a lot of its member fields and functions. I wonder whether it makes sense to make some of these member fields private. For example, it seems<br>
    std::vector<MemberInfo> Members<br>
  does not need to be referenced by outside classes, and could be made private (and hence the definition of MemberInfo). I did not check all the "Input Memoization fields", but I suspect some of them do not need to be exposed either. And some of the member functions as well, such as,<br>

    void lowerUnion();<br>
  and some other functions used by lower(), probably can be hidden from outside classes as well.<br>
<br>
  I think this is minor point since CGRecordLowering is only defined and used in this file, and I am not entirely sure about LLVM's coding style on access control. What do the other reviewers think?<br></blockquote><div>
<br></div><div>Adding private: around everything except the entry points is probably a good idea, but I don't think it matters too much.  All that stuff is TU local anyway.</div></div></div></div>