Add support for getting the current thread's name
[folly.git] / folly / File.cpp
index 4df3274eb86c3f77fa3280abb49303bbee9da9f0..be44ce572925cb614a26d54c2b86fe86f5566e4a 100644 (file)
 
 namespace folly {
 
-File::File()
-  : fd_(-1)
-  , ownsFd_(false)
-{}
-
-File::File(int fd, bool ownsFd)
-  : fd_(fd)
-  , ownsFd_(ownsFd) {
+File::File() noexcept : fd_(-1), ownsFd_(false) {}
+
+File::File(int fd, bool ownsFd) noexcept : fd_(fd), ownsFd_(ownsFd) {
   CHECK_GE(fd, -1) << "fd must be -1 or non-negative";
   CHECK(fd != -1 || !ownsFd) << "cannot own -1";
 }