mirror of
https://github.com/facebook/sapling.git
synced 2024-10-07 15:27:13 +03:00
Throw EdenError when it's not implemented.
Summary: Calling a command that is not implemented will terminate the edenfs. It was ok for testing but now we have it running on Sandcastle, so will throw Eden error instead. Reviewed By: chadaustin Differential Revision: D18145495 fbshipit-source-id: 17e57f426d3cf80c93c2112741a027db8cbc6b8d
This commit is contained in:
parent
b1523f0862
commit
fccc1343ba
@ -8,6 +8,7 @@
|
||||
#pragma once
|
||||
#include <iostream>
|
||||
#include <string>
|
||||
#include "eden/fs/service/EdenError.h"
|
||||
#include "eden/fs/utils/PathFuncs.h"
|
||||
|
||||
// This is a stub to compile eden/service on Window.
|
||||
@ -73,11 +74,14 @@ static int unlink(const char* path) {
|
||||
return _unlink(path);
|
||||
}
|
||||
|
||||
#define NOT_IMPLEMENTED() \
|
||||
do { \
|
||||
std::cout << " +++++ NOT IMPLEMETED +++++++ Function: " << __FUNCTION__ \
|
||||
<< " Line:" << __LINE__; \
|
||||
throw; \
|
||||
#define NOT_IMPLEMENTED() \
|
||||
do { \
|
||||
throw newEdenError( \
|
||||
EdenErrorType::GENERIC_ERROR, \
|
||||
" +++++ NOT IMPLEMETED +++++++ Function: ", \
|
||||
__FUNCTION__, \
|
||||
" Line: ", \
|
||||
__LINE__); \
|
||||
} while (true)
|
||||
|
||||
} // namespace eden
|
||||
|
Loading…
Reference in New Issue
Block a user