aboutsummaryrefslogtreecommitdiffstats
path: root/library/cpp/yt/misc/source_location.cpp
diff options
context:
space:
mode:
authorbabenko <babenko@yandex-team.ru>2022-02-10 16:49:19 +0300
committerDaniil Cherednik <dcherednik@yandex-team.ru>2022-02-10 16:49:19 +0300
commitf31097c96270919a1f49360bdaaa69ea4f3fefab (patch)
tree5d5cb817648f650d76cf1076100726fd9b8448e8 /library/cpp/yt/misc/source_location.cpp
parentcec37806d8847aa3db53bafc9e251d4aaf325c12 (diff)
downloadydb-f31097c96270919a1f49360bdaaa69ea4f3fefab.tar.gz
Restoring authorship annotation for <babenko@yandex-team.ru>. Commit 2 of 2.
Diffstat (limited to 'library/cpp/yt/misc/source_location.cpp')
-rw-r--r--library/cpp/yt/misc/source_location.cpp106
1 files changed, 53 insertions, 53 deletions
diff --git a/library/cpp/yt/misc/source_location.cpp b/library/cpp/yt/misc/source_location.cpp
index c632378050..8d22d43636 100644
--- a/library/cpp/yt/misc/source_location.cpp
+++ b/library/cpp/yt/misc/source_location.cpp
@@ -1,54 +1,54 @@
-#include "source_location.h"
-
-#include <string.h>
-
-namespace NYT {
-
-////////////////////////////////////////////////////////////////////////////////
-
-const char* TSourceLocation::GetFileName() const
-{
- return FileName_;
-}
-
-int TSourceLocation::GetLine() const
-{
- return Line_;
-}
-
-bool TSourceLocation::IsValid() const
-{
- return FileName_ != nullptr;
-}
-
-bool TSourceLocation::operator<(const TSourceLocation& other) const
-{
- const char* fileName = FileName_ ? FileName_ : "";
- const char* otherFileName = other.FileName_ ? other.FileName_ : "";
- int fileNameResult = strcmp(fileName, otherFileName);
- if (fileNameResult != 0) {
+#include "source_location.h"
+
+#include <string.h>
+
+namespace NYT {
+
+////////////////////////////////////////////////////////////////////////////////
+
+const char* TSourceLocation::GetFileName() const
+{
+ return FileName_;
+}
+
+int TSourceLocation::GetLine() const
+{
+ return Line_;
+}
+
+bool TSourceLocation::IsValid() const
+{
+ return FileName_ != nullptr;
+}
+
+bool TSourceLocation::operator<(const TSourceLocation& other) const
+{
+ const char* fileName = FileName_ ? FileName_ : "";
+ const char* otherFileName = other.FileName_ ? other.FileName_ : "";
+ int fileNameResult = strcmp(fileName, otherFileName);
+ if (fileNameResult != 0) {
return fileNameResult < 0;
- }
-
- if (Line_ < other.Line_) {
- return true;
- }
- if (Line_ > other.Line_) {
- return false;
- }
-
- return false;
-}
-
-bool TSourceLocation::operator==(const TSourceLocation& other) const
-{
- const char* fileName = FileName_ ? FileName_ : "";
- const char* otherFileName = other.FileName_ ? other.FileName_ : "";
- return
- strcmp(fileName, otherFileName) == 0 &&
- Line_ == other.Line_;
-}
-
-////////////////////////////////////////////////////////////////////////////////
-
-} // namespace NYT
+ }
+
+ if (Line_ < other.Line_) {
+ return true;
+ }
+ if (Line_ > other.Line_) {
+ return false;
+ }
+
+ return false;
+}
+
+bool TSourceLocation::operator==(const TSourceLocation& other) const
+{
+ const char* fileName = FileName_ ? FileName_ : "";
+ const char* otherFileName = other.FileName_ ? other.FileName_ : "";
+ return
+ strcmp(fileName, otherFileName) == 0 &&
+ Line_ == other.Line_;
+}
+
+////////////////////////////////////////////////////////////////////////////////
+
+} // namespace NYT