[PATCH] D77701: [Sema] refactor static functions into private methods NFC

2020-04-09 Thread David Blaikie via Phabricator via cfe-commits
dblaikie added a comment. Yeah, if these were already member-function static, I'd agree it was a code smell - but function-scope static functions that take "this" as the first parameter don't seem like a bad thing to me - it reduces the header surface area/dependence. Repository: rG LLVM Gi

[PATCH] D77701: [Sema] refactor static functions into private methods NFC

2020-04-08 Thread Aaron Ballman via Phabricator via cfe-commits
aaron.ballman added a comment. In D77701#1969687 , @nickdesaulniers wrote: > In D77701#1969132 , @aaron.ballman > wrote: > > > OTOH, this is reasonable, NFC, and I tend to agree about it being a code > > smell. >

[PATCH] D77701: [Sema] refactor static functions into private methods NFC

2020-04-08 Thread Nick Desaulniers via Phabricator via cfe-commits
nickdesaulniers added a comment. In D77701#1969132 , @aaron.ballman wrote: > OTOH, this is reasonable, NFC, and I tend to agree about it being a code > smell. > OTOH, this makes parsing Sema.h that much slower and adds even more text for > us to wade t

[PATCH] D77701: [Sema] refactor static functions into private methods NFC

2020-04-08 Thread Aaron Ballman via Phabricator via cfe-commits
aaron.ballman added a reviewer: rsmith. aaron.ballman added a comment. OTOH, this is reasonable, NFC, and I tend to agree about it being a code smell. OTOH, this makes parsing Sema.h that much slower and adds even more text for us to wade through in that header file. Given that the approaches ar

[PATCH] D77701: [Sema] refactor static functions into private methods NFC

2020-04-07 Thread Nick Desaulniers via Phabricator via cfe-commits
nickdesaulniers created this revision. nickdesaulniers added reviewers: aaron.ballman, dblaikie. Herald added a reviewer: jdoerfert. Herald added a project: clang. Herald added a subscriber: cfe-commits. While working in SemaStmt, I noticed a bunch of static functions are passed *this, which is a