view core/src/luan/LuanElement.java @ 400:8f1be9704726

change LuanState.newStandard() to newInstance() which doesn't preload anything
author Franklin Schmidt <fschmidt@gmail.com>
date Tue, 28 Apr 2015 13:12:17 -0600
parents 3dcb0f9bee82
children b48cfa14ba60
line wrap: on
line source

package luan;


public abstract class LuanElement {

	final String toString(String fnName) {
		String s = location();
		if( fnName != null )
			s += ": in function '" + fnName + "'";
		return s;
	}

	abstract String location();

	public static final LuanElement JAVA = new LuanElement(){
		@Override String location() {
			return "Java";
		}
	};
}