diff src/luan/modules/parsers/Csv.java @ 1562:b89212fd04b5

remove table.luan
author Franklin Schmidt <fschmidt@gmail.com>
date Sun, 08 Nov 2020 16:50:59 -0700
parents 27efb1fcbcb5
children
line wrap: on
line diff
--- a/src/luan/modules/parsers/Csv.java	Thu Nov 05 20:24:09 2020 -0700
+++ b/src/luan/modules/parsers/Csv.java	Sun Nov 08 16:50:59 2020 -0700
@@ -9,9 +9,9 @@
 
 public final class Csv {
 
-	public static LuanTable toList(Luan luan,String line) throws ParseException {
+	public static LuanTable toList(String line) throws ParseException {
 		try {
-			return new Csv(line).parse(luan);
+			return new Csv(line).parse();
 		} catch(LuanException e) {
 			throw new RuntimeException(e);
 		}
@@ -27,12 +27,12 @@
 		return new ParseException(parser,msg);
 	}
 
-	private LuanTable parse(Luan luan) throws ParseException, LuanException {
-		LuanTable list = new LuanTable(luan);
+	private LuanTable parse() throws ParseException, LuanException {
+		LuanTable list = new LuanTable();
 		while(true) {
 			Spaces();
 			String field = parseField();
-			list.put(list.rawLength()+1,field);
+			list.rawPut(list.rawLength()+1,field);
 			Spaces();
 			if( parser.endOfInput() )
 				return list;