util: remove ndn::optional, use std::optional directly

Change-Id: I503e8f250e80e0ff7708070effc2e84e3b38b3b7
diff --git a/tests/unit/face.t.cpp b/tests/unit/face.t.cpp
index 5fdfd1c..0ee95b4 100644
--- a/tests/unit/face.t.cpp
+++ b/tests/unit/face.t.cpp
@@ -1,6 +1,6 @@
 /* -*- Mode:C++; c-file-style:"gnu"; indent-tabs-mode:nil; -*- */
 /*
- * Copyright (c) 2013-2022 Regents of the University of California.
+ * Copyright (c) 2013-2023 Regents of the University of California.
  *
  * This file is part of ndn-cxx library (NDN C++ library with eXperimental eXtensions).
  *
@@ -427,14 +427,14 @@
 
   BOOST_CHECK_EQUAL(face.sentNacks.size(), 0);
 
-  face.put(makeNack(*makeInterest("/unsolicited", false, nullopt, 18645250),
+  face.put(makeNack(*makeInterest("/unsolicited", false, std::nullopt, 18645250),
                     lp::NackReason::NO_ROUTE));
   advanceClocks(10_ms);
   BOOST_CHECK_EQUAL(face.sentNacks.size(), 0); // unsolicited Nack would not be sent
 
-  auto interest1 = makeInterest("/Hello/World", false, nullopt, 14247162);
+  auto interest1 = makeInterest("/Hello/World", false, std::nullopt, 14247162);
   face.receive(*interest1);
-  auto interest2 = makeInterest("/another/prefix", false, nullopt, 92203002);
+  auto interest2 = makeInterest("/another/prefix", false, std::nullopt, 92203002);
   face.receive(*interest2);
   advanceClocks(10_ms);
 
@@ -465,7 +465,7 @@
   face.setInterestFilter("/", bind([&] { hasInterest2 = true; }));
   advanceClocks(10_ms);
 
-  auto interest = makeInterest("/A", false, nullopt, 14333271);
+  auto interest = makeInterest("/A", false, std::nullopt, 14333271);
   face.receive(*interest);
   advanceClocks(10_ms);
   BOOST_CHECK(hasInterest1);
@@ -496,7 +496,7 @@
   face.setInterestFilter(InterestFilter("/").allowLoopback(false),
     bind([] { BOOST_ERROR("Unexpected Interest on second InterestFilter"); }));
 
-  auto interest = makeInterest("/A", false, nullopt, 28395852);
+  auto interest = makeInterest("/A", false, std::nullopt, 28395852);
   face.expressInterest(*interest,
                        bind([] { BOOST_FAIL("Unexpected data"); }),
                        [&] (const Interest&, const lp::Nack& nack) {
diff --git a/tests/unit/interest.t.cpp b/tests/unit/interest.t.cpp
index 9e71cfb..684f097 100644
--- a/tests/unit/interest.t.cpp
+++ b/tests/unit/interest.t.cpp
@@ -1,6 +1,6 @@
 /* -*- Mode:C++; c-file-style:"gnu"; indent-tabs-mode:nil; -*- */
 /*
- * Copyright (c) 2013-2022 Regents of the University of California.
+ * Copyright (c) 2013-2023 Regents of the University of California.
  *
  * This file is part of ndn-cxx library (NDN C++ library with eXperimental eXtensions).
  *
@@ -57,11 +57,11 @@
   BOOST_CHECK_EQUAL(i.getForwardingHint().empty(), true);
   BOOST_CHECK_EQUAL(i.hasNonce(), false);
   BOOST_CHECK_EQUAL(i.getInterestLifetime(), DEFAULT_INTEREST_LIFETIME);
-  BOOST_CHECK(i.getHopLimit() == nullopt);
+  BOOST_CHECK(i.getHopLimit() == std::nullopt);
   BOOST_CHECK_EQUAL(i.hasApplicationParameters(), false);
   BOOST_CHECK_EQUAL(i.getApplicationParameters().isValid(), false);
   BOOST_CHECK_EQUAL(i.isParametersDigestValid(), true);
-  BOOST_CHECK(i.getSignatureInfo() == nullopt);
+  BOOST_CHECK(i.getSignatureInfo() == std::nullopt);
   BOOST_CHECK_EQUAL(i.getSignatureValue().isValid(), false);
   BOOST_CHECK_EQUAL(i.isSigned(), false);
 }
@@ -96,10 +96,10 @@
   BOOST_CHECK_EQUAL(i2.hasNonce(), true);
   BOOST_CHECK_EQUAL(i2.getNonce(), 0x01020304);
   BOOST_CHECK_EQUAL(i2.getInterestLifetime(), DEFAULT_INTEREST_LIFETIME);
-  BOOST_CHECK(i2.getHopLimit() == nullopt);
+  BOOST_CHECK(i2.getHopLimit() == std::nullopt);
   BOOST_CHECK_EQUAL(i2.hasApplicationParameters(), false);
   BOOST_CHECK_EQUAL(i2.getApplicationParameters().isValid(), false);
-  BOOST_CHECK(i2.getSignatureInfo() == nullopt);
+  BOOST_CHECK(i2.getSignatureInfo() == std::nullopt);
   BOOST_CHECK_EQUAL(i2.getSignatureValue().isValid(), false);
   BOOST_CHECK_EQUAL(i2.isSigned(), false);
 }
@@ -140,10 +140,10 @@
   BOOST_CHECK_EQUAL(i2.hasNonce(), true);
   BOOST_CHECK_EQUAL(i2.getNonce(), 0x1);
   BOOST_CHECK_EQUAL(i2.getInterestLifetime(), DEFAULT_INTEREST_LIFETIME);
-  BOOST_CHECK(i2.getHopLimit() == nullopt);
+  BOOST_CHECK(i2.getHopLimit() == std::nullopt);
   BOOST_CHECK_EQUAL(i2.hasApplicationParameters(), true);
   BOOST_CHECK_EQUAL(i2.getApplicationParameters(), "2404C0C1C2C3"_block);
-  BOOST_CHECK(i2.getSignatureInfo() == nullopt);
+  BOOST_CHECK(i2.getSignatureInfo() == std::nullopt);
   BOOST_CHECK_EQUAL(i2.getSignatureValue().isValid(), false);
   BOOST_CHECK_EQUAL(i2.isSigned(), false);
 }
@@ -402,7 +402,7 @@
   BOOST_CHECK_EQUAL(i.getForwardingHint().empty(), true);
   BOOST_CHECK_EQUAL(i.hasNonce(), false);
   BOOST_CHECK_EQUAL(i.getInterestLifetime(), DEFAULT_INTEREST_LIFETIME);
-  BOOST_CHECK(i.getHopLimit() == nullopt);
+  BOOST_CHECK(i.getHopLimit() == std::nullopt);
   BOOST_CHECK_EQUAL(i.hasApplicationParameters(), false);
   BOOST_CHECK_EQUAL(i.getApplicationParameters().isValid(), false);
 
@@ -422,7 +422,7 @@
   BOOST_CHECK_EQUAL(i.getForwardingHint().empty(), true);
   BOOST_CHECK_EQUAL(i.hasNonce(), false);
   BOOST_CHECK_EQUAL(i.getInterestLifetime(), DEFAULT_INTEREST_LIFETIME);
-  BOOST_CHECK(i.getHopLimit() == nullopt);
+  BOOST_CHECK(i.getHopLimit() == std::nullopt);
   BOOST_CHECK_EQUAL(i.hasApplicationParameters(), false);
   BOOST_CHECK_EQUAL(i.getApplicationParameters().isValid(), false);
 }
@@ -789,7 +789,7 @@
   BOOST_CHECK_EQUAL(i2.getNonce(), 2);
   BOOST_CHECK_EQUAL(i1.getNonce(), 1); // should not affect i1's Nonce (Bug #4168)
 
-  i2.setNonce(nullopt);
+  i2.setNonce(std::nullopt);
   BOOST_CHECK(!i2.hasNonce());
 }
 
@@ -852,11 +852,11 @@
 BOOST_AUTO_TEST_CASE(SetHopLimit)
 {
   Interest i;
-  BOOST_CHECK(i.getHopLimit() == nullopt);
+  BOOST_CHECK(i.getHopLimit() == std::nullopt);
   i.setHopLimit(42);
   BOOST_CHECK(i.getHopLimit() == 42);
-  i.setHopLimit(nullopt);
-  BOOST_CHECK(i.getHopLimit() == nullopt);
+  i.setHopLimit(std::nullopt);
+  BOOST_CHECK(i.getHopLimit() == std::nullopt);
 }
 
 BOOST_AUTO_TEST_CASE(SetApplicationParameters)
@@ -901,7 +901,7 @@
     return e.what() == "InterestSignatureInfo must be present to set InterestSignatureValue"s;
   });
 
-  BOOST_CHECK(i.getSignatureInfo() == nullopt);
+  BOOST_CHECK(i.getSignatureInfo() == std::nullopt);
   BOOST_CHECK_EQUAL(i.getSignatureValue().isValid(), false);
   BOOST_CHECK_EQUAL(i.isSigned(), false);
 
@@ -1010,7 +1010,7 @@
   BOOST_CHECK(i.getSignatureInfo() == si);
 
   i.unsetApplicationParameters(); // removes ParametersSha256DigestComponent and InterestSignatureInfo
-  BOOST_CHECK(i.getSignatureInfo() == nullopt);
+  BOOST_CHECK(i.getSignatureInfo() == std::nullopt);
   BOOST_CHECK_EQUAL(i.getSignatureValue().isValid(), false);
   BOOST_CHECK_EQUAL(i.getName(), "/A/B/C");
 
@@ -1157,7 +1157,7 @@
 
   i.setCanBePrefix(false);
   i.setMustBeFresh(false);
-  i.setHopLimit(nullopt);
+  i.setHopLimit(std::nullopt);
   i.setApplicationParameters("2402CAFE"_block);
   BOOST_CHECK_EQUAL(i.toUri(),
                     "/foo/params-sha256=8621f5e8321f04104640c8d02877d7c5142cad6e203c5effda1783b1a0e476d6"
diff --git a/tests/unit/meta-info.t.cpp b/tests/unit/meta-info.t.cpp
index af8416a..19fa2d3 100644
--- a/tests/unit/meta-info.t.cpp
+++ b/tests/unit/meta-info.t.cpp
@@ -1,6 +1,6 @@
 /* -*- Mode:C++; c-file-style:"gnu"; indent-tabs-mode:nil; -*- */
 /*
- * Copyright (c) 2013-2022 Regents of the University of California.
+ * Copyright (c) 2013-2023 Regents of the University of California.
  *
  * This file is part of ndn-cxx library (NDN C++ library with eXperimental eXtensions).
  *
@@ -20,7 +20,6 @@
  */
 
 #include "ndn-cxx/meta-info.hpp"
