cpplint: Remove many unnecessary NOLINT
Now that we updated to upstream cpplint, a lot of these NOLINTs are no
longer necessary.
Bug: 68951293
Change-Id: If8ed5ffe89727f313f907a214b6d8fd2a2eddbad
diff --git a/openjdkjvmti/jvmti_allocator.h b/openjdkjvmti/jvmti_allocator.h
index e6cbc85..11af7b6 100644
--- a/openjdkjvmti/jvmti_allocator.h
+++ b/openjdkjvmti/jvmti_allocator.h
@@ -58,7 +58,7 @@
JvmtiAllocator() : env_(nullptr) {}
template <typename U>
- JvmtiAllocator(const JvmtiAllocator<U>& other) // NOLINT, implicit
+ JvmtiAllocator(const JvmtiAllocator<U>& other)
: env_(other.env_) {}
JvmtiAllocator(const JvmtiAllocator& other) = default;
@@ -95,7 +95,7 @@
JvmtiAllocator() : env_(nullptr) {}
template <typename U>
- JvmtiAllocator(const JvmtiAllocator<U>& other) // NOLINT, implicit
+ JvmtiAllocator(const JvmtiAllocator<U>& other)
: env_(other.env_) {}
JvmtiAllocator(const JvmtiAllocator& other) = default;
diff --git a/openjdkjvmti/ti_class.cc b/openjdkjvmti/ti_class.cc
index 2c5e5f9..e69c78b 100644
--- a/openjdkjvmti/ti_class.cc
+++ b/openjdkjvmti/ti_class.cc
@@ -33,7 +33,7 @@
#include "android-base/stringprintf.h"
-#include <mutex> // NOLINT [build/c++11] [5]
+#include <mutex>
#include <unordered_set>
#include "art_jvmti.h"
diff --git a/openjdkjvmti/ti_extension.cc b/openjdkjvmti/ti_extension.cc
index d3e0912..afd0723 100644
--- a/openjdkjvmti/ti_extension.cc
+++ b/openjdkjvmti/ti_extension.cc
@@ -54,7 +54,7 @@
JvmtiUniquePtr<char[]> param_name = CopyString(env, name, err);
char* name_ptr = param_name.get();
char_buffers->push_back(std::move(param_name));
- return jvmtiParamInfo { name_ptr, kind, base_type, null_ok }; // NOLINT [whitespace/braces] [4]
+ return jvmtiParamInfo{ name_ptr, kind, base_type, null_ok };
}
};
@@ -146,7 +146,7 @@
"com.android.art.heap.get_object_heap_id",
"Retrieve the heap id of the the object tagged with the given argument. An "
"arbitrary object is chosen if multiple objects exist with the same tag.",
- { // NOLINT [whitespace/braces] [4]
+ {
{ "tag", JVMTI_KIND_IN, JVMTI_TYPE_JLONG, false},
{ "heap_id", JVMTI_KIND_OUT, JVMTI_TYPE_JINT, false}
},
@@ -159,7 +159,7 @@
reinterpret_cast<jvmtiExtensionFunction>(HeapExtensions::GetHeapName),
"com.android.art.heap.get_heap_name",
"Retrieve the name of the heap with the given id.",
- { // NOLINT [whitespace/braces] [4]
+ {
{ "heap_id", JVMTI_KIND_IN, JVMTI_TYPE_JINT, false},
{ "heap_name", JVMTI_KIND_ALLOC_BUF, JVMTI_TYPE_CCHAR, false}
},
@@ -175,13 +175,13 @@
" except for additionally passing the heap id of the current object. The jvmtiHeapCallbacks"
" structure is reused, with the callbacks field overloaded to a signature of "
"jint (*)(jlong, jlong, jlong*, jint length, void*, jint).",
- { // NOLINT [whitespace/braces] [4]
+ {
{ "heap_filter", JVMTI_KIND_IN, JVMTI_TYPE_JINT, false},
{ "klass", JVMTI_KIND_IN, JVMTI_TYPE_JCLASS, true},
{ "callbacks", JVMTI_KIND_IN_PTR, JVMTI_TYPE_CVOID, false},
{ "user_data", JVMTI_KIND_IN_PTR, JVMTI_TYPE_CVOID, true}
},
- { // NOLINT [whitespace/braces] [4]
+ {
ERR(MUST_POSSESS_CAPABILITY),
ERR(INVALID_CLASS),
ERR(NULL_POINTER),
@@ -197,7 +197,7 @@
" 'Allocate' jvmti function. This does not include any memory that has been deallocated"
" through the 'Deallocate' function. This number is approximate and might not correspond"
" exactly to the sum of the sizes of all not freed allocations.",
- { // NOLINT [whitespace/braces] [4]
+ {
{ "currently_allocated", JVMTI_KIND_OUT, JVMTI_TYPE_JLONG, false},
},
{ ERR(NULL_POINTER) });
@@ -213,7 +213,7 @@
" chunk format. It returns the processed chunk. This is provided for backwards compatibility"
" reasons only. Agents should avoid making use of this extension when possible and instead"
" use the other JVMTI entrypoints explicitly.",
- { // NOLINT[whitespace/braces] [4]
+ {
{ "type_in", JVMTI_KIND_IN, JVMTI_TYPE_JINT, false },
{ "length_in", JVMTI_KIND_IN, JVMTI_TYPE_JINT, false },
{ "data_in", JVMTI_KIND_IN_BUF, JVMTI_TYPE_JBYTE, false },
@@ -322,7 +322,7 @@
" is responsible for interpreting the information present in the 'data' buffer. This is"
" provided for backwards-compatibility support only. Agents should prefer to use relevant"
" JVMTI events and functions above listening for this event.",
- { // NOLINT[whitespace/braces] [4]
+ {
{ "jni_env", JVMTI_KIND_IN_PTR, JVMTI_TYPE_JNIENV, false },
{ "type", JVMTI_KIND_IN, JVMTI_TYPE_JINT, false },
{ "data_size", JVMTI_KIND_IN, JVMTI_TYPE_JINT, false },
diff --git a/openjdkjvmti/ti_monitor.cc b/openjdkjvmti/ti_monitor.cc
index b31e9f2..7db0566 100644
--- a/openjdkjvmti/ti_monitor.cc
+++ b/openjdkjvmti/ti_monitor.cc
@@ -32,9 +32,9 @@
#include "ti_monitor.h"
#include <atomic>
-#include <chrono> // NOLINT [build/c++11] [5]
-#include <condition_variable> // NOLINT [build/c++11] [5]
-#include <mutex> // NOLINT [build/c++11] [5]
+#include <chrono>
+#include <condition_variable>
+#include <mutex>
#include "art_jvmti.h"
#include "monitor.h"