view src/luan/LuanElement.java @ 163:3c95a2291d64

make all module fns non-global and make global fns call module fns git-svn-id: https://luan-java.googlecode.com/svn/trunk@164 21e917c8-12df-6dd8-5cb6-c86387c605b9
author fschmidt@gmail.com <fschmidt@gmail.com@21e917c8-12df-6dd8-5cb6-c86387c605b9>
date Fri, 20 Jun 2014 09:32:36 +0000
parents 7e160d2f6d9c
children
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";
		}
	};
}