force link failure when compilation flags don't match
Summary: F14 varies its inline code according to the flags passed to the compiler. This can cause problems if libraries override compilation flags on their own, since it won't be safe to exchange F14 instances between compilation domains. This diff introduces a template specialization that varies according to the intrinsics mode and that has only a single definition (in F14Table.cpp). The member is called on a couple of cold paths (exception handling for copy construction and rehash). This makes it very likely that a compilation unit that uses F14 and is compiled with different compiler flags than F14Table.cpp will get a linker error. Reviewed By: yfeldblum Differential Revision: D9200315 fbshipit-source-id: 9cbca18eef0ddd6efcf6d9d6057eda2400f8653c
Showing
Please register or sign in to comment