}
Outer: for (int i = 0; i < loadPath.size(); i++) {
// TODO this is really inefficient, and potentially a problem everytime anyone require's something.
// we should try to make LoadPath a special array object.
RubyString entryString = loadPath.eltInternal(i).convertToString();
String loadPathEntry = entryString.asJavaString();
if (loadPathEntry.equals(".") || loadPathEntry.equals("")) {
foundResource = tryResourceFromCWD(state, baseName, suffixType);
if (foundResource != null) {