Handle references to global constants in expressions
Summary: We currently only allow a subset of literal expressions in constant initializers, ignoring everything else. We also need to handle references to global constants. This means the function which converts a node to an expression needs access to the current namespace, in order to elaborate names. This function was previously a method on `Node_`, so threading that state in might have been a bit cumbersome. Instead, this diff moves the method to be a method on `DirectDeclSmartConstructors` (as is `node_to_ty`).
Reviewed By: Wilfred
Differential Revision:
D21484513
fbshipit-source-id:
7a537da74223dabea23f7f18b926b1ae44d4889b