import std.range : only, takeNone; { auto reply = parseNumeric!(Numeric.RPL_REHASHING)(only("someone", "ircd.conf", "Rehashing")); assert(reply.get.configFile == "ircd.conf"); assert(reply.get.message == "Rehashing"); } { immutable reply = parseNumeric!(Numeric.RPL_REHASHING)(only("someone", "ircd.conf")); assert(reply.isNull); } { immutable reply = parseNumeric!(Numeric.RPL_REHASHING)(only("someone")); assert(reply.isNull); } { immutable reply = parseNumeric!(Numeric.RPL_REHASHING)(takeNone(only(""))); assert(reply.isNull); }
Parser for RPL_REHASHING
Format is 382 <client> <config file> :Rehashing]