stringify(_.util.encode(tokens), language);
				},

				tokenize: function(text, grammar, language) {
					var Token = _.Token;

					var strarr = [text];

					var rest = grammar.rest;

					if (rest) {
						for (var token in rest) {
							grammar[token] = rest[token];
						}

						delete grammar.rest;
					}

					tokenloop: for (var token in grammar) {
						if(!grammar.hasOwnProperty(token) || !grammar[token]) {
							continue;
						}

						var patterns = grammar[token];
						patterns = (_.util.