8328139: Prefer 'override' to 'virtual' in subclasses of 'GCInitLogger'

Reviewed-by: kbarrett, jsjolen
This commit is contained in:
Guoxiong Li 2024-03-14 15:01:44 +00:00
parent 792fc9d114
commit 51381bb13c
3 changed files with 8 additions and 7 deletions

View File

@ -1,4 +1,5 @@
/*
* Copyright (c) 2024, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 2020, Red Hat, Inc. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
@ -29,7 +30,7 @@
class EpsilonInitLogger : public GCInitLogger {
protected:
virtual void print_gc_specific();
void print_gc_specific() override;
public:
static void print();

View File

@ -1,5 +1,5 @@
/*
* Copyright (c) 2020, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 2020, 2024, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@ -29,9 +29,9 @@
class G1InitLogger : public GCInitLogger {
protected:
virtual void print_heap();
virtual void print_workers();
virtual void print_gc_specific();
void print_heap() override;
void print_workers() override;
void print_gc_specific() override;
public:
static void print();
};

View File

@ -1,5 +1,5 @@
/*
* Copyright (c) 2020, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 2020, 2024, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@ -29,7 +29,7 @@
class ParallelInitLogger : public GCInitLogger {
protected:
virtual void print_heap();
void print_heap() override;
public:
static void print();
};