-#include "ndn-cxx/data.hpp"
 
 #include "tests/boost-test.hpp"
 
@@ -35,7 +34,7 @@
   MetaInfo a("1406 type=180100 freshness=190100"_block);
   BOOST_CHECK_EQUAL(a.getType(), tlv::ContentType_Blob);
   BOOST_CHECK_EQUAL(a.getFreshnessPeriod(), 0_ms);
-  BOOST_CHECK(a.getFinalBlock() == nullopt);
+  BOOST_CHECK(a.getFinalBlock() == std::nullopt);
 
   MetaInfo b;
   BOOST_CHECK_NE(a.wireEncode(), b.wireEncode());
diff --git a/tests/unit/security/certificate-cache.t.cpp b/tests/unit/security/certificate-cache.t.cpp
index 8c715eb..51aa72b 100644
--- a/tests/unit/security/certificate-cache.t.cpp
+++ b/tests/unit/security/certificate-cache.t.cpp
@@ -1,6 +1,6 @@
 /* -*- Mode:C++; c-file-style:"gnu"; indent-tabs-mode:nil; -*- */
 /*
- * Copyright (c) 2013-2022 Regents of the University of California.
+ * Copyright (c) 2013-2023 Regents of the University of California.
  *
  * This file is part of ndn-cxx library (NDN C++ library with eXperimental eXtensions).
  *
@@ -43,7 +43,7 @@
   }
 
   void
-  checkFindByInterest(const Name& name, bool canBePrefix, optional<Certificate> expected) const
+  checkFindByInterest(const Name& name, bool canBePrefix, std::optional<Certificate> expected) const
   {
     Interest interest(name);
     interest.setCanBePrefix(canBePrefix);
@@ -95,10 +95,10 @@
   checkFindByInterest(cert.getIdentity(), true, cert);
   checkFindByInterest(cert.getKeyName(), true, cert);
   checkFindByInterest(cert.getName(), false, cert);
-  checkFindByInterest(Name(cert.getName()).appendVersion(), true, nullopt);
+  checkFindByInterest(Name(cert.getName()).appendVersion(), true, std::nullopt);
 
   advanceClocks(12_s);
-  checkFindByInterest(cert.getIdentity(), true, nullopt);
+  checkFindByInterest(cert.getIdentity(), true, std::nullopt);
 }
 
 BOOST_AUTO_TEST_SUITE_END() // TestCertificateCache
diff --git a/tests/unit/security/certificate.t.cpp b/tests/unit/security/certificate.t.cpp
index f113ca9..37243d6 100644
--- a/tests/unit/security/certificate.t.cpp
+++ b/tests/unit/security/certificate.t.cpp
@@ -1,6 +1,6 @@
 /* -*- Mode:C++; c-file-style:"gnu"; indent-tabs-mode:nil; -*- */
 /*
- * Copyright (c) 2013-2022 Regents of the University of California.
+ * Copyright (c) 2013-2023 Regents of the University of California.
  *
  * This file is part of ndn-cxx library (NDN C++ library with eXperimental eXtensions).
  *
@@ -366,7 +366,7 @@
   sigInfo.removeCustomTlv(tlv::AdditionalDescription);
   sigInfo.addCustomTlv(makeStringBlock(tlv::ValidityPeriod, "malformed"));
   sigInfo.setSignatureType(tlv::DigestSha256);
-  sigInfo.setKeyLocator(nullopt);
+  sigInfo.setKeyLocator(std::nullopt);
   Certificate cert6(cert3);
   cert6.setSignatureInfo(sigInfo);
   BOOST_CHECK_EQUAL(boost::lexical_cast<std::string>(cert6), expected6);
diff --git a/tests/unit/security/key-chain.t.cpp b/tests/unit/security/key-chain.t.cpp
index 98a0721..9bd97af 100644
--- a/tests/unit/security/key-chain.t.cpp
+++ b/tests/unit/security/key-chain.t.cpp
@@ -1,6 +1,6 @@
 /* -*- Mode:C++; c-file-style:"gnu"; indent-tabs-mode:nil; -*- */
 /*
- * Copyright (c) 2013-2022 Regents of the University of California.
+ * Copyright (c) 2013-2023 Regents of the University of California.
  *
  * This file is part of ndn-cxx library (NDN C++ library with eXperimental eXtensions).
  *
@@ -427,7 +427,7 @@
 
   const uint32_t expectedSigType = SignatureTypeTlvValue;
   const bool shouldHaveKeyLocator = true;
-  const optional<KeyLocator> expectedKeyLocator = cert.getName();
+  const std::optional<KeyLocator> expectedKeyLocator = cert.getName();
 
   bool
   verify(const SigningInfo&) const
@@ -504,7 +504,7 @@
 
   const uint32_t expectedSigType = SignatureTypeTlvValue;
   const bool shouldHaveKeyLocator = true;
-  const optional<KeyLocator> expectedKeyLocator = nullopt; // don't check KeyLocator value
+  const std::optional<KeyLocator> expectedKeyLocator = std::nullopt; // don't check KeyLocator value
 
   bool
   verify(const SigningInfo& si) const
@@ -524,12 +524,12 @@
 
   const uint32_t expectedSigType = tlv::DigestSha256;
   const bool shouldHaveKeyLocator = false;
-  const optional<KeyLocator> expectedKeyLocator = nullopt;
+  const std::optional<KeyLocator> expectedKeyLocator = std::nullopt;
 
   bool
   verify(const SigningInfo&) const
   {
-    return verifySignature(this->packet, nullopt);
+    return verifySignature(this->packet, std::nullopt);
   }
 };
 
@@ -591,7 +591,8 @@
   }
 
   void
-  checkKeyLocatorName(const Certificate& cert, const optional<Name>& klName = nullopt) const
+  checkKeyLocatorName(const Certificate& cert,
+                      const std::optional<Name>& klName = std::nullopt) const
   {
     auto kl = cert.getKeyLocator();
     if (!kl.has_value()) {
diff --git a/tests/unit/security/trust-anchor-container.t.cpp b/tests/unit/security/trust-anchor-container.t.cpp
index 19d6867..09825db 100644
--- a/tests/unit/security/trust-anchor-container.t.cpp
+++ b/tests/unit/security/trust-anchor-container.t.cpp
@@ -1,6 +1,6 @@
 /* -*- Mode:C++; c-file-style:"gnu"; indent-tabs-mode:nil; -*- */
 /*
- * Copyright (c) 2013-2022 Regents of the University of California.
+ * Copyright (c) 2013-2023 Regents of the University of California.
  *
  * This file is part of ndn-cxx library (NDN C++ library with eXperimental eXtensions).
  *
@@ -20,7 +20,6 @@
  */
 
 #include "ndn-cxx/security/trust-anchor-container.hpp"
