projects
/
platform
/
core
/
uifw
/
dali-toolkit.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Merge "Make -DUSE_DEFAULT_RESOURCE_DIR=OFF compile again" into devel/master
[platform/core/uifw/dali-toolkit.git]
/
dali-scene-loader
/
public-api
/
utils.h
diff --git
a/dali-scene-loader/public-api/utils.h
b/dali-scene-loader/public-api/utils.h
index
3ab0c33
..
1aace35
100644
(file)
--- a/
dali-scene-loader/public-api/utils.h
+++ b/
dali-scene-loader/public-api/utils.h
@@
-41,10
+41,7
@@
namespace SceneLoader
class DALI_SCENE_LOADER_API StreamBuffer : public std::basic_streambuf<char>
{
public:
class DALI_SCENE_LOADER_API StreamBuffer : public std::basic_streambuf<char>
{
public:
- StreamBuffer(char* buffer, size_t size) noexcept(true)
- {
- setp(buffer, buffer + size);
- }
+ StreamBuffer(char* buffer, size_t size) noexcept(true);
};
/*
};
/*
@@
-57,18
+54,10
@@
class DALI_SCENE_LOADER_API ExceptionFlinger
public:
enum { MESSAGE_BUFFER_SIZE = 512 };
public:
enum { MESSAGE_BUFFER_SIZE = 512 };
- ExceptionFlinger(const char* location) noexcept(true)
- : mLocation(location),
- mStreamBuffer(GetMessageBuffer(), MESSAGE_BUFFER_SIZE - 1),
- mStream(&mStreamBuffer)
- {}
+ ExceptionFlinger(const char* location) noexcept(true);
[[noreturn]]
[[noreturn]]
- ~ExceptionFlinger() noexcept(false)
- {
- operator<<('\0');
- throw DaliException(mLocation, GetMessageBuffer());
- }
+ ~ExceptionFlinger() noexcept(false);
template <typename T>
ExceptionFlinger& operator<<(const T& rhs) noexcept(true)
template <typename T>
ExceptionFlinger& operator<<(const T& rhs) noexcept(true)
@@
-78,9
+67,17
@@
public:
}
private:
}
private:
+ struct Impl
+ {
+ const char* mLocation;
+
+ [[noreturn]]
+ ~Impl() noexcept(false);
+ };
+
static char* GetMessageBuffer() noexcept(true);
static char* GetMessageBuffer() noexcept(true);
-
const char* mLocation
;
+
Impl mImpl
;
StreamBuffer mStreamBuffer;
std::ostream mStream;
};
StreamBuffer mStreamBuffer;
std::ostream mStream;
};