Outline `Optional::require_value()`
authorAshwin Bharambe <ashwin@fb.com>
Thu, 11 May 2017 20:29:41 +0000 (13:29 -0700)
committerFacebook Github Bot <facebook-github-bot@users.noreply.github.com>
Thu, 11 May 2017 20:37:22 +0000 (13:37 -0700)
commit42c429142cd46d35bf0599dcfff3b3160001b483
tree6ada0af47dec4faa87934a6f84817a8110924fa8
parentc8aadaad37770dc4d1caf2bff239c604b51a6132
Outline `Optional::require_value()`

Summary:
We would like to use `folly/Optional` in settings where exceptions
are disabled. An example is ObjC++ codebases where supporting exceptions
doesn't quite help (since objc_msgSend() can throw) and yet we need to pay the
additional binary size cost for the unwind tables.

This patch makes a small change to outline the "assert" utility included
inside Optional.h

Reviewed By: yfeldblum, mzlee

Differential Revision: D5030172

fbshipit-source-id: 7def3c6eda22c41c8cab2037444978e0a4c50abf
folly/Makefile.am
folly/Optional.cpp [new file with mode: 0644]
folly/Optional.h