-#include "ndn-cxx/util/io.hpp"
 
 #include "tests/boost-test.hpp"
 #include "tests/key-chain-fixture.hpp"
@@ -61,7 +60,7 @@
   }
 
   void
-  checkFindByInterest(const Name& name, bool canBePrefix, optional<Certificate> expected) const
+  checkFindByInterest(const Name& name, bool canBePrefix, std::optional<Certificate> expected) const
   {
     Interest interest(name);
     interest.setCanBePrefix(canBePrefix);
@@ -172,7 +171,7 @@
   checkFindByInterest(identity1.getName().getPrefix(-1), true, cert1);
   checkFindByInterest(cert1.getKeyName(), true, cert1);
   checkFindByInterest(cert1.getName(), false, cert1);
-  checkFindByInterest(Name(identity1.getName()).appendVersion(), true, nullopt);
+  checkFindByInterest(Name(identity1.getName()).appendVersion(), true, std::nullopt);
 
   auto makeIdentity1Cert = [=] (const std::string& issuerId) {
     auto key = identity1.getDefaultKey();
diff --git a/tests/unit/security/validation-policy-command-interest.t.cpp b/tests/unit/security/validation-policy-command-interest.t.cpp
index 604c60d..971b509 100644
--- a/tests/unit/security/validation-policy-command-interest.t.cpp
+++ b/tests/unit/security/validation-policy-command-interest.t.cpp
@@ -1,6 +1,6 @@
 /* -*- Mode:C++; c-file-style:"gnu"; indent-tabs-mode:nil; -*- */
 /*
- * Copyright (c) 2013-2022 Regents of the University of California.
+ * Copyright (c) 2013-2023 Regents of the University of California.
  *
  * This file is part of ndn-cxx library (NDN C++ library with eXperimental eXtensions).
  *
@@ -64,16 +64,16 @@
 {
 protected:
   Interest
-  makeCommandInterest(const Identity& identity, SignedInterestFormat format = SignedInterestFormat::V02)
+  makeCommandInterest(const Identity& id, SignedInterestFormat format = SignedInterestFormat::V02)
   {
-    Name name = identity.getName();
+    Name name = id.getName();
     name.append("CMD");
     switch (format) {
       case SignedInterestFormat::V02:
-        return m_signer.makeCommandInterest(name, signingByIdentity(identity));
+        return m_signer.makeCommandInterest(name, signingByIdentity(id));
       case SignedInterestFormat::V03: {
         Interest interest(name);
-        m_signer.makeSignedInterest(interest, signingByIdentity(identity));
+        m_signer.makeSignedInterest(interest, signingByIdentity(id));
         return interest;
       }
     }
@@ -198,7 +198,7 @@
 {
   auto i1 = makeCommandInterest(identity, SignedInterestFormat::V03);
   auto si = i1.getSignatureInfo().value();
-  si.setTime(nullopt);
+  si.setTime(std::nullopt);
   i1.setSignatureInfo(si);
   VALIDATE_FAILURE(i1, "Should fail (timestamp is missing)");
   BOOST_TEST(lastError.getCode() == ValidationError::POLICY_ERROR);
@@ -218,7 +218,7 @@
 {
   auto i1 = makeCommandInterest(identity, SignedInterestFormat::V03);
   auto si = i1.getSignatureInfo().value();
-  si.setKeyLocator(nullopt);
+  si.setKeyLocator(std::nullopt);
   i1.setSignatureInfo(si);
   VALIDATE_FAILURE(i1, "Should fail (missing KeyLocator)");
   BOOST_TEST(lastError.getCode() == ValidationError::INVALID_KEY_LOCATOR);
diff --git a/tests/unit/security/validator-fixture.hpp b/tests/unit/security/validator-fixture.hpp
index d8d357f..7e1e0b5 100644
--- a/tests/unit/security/validator-fixture.hpp
+++ b/tests/unit/security/validator-fixture.hpp
@@ -1,6 +1,6 @@
 /* -*- Mode:C++; c-file-style:"gnu"; indent-tabs-mode:nil; -*- */
 /*
- * Copyright (c) 2013-2022 Regents of the University of California.
+ * Copyright (c) 2013-2023 Regents of the University of California.
  *
  * This file is part of ndn-cxx library (NDN C++ library with eXperimental eXtensions).
  *
@@ -158,7 +158,7 @@
 
 private:
   void
-  verifyOriginalPacket(const optional<Certificate>&) override
+  verifyOriginalPacket(const std::optional<Certificate>&) override
   {
     // do nothing
   }
diff --git a/tests/unit/security/verification-helpers.t.cpp b/tests/unit/security/verification-helpers.t.cpp
index d3434c8..83d37da 100644
--- a/tests/unit/security/verification-helpers.t.cpp
+++ b/tests/unit/security/verification-helpers.t.cpp
@@ -1,6 +1,6 @@
 /* -*- Mode:C++; c-file-style:"gnu"; indent-tabs-mode:nil; -*- */
 /*
- * Copyright (c) 2013-2022 Regents of the University of California.
+ * Copyright (c) 2013-2023 Regents of the University of California.
  *
  * This file is part of ndn-cxx library (NDN C++ library with eXperimental eXtensions).
  *
@@ -632,21 +632,21 @@
   Interest interestOldFormat(dataset.goodInterestOldFormat);
   Interest badSigInterestOldFormat(dataset.badSigInterestOldFormat);
 
-  BOOST_CHECK(verifySignature(data, nullopt));
-  BOOST_CHECK(verifySignature(interest, nullopt));
-  BOOST_CHECK(verifySignature(interestOldFormat, nullopt));
+  BOOST_CHECK(verifySignature(data, std::nullopt));
+  BOOST_CHECK(verifySignature(interest, std::nullopt));
+  BOOST_CHECK(verifySignature(interestOldFormat, std::nullopt));
 
-  BOOST_CHECK(!verifySignature(badSigData, nullopt));
-  BOOST_CHECK(!verifySignature(badSigInterest, nullopt));
-  BOOST_CHECK(!verifySignature(badSigInterestOldFormat, nullopt));
+  BOOST_CHECK(!verifySignature(badSigData, std::nullopt));
+  BOOST_CHECK(!verifySignature(badSigInterest, std::nullopt));
+  BOOST_CHECK(!verifySignature(badSigInterestOldFormat, std::nullopt));
 
   Data unsignedData("/some/data");
   Interest unsignedInterest1("/some/interest/with/several/name/components");
   Interest unsignedInterest2("/interest-with-one-name-component");
 
-  BOOST_CHECK(!verifySignature(unsignedData, nullopt));
-  BOOST_CHECK(!verifySignature(unsignedInterest1, nullopt));
-  BOOST_CHECK(!verifySignature(unsignedInterest2, nullopt));
+  BOOST_CHECK(!verifySignature(unsignedData, std::nullopt));
+  BOOST_CHECK(!verifySignature(unsignedInterest1, std::nullopt));
+  BOOST_CHECK(!verifySignature(unsignedInterest2, std::nullopt));
 }
 
 const uint8_t sha256DataUnrecognizedElements[] = {
@@ -673,8 +673,8 @@
   Data data(Block{sha256DataUnrecognizedElements});
   Interest interest(Block{sha256InterestUnrecognizedElements});
 
-  BOOST_CHECK(verifySignature(data, nullopt));
-  BOOST_CHECK(verifySignature(interest, nullopt));
+  BOOST_CHECK(verifySignature(data, std::nullopt));
+  BOOST_CHECK(verifySignature(interest, std::nullopt));
 }
 
 BOOST_AUTO_TEST_SUITE_END() // TestVerificationHelpers
diff --git a/tests/unit/signature-info.t.cpp b/tests/unit/signature-info.t.cpp
index dff4241..1257851 100644
--- a/tests/unit/signature-info.t.cpp
+++ b/tests/unit/signature-info.t.cpp
@@ -1,6 +1,6 @@
 /* -*- Mode:C++; c-file-style:"gnu"; indent-tabs-mode:nil; -*- */
 /*
- * Copyright (c) 2013-2022 Regents of the University of California.
+ * Copyright (c) 2013-2023 Regents of the University of California.
  *
  * This file is part of ndn-cxx library (NDN C++ library with eXperimental eXtensions).
  *
@@ -100,7 +100,7 @@
 
   info.wireEncode();
   BOOST_CHECK_EQUAL(info.hasWire(), true);
-  info.setKeyLocator(nullopt);
+  info.setKeyLocator(std::nullopt);
   BOOST_CHECK_EQUAL(info.hasKeyLocator(), false);
   BOOST_CHECK_THROW(info.getKeyLocator(), SignatureInfo::Error);
   BOOST_CHECK_EQUAL(info.hasWire(), false);
@@ -127,7 +127,7 @@
 
   info.wireEncode();
   BOOST_CHECK_EQUAL(info.hasWire(), true);
-  info.setNonce(nullopt);
+  info.setNonce(std::nullopt);
   BOOST_CHECK_EQUAL(info.hasWire(), false);
   BOOST_CHECK(!info.getNonce());
 }
@@ -152,7 +152,7 @@
 
   info.wireEncode();
   BOOST_CHECK_EQUAL(info.hasWire(), true);
-  info.setTime(nullopt);
+  info.setTime(std::nullopt);
   BOOST_CHECK_EQUAL(info.hasWire(), false);
   BOOST_CHECK(!info.getTime());
 }
@@ -176,7 +176,7 @@
 
   info.wireEncode();
   BOOST_CHECK_EQUAL(info.hasWire(), true);
-  info.setSeqNum(nullopt);
+  info.setSeqNum(std::nullopt);
   BOOST_CHECK_EQUAL(info.hasWire(), false);
   BOOST_CHECK(!info.getSeqNum());
 }
@@ -452,7 +452,7 @@
 
   info2.wireEncode();
   BOOST_CHECK_EQUAL(info2.hasWire(), true);
-  info2.setValidityPeriod(nullopt);
+  info2.setValidityPeriod(std::nullopt);
   BOOST_CHECK_THROW(info2.getValidityPeriod(), SignatureInfo::Error);
   BOOST_CHECK_EQUAL(info2.hasWire(), false);
 }