Examples of slowPush()


Examples of org.jruby.truffle.runtime.core.RubyArray.slowPush()

        assert arrayObject instanceof RubyArray : getSourceSection();

        final RubyArray originalArray = (RubyArray) arrayObject;

        final RubyArray newArray = new RubyArray(getContext().getCoreLibrary().getArrayClass(), originalArray.slowToArray(), originalArray.getSize());
        newArray.slowPush(pushed.execute(frame));
        return newArray;
    }

}
View Full Code Here

Examples of org.jruby.truffle.runtime.core.RubyArray.slowPush()

                for (Map.Entry<Object, Object> entry : store.entrySet()) {
                    if (CompilerDirectives.inInterpreter()) {
                        count++;
                    }

                    result.slowPush(yield(frame, block, entry.getKey(), entry.getValue()));
                }
            } finally {
                if (CompilerDirectives.inInterpreter()) {
                    ((RubyRootNode) getRootNode()).reportLoopCountThroughBlocks(count);
                }
View Full Code Here

Examples of org.jruby.truffle.runtime.core.RubyArray.slowPush()

                }
            }
            for (RubyMethod method : methods) {
                if (method.getVisibility() == Visibility.PRIVATE){
                    RubySymbol m = getContext().newSymbol(method.getName());
                    array.slowPush(m);
                }
            }
            return array;
        }
    }
View Full Code Here

Examples of org.jruby.truffle.runtime.core.RubyArray.slowPush()

                }
            }
            for (RubyMethod method : methods) {
                if (method.getVisibility() == Visibility.PUBLIC){
                    RubySymbol m = getContext().newSymbol(method.getName());
                    array.slowPush(m);
                }
            }
            return array;
        }
    }
View Full Code Here

Examples of org.jruby.truffle.runtime.core.RubyArray.slowPush()

            final RubyArray array = new RubyArray(getContext().getCoreLibrary().getArrayClass());
            for (RubyMethod method : methods.values()) {
                if (method.getVisibility() != Visibility.PRIVATE && !method.isUndefined()) {
                    // TODO(CS): shoudln't be using this
                    array.slowPush(getContext().newSymbol(method.getName()));
                }
            }

            return array;
        }
View Full Code Here

Examples of org.jruby.truffle.runtime.core.RubyArray.slowPush()

                Files.walkFileTree(FileSystems.getDefault().getPath(prefix), new SimpleFileVisitor<Path>() {

                    @Override
                    public FileVisitResult visitFile(Path file, BasicFileAttributes attrs) throws IOException {
                        if (matcher.matches(file)) {
                            array.slowPush(context.makeString(file.toString()));
                        }

                        return FileVisitResult.CONTINUE;
                    }
View Full Code Here

Examples of org.jruby.truffle.runtime.core.RubyArray.slowPush()

            notDesignedForCompilation();

            final RubyArray array = new RubyArray(getContext().getCoreLibrary().getArrayClass());

            for (RubySymbol s : getContext().getSymbolTable().getSymbolsTable().values()){
                array.slowPush(s);
            }
            return array;
        }

    }
View Full Code Here

Examples of org.jruby.truffle.runtime.core.RubyArray.slowPush()

            final RubyArray array = new RubyArray(getContext().getCoreLibrary().getArrayClass());

            // TODO(cs): handle inherit
            for (String constant : module.getConstants().keySet()) {
                array.slowPush(getContext().newSymbol(constant));
            }

            return array;
        }
    }
View Full Code Here

Examples of org.jruby.truffle.runtime.core.RubyArray.slowPush()

            } else {
                methods = self.getSingletonClass(this).getMethods().values();
            }

            for (RubyMethod method : methods) {
                array.slowPush(RubySymbol.newSymbol(self.getContext(), method.getName()));
            }

            return array;
        }
View Full Code Here

Examples of org.jruby.truffle.runtime.core.RubyArray.slowPush()

            Arrays.sort(instanceVariableNames);

            final RubyArray array = new RubyArray(getContext().getCoreLibrary().getArrayClass());

            for (String name : instanceVariableNames) {
                array.slowPush(RubyString.fromJavaString(getContext().getCoreLibrary().getStringClass(), name));
            }

            return array;
        }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.