Facebook code kinda has three layers:
1. clients (Objective-C for iOS, Java for Android, JS for Web and React Native)
2. application logic (Hack)
3. services (c++ and python are most prominent and well-supported, but there's a long tail of languages like Java, Haskell, OCaml, Ruby, etc.)
The prominent languages in each layer have pretty substantial code-bases.
More importantly, there's an engineering culture of eschewing "code ownership" and encouraging "code upgradability" so that motivated folks like Jason can drive these large changes.