var IS_CLASS = 0
var IS_FUN = 1
var IS_VAR = 2
var IS_CALL = 3
var IS_LR = 4
var IS_OP = 5
var IS_NULL = 6
var IS_RETURN = 7
var IS_IF = 8
var IS_FOR = 9
var IS_WHILE = 10
var IS_TRY = 11
var IS_NEW = 12
var IS_BREAK = 13
var IS_CONV = 14
var IS_ARR = 15
var IS_ARR_ACT = 16
var IS_SWITCH = 17
var IS_CASE = 18
var IS_NULL = 19
var IS_DEF = 20
var IS_BLOCK = 21
var JNULL = new J_NULL()

function J_CLASS(na,ex,vi,va,fu,s,imp,t){
	this.is = IS_CLASS
	this.name = na
	this.extends = ex
	this.vis = vi
	this.vars = va
	this.funs = fu
	this.static = s
	this.imports = imp
	this.tok = t
	this.impcls = []
	this.implement = []
	this.interface = false
	this.vardef
	this.generic
}
function J_ASSIGNS(){
	//this.def = []
	this.inst = []
	this.stat = []
}
function J_FUNCTION(na,ty,vis,stat,ar,va,st,t){
	this.is = IS_FUN
	this.name = na
	this.type = ty
	this.vis = vis
	this.static = stat
	this.args = ar
	this.vars = va
	this.stats = st
	this.tok = t
}
function J_VARIABLE(na,ty,vi,va,t,st,fin,emdef,dep){
	this.is = IS_VAR
	this.name = na
	this.type = ty
	this.vis = vi
	this.value = va
	this.tok = t
	this.fin = (fin!=null?fin:false)
	this.emdef = emdef
	this.dependents = dep
	this.static = st
}
function J_VALUE(ty,va,t){
	this.is = IS_VAR
	this.type = ty
	this.value = va
	this.tok = t
}
function J_CALL(fu,ar,cu,su,arr,t,g){
	this.is = IS_CALL
	this.fun = fu
	this.args = ar
	this.custom = cu
	this.subcall = su
	this.arr = arr
	this.tok = t
	this.gen = g
}
function J_LR(le,ri,pre,t){
	this.is = IS_LR
	this.left = le
	this.right = ri
	this.pre = pre
	this.tok = t
}
function J_OP(op,le,ri,t){
	this.is = IS_OP
	this.op = op
	this.left = le
	this.right = ri
	this.tok = t
}
function J_RETURN(fu,t){
	this.is = IS_RETURN
	this.fun = fu
	this.tok = t
}
function J_IF(co,th,el,t){
	this.is = IS_IF
	this.con = co
	this.thenf = th
	this.elsef = el
	this.tok = t;
}
function J_FOR(va,de,co,i,d,t){
	this.is = IS_FOR
	this.vars = va
	this.def = de
	this.con = co
	this.inc = i
	this.dof = d
	this.tok = t
}
function J_WHILE(co,d,s,t){
	this.is = IS_WHILE
	this.con = co
	this.dof = d
	this.skip = s
	this.tok = t
}
function J_TRY(tr,ca,fi,t){
	this.is = IS_TRY
	this.tryf = tr
	this.catches = ca
	this.finallyf = fi
	this.tok = t
}
function J_NEW(cls,arr,str,ty,t){
	this.is = IS_NEW
	this.cls = cls
	this.arr = arr
	this.str = str
	this.type = ty
	this.tok = t
}
function J_BREAK(brk,t){
	this.is = IS_BREAK
	this.brk = brk
	this.tok = t
}
function J_CONV(ty,st,t){
	this.is = IS_CONV
	this.type = ty
	this.stat = st
	this.tok = t
}
function J_FOLDER(){}
function J_ARR(arr,type,t){
	this.is = IS_ARR
	this.arr = arr
	this.type=type
	this.tok = t
}
function J_ARR_ACT(arr,type,t){
	this.is = IS_ARR_ACT
	this.arr = arr
	this.type=type
	this.tok = t
}
function J_SWITCH(co,ca,t){
	this.is = IS_SWITCH
	this.con = co
	this.cases = ca
	this.tok = t
}
function J_CASE(co,st,t){
	this.is = IS_CASE
	this.con = co
	this.stats = st
	this.tok = t
}
function J_NULL(t){
	this.is = IS_NULL
	this.name = "Object"
	this.tok = t
}
function J_DEF(c,p,t){
	this.is = IS_DEF
	this.va = c
	this.prim = p
	this.tok = t
}
function J_BLOCK(v,s){
	this.is = IS_BLOCK
	this.vars = v
	this.stats = s
}
