lp: correct rules for whether an unknown field can be ignored

Add TLV-TYPE to exception output for unignorable unknown and unrepeatable fields

refs #3884

Change-Id: I52c6cc2b6b5363432d8cc5bf60407ccf6ece7dc0
diff --git a/src/lp/packet.cpp b/src/lp/packet.cpp
index 8d62ed9..7b71c72 100644
--- a/src/lp/packet.cpp
+++ b/src/lp/packet.cpp
@@ -1,6 +1,6 @@
 /* -*- Mode:C++; c-file-style:"gnu"; indent-tabs-mode:nil; -*- */
 /**
- * Copyright (c) 2013-2015 Regents of the University of California.
+ * Copyright (c) 2013-2016 Regents of the University of California.
  *
  * This file is part of ndn-cxx library (NDN C++ library with eXperimental eXtensions).
  *
@@ -109,12 +109,12 @@
     detail::FieldInfo info(element.type());
 
     if (!info.isRecognized && !info.canIgnore) {
-      BOOST_THROW_EXCEPTION(Error("unrecognized field cannot be ignored"));
+      BOOST_THROW_EXCEPTION(Error("unrecognized field " + to_string(element.type()) + " cannot be ignored"));
     }
 
     if (!isFirst) {
       if (info.tlvType == prev.tlvType && !info.isRepeatable) {
-        BOOST_THROW_EXCEPTION(Error("non-repeatable field cannot be repeated"));
+        BOOST_THROW_EXCEPTION(Error("non-repeatable field " + to_string(element.type()) + " cannot be repeated"));
       }
 
       else if (info.tlvType != prev.tlvType && !detail::compareFieldSortOrder(prev, info)) {