Repository Analysis

Tencent/MMKV

An efficient, small mobile key-value storage framework developed by WeChat. Works on Android, iOS, macOS, Windows, POSIX, and OHOS.

2.8 Likely human-written View on GitHub
2.8
Adjusted Score
2.8
Raw Score
100%
Time Factor
2026-05-14
Last Push
18,598
Stars
C++
Language
55,393
Lines of Code
368
Files
139
Pattern Hits
2026-05-31
Scan Date

Score History

Severity Breakdown

CRITICAL 0HIGH 0MEDIUM 9LOW 130

Pattern Findings

139 matches across 5 categories. Click a row to expand file-level details.

Over-Commented Block128 hits · 128 pts
SeverityFileLineSnippet
LOWPOSIX/CMakeLists.txt1#
LOWPOSIX/demo/CMakeLists.txt1#
LOWPOSIX/demo/TestInterProcessLock.cpp21#include <MMKV/MMKV.h>
LOWPOSIX/demo/demo.cpp21#include <MMKV/MMKV.h>
LOWPOSIX/demo/demo.cpp1121// string key = "keyyy";
LOWPOSIX/golang/CMakeLists.txt1#
LOWPOSIX/src/CMakeLists.txt1#
LOWCore/MMKVLog.h21#ifndef MMKV_MMKVLOG_H
LOWCore/MMKVLog.h41
LOWCore/MMKVLog.h61# endif
LOWCore/MMBuffer.cpp21#define NOMINMAX // undefine max/min
LOWCore/MMKV.h21#ifndef MMKV_MMKV_H
LOWCore/MMKV.h601 // MMKV's size won't reduce after deleting key-values
LOWCore/MMKV_Android.cpp21#include "MMKV.h"
LOWCore/CMakeLists.txt1#
LOWCore/MMKV.cpp21#include "CodedInputData.h"
LOWCore/MMKV.cpp41#include <cstring>
LOWCore/MMKVMetaInfo.hpp101#endif
LOWCore/PBEncodeItem.hpp101#endif
LOWCore/ThreadLock.h21#ifndef MMKV_THREADLOCK_H
LOWCore/MiniPBCoder.cpp21#include "MiniPBCoder.h"
LOWCore/MiniPBCoder_OSX.cpp21#include "MiniPBCoder.h"
LOWCore/MMKVPredef.h21#ifndef MMKV_SRC_MMKVPREDEF_H
LOWCore/MMKVPredef.h41#endif
LOWCore/MMKVPredef.h61# define MMKV_ANDROID
LOWCore/MMKVPredef.h81# endif
LOWCore/MMKVPredef.h121#endif // MMKV_WIN32
LOWCore/MMKVPredef.h261constexpr size_t AES_IV_LEN = 16;
LOWCore/MMKVPredef.h281#else
LOWCore/CodedInputDataCrypt.cpp21#include "CodedInputDataCrypt.h"
LOWCore/KeyValueHolder.h121#endif
LOWCore/MMKV_OSX.cpp21#include "MMKVPredef.h"
LOWCore/MemoryFile_Linux.cpp21#include "MemoryFile.h"
LOWCore/ScopedLock.hpp61#include <type_traits>
LOWCore/MMKV_IO.cpp21#include "MMKV_IO.h"
LOWCore/MMKV_IO.cpp41#include <filesystem>
LOWCore/MiniPBCoder.h21#ifndef MMKV_MINIPBCODER_H
LOWCore/MemoryFile.cpp21#include "MemoryFile.h"
LOWCore/fakeinclude/MMKVCore/ThreadLock.h21#include "../../ThreadLock.h"
LOWCore/fakeinclude/MMKVCore/ScopedLock.hpp21#include "../../ScopedLock.hpp"
LOWCore/crc32/CMakeLists.txt1#
LOWCore/crc32/crc32_armv8.cpp41
LOWCore/crc32/Checksum.h61// getauxval(AT_HWCAP) in OHOS returns wrong value, we just assume all OHOS device have crc32 instr
LOWCore/crc32/zlib/zconf.h1/* zconf.h -- configuration of the zlib compression library
LOWCore/crc32/zlib/zconf.h21#define WINDOWS
LOWCore/crc32/zlib/zconf.h41#define MAXSEG_64K
LOWCore/crc32/zlib/zconf.h61#define STDC
LOWCore/crc32/zlib/zconf.h81#define z_const const
LOWCore/crc32/zlib/zconf.h141
LOWCore/crc32/zlib/zconf.h161#define FAR _far
LOWCore/crc32/zlib/zconf.h181#ifdef ZLIB_DLL
LOWCore/crc32/zlib/zconf.h201#define ZEXPORT WINAPI
LOWCore/crc32/zlib/zconf.h221
LOWCore/crc32/zlib/zconf.h261#endif
LOWCore/crc32/zlib/zconf.h281#define Z_HAVE_UNISTD_H
LOWCore/crc32/zlib/zconf.h301#ifndef Z_SOLO
LOWCore/crc32/zlib/zconf.h321#include <unistd.h> /* for SEEK_*, off_t, and _LFS64_LARGEFILE */
LOWCore/crc32/zlib/zconf.h341#endif
LOWCore/crc32/zlib/zconf.h361#endif
LOWCore/aes/openssl/openssl_md5_locl.h21#define HASH_LONG MD5_LONG
68 more matches not shown…
Self-Referential Comments7 hits · 21 pts
SeverityFileLineSnippet
MEDIUMflutter/mmkv_ios/pubspec.yaml28# The following section is specific to Flutter.
MEDIUMflutter/mmkv_android/pubspec.yaml28# The following section is specific to Flutter.
MEDIUMflutter/mmkv/pubspec.yaml43# The following section is specific to Flutter.
MEDIUMflutter/mmkv/example/pubspec.yaml38# The following section is specific to Flutter.
MEDIUMflutter/mmkv_ohos/pubspec.yaml32# The following section is specific to Flutter packages.
MEDIUMflutter/mmkv_win32/pubspec.yaml27# The following section is specific to Flutter packages.
MEDIUMflutter/mmkv_linux/pubspec.yaml27# The following section is specific to Flutter packages.
Excessive Try-Catch Wrapping2 hits · 3 pts
SeverityFileLineSnippet
LOWScript/dumpJavaSignature.py129 except Exception as e:
MEDIUMScript/dumpJavaSignature.py144 print(f"Error: {e}")
Slop Phrases1 hit · 3 pts
SeverityFileLineSnippet
MEDIUMflutter/mmkv/example/pubspec.yaml42 # included with your application, so that you can use the icons in
Hyper-Verbose Identifiers1 hit · 1 pts
SeverityFileLineSnippet
LOW…y/src/ohosTest/ets/testrunner/OpenHarmonyTestRunner.ts27async function addAbilityMonitorCallback(err: any) {