Remove unused private member variables found by clang -Wunused-private-field

Review URL: https://codereview.chromium.org/11414207
Patch from Adam Klein <adamk@chromium.org>.

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@13096 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
This commit is contained in:
danno@chromium.org 2012-11-29 15:13:49 +00:00
parent 7cc61deafa
commit 5a40f006f9
10 changed files with 18 additions and 37 deletions

View File

@ -1511,9 +1511,9 @@ void Shell::RunShell(Isolate* isolate) {
class ShellThread : public i::Thread {
public:
// Takes ownership of the underlying char array of |files|.
ShellThread(Isolate* isolate, int no, char* files)
ShellThread(Isolate* isolate, char* files)
: Thread("d8:ShellThread"),
isolate_(isolate), no_(no), files_(files) { }
isolate_(isolate), files_(files) { }
~ShellThread() {
delete[] files_;
@ -1522,7 +1522,6 @@ class ShellThread : public i::Thread {
virtual void Run();
private:
Isolate* isolate_;
int no_;
char* files_;
};
@ -1829,7 +1828,7 @@ int Shell::RunMain(Isolate* isolate, int argc, char* argv[]) {
printf("File list '%s' not found\n", options.parallel_files[i]);
Exit(1);
}
ShellThread* thread = new ShellThread(isolate, threads.length(), files);
ShellThread* thread = new ShellThread(isolate, files);
thread->Start();
threads.Add(thread);
}

View File

@ -537,9 +537,6 @@ class FrameDescription {
intptr_t context_;
StackFrame::Type type_;
Smi* state_;
#ifdef DEBUG
Code::Kind kind_;
#endif
// Continuation is the PC where the execution continues after
// deoptimizing.

View File

@ -338,10 +338,9 @@ class IncrementalMarkingMarkingVisitor
class IncrementalMarkingRootMarkingVisitor : public ObjectVisitor {
public:
IncrementalMarkingRootMarkingVisitor(Heap* heap,
IncrementalMarking* incremental_marking)
: heap_(heap),
incremental_marking_(incremental_marking) {
explicit IncrementalMarkingRootMarkingVisitor(
IncrementalMarking* incremental_marking)
: incremental_marking_(incremental_marking) {
}
void VisitPointer(Object** p) {
@ -368,7 +367,6 @@ class IncrementalMarkingRootMarkingVisitor : public ObjectVisitor {
}
}
Heap* heap_;
IncrementalMarking* incremental_marking_;
};
@ -628,7 +626,7 @@ void IncrementalMarking::StartMarking(CompactionFlag flag) {
}
// Mark strong roots grey.
IncrementalMarkingRootMarkingVisitor visitor(heap_, this);
IncrementalMarkingRootMarkingVisitor visitor(this);
heap_->IterateStrongRoots(&visitor, VISIT_ONLY_STRONG);
// Ready to start incremental marking.

View File

@ -11595,9 +11595,8 @@ class SubStringAsciiSymbolKey : public HashTableKey {
public:
explicit SubStringAsciiSymbolKey(Handle<SeqOneByteString> string,
int from,
int length,
uint32_t seed)
: string_(string), from_(from), length_(length), seed_(seed) { }
int length)
: string_(string), from_(from), length_(length) { }
uint32_t Hash() {
ASSERT(length_ >= 0);
@ -11654,7 +11653,6 @@ class SubStringAsciiSymbolKey : public HashTableKey {
int from_;
int length_;
uint32_t hash_field_;
uint32_t seed_;
};
@ -12580,7 +12578,7 @@ MaybeObject* SymbolTable::LookupSubStringAsciiSymbol(
int from,
int length,
Object** s) {
SubStringAsciiSymbolKey key(str, from, length, GetHeap()->HashSeed());
SubStringAsciiSymbolKey key(str, from, length);
return LookupKey(&key, s);
}

View File

@ -96,7 +96,6 @@ class FunctionEntry BASE_EMBEDDED {
private:
Vector<unsigned> backing_;
bool owns_data_;
};

View File

@ -2440,11 +2440,9 @@ class FixedSpace : public PagedSpace {
FixedSpace(Heap* heap,
intptr_t max_capacity,
AllocationSpace id,
int object_size_in_bytes,
const char* name)
int object_size_in_bytes)
: PagedSpace(heap, max_capacity, id, NOT_EXECUTABLE),
object_size_in_bytes_(object_size_in_bytes),
name_(name) {
object_size_in_bytes_(object_size_in_bytes) {
page_extra_ = Page::kNonCodeObjectAreaSize % object_size_in_bytes;
}
@ -2461,9 +2459,6 @@ class FixedSpace : public PagedSpace {
private:
// The size of objects in this space.
int object_size_in_bytes_;
// The name of this space.
const char* name_;
};
@ -2474,7 +2469,7 @@ class MapSpace : public FixedSpace {
public:
// Creates a map space object with a maximum capacity.
MapSpace(Heap* heap, intptr_t max_capacity, AllocationSpace id)
: FixedSpace(heap, max_capacity, id, Map::kSize, "map"),
: FixedSpace(heap, max_capacity, id, Map::kSize),
max_map_space_pages_(kMaxMapPageIndex - 1) {
}
@ -2515,7 +2510,7 @@ class CellSpace : public FixedSpace {
public:
// Creates a property cell space object with a maximum capacity.
CellSpace(Heap* heap, intptr_t max_capacity, AllocationSpace id)
: FixedSpace(heap, max_capacity, id, JSGlobalPropertyCell::kSize, "cell")
: FixedSpace(heap, max_capacity, id, JSGlobalPropertyCell::kSize)
{}
virtual int RoundSizeDownToObjectAlignment(int size) {

View File

@ -210,8 +210,7 @@ class StoreBufferRebuildScope {
explicit StoreBufferRebuildScope(Heap* heap,
StoreBuffer* store_buffer,
StoreBufferCallback callback)
: heap_(heap),
store_buffer_(store_buffer),
: store_buffer_(store_buffer),
stored_state_(store_buffer->store_buffer_rebuilding_enabled_),
stored_callback_(store_buffer->callback_) {
store_buffer_->store_buffer_rebuilding_enabled_ = true;
@ -226,7 +225,6 @@ class StoreBufferRebuildScope {
}
private:
Heap* heap_;
StoreBuffer* store_buffer_;
bool stored_state_;
StoreBufferCallback stored_callback_;

View File

@ -17993,7 +17993,6 @@ class ThreadInterruptTest {
private:
ThreadInterruptTest* test_;
struct sigaction sa_;
};
i::Semaphore* sem_;

View File

@ -1015,7 +1015,6 @@ class TestRetainedObjectInfo : public v8::RetainedObjectInfo {
private:
bool disposed_;
int category_;
int hash_;
const char* group_label_;
const char* label_;

View File

@ -59,9 +59,9 @@ using ::v8::V8;
class KangarooThread : public v8::internal::Thread {
public:
KangarooThread(v8::Isolate* isolate,
v8::Handle<v8::Context> context, int value)
v8::Handle<v8::Context> context)
: Thread("KangarooThread"),
isolate_(isolate), context_(context), value_(value) {
isolate_(isolate), context_(context) {
}
void Run() {
@ -90,7 +90,6 @@ class KangarooThread : public v8::internal::Thread {
private:
v8::Isolate* isolate_;
Persistent<v8::Context> context_;
int value_;
};
// Migrates an isolate from one thread to another
@ -106,7 +105,7 @@ TEST(KangarooIsolates) {
CHECK_EQ(isolate, v8::internal::Isolate::Current());
CompileRun("function getValue() { return 30; }");
}
KangarooThread thread1(isolate, context, 1);
KangarooThread thread1(isolate, context);
thread1.Start();
thread1.Join();
}