/*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* under the terms of the GNU General Public License version 2 only, as
* published by the Free Software Foundation.
*
* This code is distributed in the hope that it will be useful, but WITHOUT
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
* FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
* version 2 for more details (a copy is included in the LICENSE file that
* accompanied this code).
*
* You should have received a copy of the GNU General Public License version
* 2 along with this work; if not, write to the Free Software Foundation,
* Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
*
* Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
* or visit www.oracle.com if you need additional information or have any
* questions.
*
*/
#include "precompiled.hpp"
#include "oops/oop.inline.hpp"
#include "oops/symbol.hpp"
#include "memory/allocation.inline.hpp"
for (int i = 0; i < _length; i++) {
byte_at_put(i, name[i]);
}
}
return res;
}
return res;
}
// ------------------------------------------------------------------
// Symbol::equals
//
// Compares the symbol with a string of the given length.
int l = utf8_length();
if (l != len) return false;
while (l-- > 0) {
return false;
}
return true;
}
// ------------------------------------------------------------------
// Symbol::starts_with
//
// Tests if the symbol starts with the specified prefix of the given
// length.
if (len > utf8_length()) return false;
while (len-- > 0) {
return false;
}
return true;
}
// ------------------------------------------------------------------
// Symbol::index_of
//
// Finds if the given string is a substring of this symbol's utf8 bytes.
// Return -1 on failure. Otherwise return the first index where str occurs.
if (len <= 0) return 0;
return -1;
return -1; // not found
}
return -1;
}
if (size > 0) {
for (int i = 0; i < len; i++) {
}
}
return buf;
}
}
char* str;
} else {
}
}
} else {
}
}
}
if (length > 0) {
}
return result;
}
if (size > 0) {
// Turn all '/'s into '.'s (also for array klasses)
}
}
return str;
} else {
return buf;
}
}
// Turn all '/'s into '.'s (also for array klasses)
}
}
return str;
}
if (this == NULL) {
} else {
}
}
// The print_value functions are present in all builds, to support the
// disassembler and error reporting.
if (this == NULL) {
} else {
for (int i = 0; i < utf8_length(); i++) {
}
}
}
// SymbolTable prints this in its statistics