src/hotspot/share/gc/z/zArray.inline.hpp
changeset 58084 cddef3bde924
parent 54173 e6a92f2f37a9
child 58707 810409af12f1
equal deleted inserted replaced
58083:9046db64ca39 58084:cddef3bde924
     1 /*
     1 /*
     2  * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved.
     2  * Copyright (c) 2015, 2019, Oracle and/or its affiliates. All rights reserved.
     3  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
     3  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
     4  *
     4  *
     5  * This code is free software; you can redistribute it and/or modify it
     5  * This code is free software; you can redistribute it and/or modify it
     6  * under the terms of the GNU General Public License version 2 only, as
     6  * under the terms of the GNU General Public License version 2 only, as
     7  * published by the Free Software Foundation.
     7  * published by the Free Software Foundation.
    34     _size(0),
    34     _size(0),
    35     _capacity(0) {}
    35     _capacity(0) {}
    36 
    36 
    37 template <typename T>
    37 template <typename T>
    38 inline ZArray<T>::~ZArray() {
    38 inline ZArray<T>::~ZArray() {
    39   if (_array != NULL) {
    39   FREE_C_HEAP_ARRAY(T, _array);
    40     FREE_C_HEAP_ARRAY(T, _array);
       
    41   }
       
    42 }
    40 }
    43 
    41 
    44 template <typename T>
    42 template <typename T>
    45 inline size_t ZArray<T>::size() const {
    43 inline size_t ZArray<T>::size() const {
    46   return _size;
    44   return _size;