Mercurial > hg > graal-compiler
diff graal/com.oracle.truffle.api/src/com/oracle/truffle/api/frame/FrameSlotImpl.java @ 9321:cd1a1d92b3e3
Frame API: Introduce FrameSlotKind.
author | Andreas Woess <andreas.woess@jku.at> |
---|---|
date | Thu, 25 Apr 2013 18:14:08 +0200 |
parents | 07f8d136a05e |
children | 5d91b0b67cba |
line wrap: on
line diff
--- a/graal/com.oracle.truffle.api/src/com/oracle/truffle/api/frame/FrameSlotImpl.java Thu Apr 25 23:17:58 2013 +0200 +++ b/graal/com.oracle.truffle.api/src/com/oracle/truffle/api/frame/FrameSlotImpl.java Thu Apr 25 18:14:08 2013 +0200 @@ -27,13 +27,13 @@ private final FrameDescriptor descriptor; private final Object identifier; private final int index; - private Class<?> type; + private FrameSlotKind kind; - protected FrameSlotImpl(FrameDescriptor descriptor, Object identifier, int index, Class<?> type) { + protected FrameSlotImpl(FrameDescriptor descriptor, Object identifier, int index, FrameSlotKind kind) { this.descriptor = descriptor; this.identifier = identifier; this.index = index; - this.type = type; + this.kind = kind; } public Object getIdentifier() { @@ -44,19 +44,19 @@ return index; } - public Class<?> getType() { - return type; + public FrameSlotKind getKind() { + return kind; } - public void setType(final Class<?> type) { - assert this.type != type; - this.type = type; + public void setKind(final FrameSlotKind kind) { + assert this.kind != kind; + this.kind = kind; this.descriptor.updateVersion(); } @Override public String toString() { - return "[" + index + "," + identifier + "," + type + "]"; + return "[" + index + "," + identifier + "," + kind + "]"; } @Override