浏览代码

Add parseError

Pascal Peridont 19 年之前
父节点
当前提交
ff7faaf2e6
共有 2 个文件被更改,包括 4 次插入2 次删除
  1. 2 0
      std/mtwin/mail/Exception.hx
  2. 2 2
      std/mtwin/mail/ImapEnvelope.hx

+ 2 - 0
std/mtwin/mail/Exception.hx

@@ -36,4 +36,6 @@ enum Exception {
 	UnknowResponse(r:String);
 	BadResponse(r:String);
 	ImapFetchError(id:Int);
+
+	ParseError(s:String);
 }

+ 2 - 2
std/mtwin/mail/ImapEnvelope.hx

@@ -135,8 +135,8 @@ class ImapEnvelope {
 					var bs = b.toString();
 					if( bs == "NIL" )
 						addElement( null );
-					//else
-						//throw ParseError(bs);
+					else
+						throw ParseError(bs);
 			}
 		}
 		ret.__length = p;