Instantly share code, notes, and snippets.
::C #=> :c
Colin is right, it seems that, due to a 'quirk' in the way ruby parses and evaluates the assignments of constants. They are set to the global namespace when attempted to be assigned in a block such as module_exec. This can be worked around by explicitly declaring the namespace, but it might not always be useful.
Mod::C = :c
Mod::C #=> :c