[Groonga-commit] groonga/grnxx at d76d8d9 [master] Fix a bug that "flags" is not correctly initialized.

Back to archive index

susumu.yata null+****@clear*****
Fri Apr 26 20:54:07 JST 2013


susumu.yata	2013-04-26 20:54:07 +0900 (Fri, 26 Apr 2013)

  New Revision: d76d8d998cc3cb3a8e94c829da470d18bb3c2147
  https://github.com/groonga/grnxx/commit/d76d8d998cc3cb3a8e94c829da470d18bb3c2147

  Message:
    Fix a bug that "flags" is not correctly initialized.

  Modified files:
    lib/grnxx/alpha/map.hpp

  Modified: lib/grnxx/alpha/map.hpp (+6 -3)
===================================================================
--- lib/grnxx/alpha/map.hpp    2013-04-26 17:42:02 +0900 (8a48177)
+++ lib/grnxx/alpha/map.hpp    2013-04-26 20:54:07 +0900 (c42b965)
@@ -50,6 +50,9 @@ struct MapHeader {
 struct MapCursorFlagsIdentifier;
 typedef FlagsImpl<MapCursorFlagsIdentifier> MapCursorFlags;
 
+// Use the default settings.
+constexpr MapCursorFlags MAP_CURSOR_DEFAULT           =
+    MapCursorFlags::define(0x000);
 // Sort keys by ID.
 constexpr MapCursorFlags MAP_CURSOR_ORDER_BY_ID       =
     MapCursorFlags::define(0x001);
@@ -57,8 +60,8 @@ constexpr MapCursorFlags MAP_CURSOR_ORDER_BY_ID       =
 constexpr MapCursorFlags MAP_CURSOR_ORDER_BY_KEY      =
     MapCursorFlags::define(0x002);
 // TODO: Sort keys by distance.
-constexpr MapCursorFlags MAP_CURSOR_ORDER_BY_DISTANCE =
-    MapCursorFlags::define(0x004);
+//constexpr MapCursorFlags MAP_CURSOR_ORDER_BY_DISTANCE =
+//    MapCursorFlags::define(0x004);
 // Access keys in reverse order.
 constexpr MapCursorFlags MAP_CURSOR_REVERSE_ORDER     =
     MapCursorFlags::define(0x010);
@@ -77,7 +80,7 @@ struct MapCursorOptions {
   uint64_t offset;
   uint64_t limit;
 
-  constexpr MapCursorOptions() : flags(), offset(0), limit(-1) {}
+  MapCursorOptions() : flags(MAP_CURSOR_DEFAULT), offset(0), limit(-1) {}
 };
 
 template <typename T>
-------------- next part --------------
HTML����������������������������...
Download 



More information about the Groonga-commit mailing list
Back to archive index