mirror of
https://github.com/GothenburgBitFactory/taskwarrior.git
synced 2025-07-07 20:06:36 +02:00
ISO8601: Conditional compilation allows Taskserver to reuse code
This commit is contained in:
parent
560bf53f42
commit
0141d10d56
1 changed files with 5 additions and 0 deletions
|
@ -32,7 +32,9 @@
|
|||
#include <assert.h>
|
||||
#include <Lexer.h>
|
||||
#include <util.h>
|
||||
#ifdef PRODUCT_TASKWARRIOR
|
||||
#include <Dates.h>
|
||||
#endif
|
||||
#include <text.h>
|
||||
#include <utf8.h>
|
||||
#include <i18n.h>
|
||||
|
@ -614,6 +616,7 @@ bool ISO8601d::parse_formatted (Nibbler& n, const std::string& format)
|
|||
////////////////////////////////////////////////////////////////////////////////
|
||||
bool ISO8601d::parse_named (Nibbler& n)
|
||||
{
|
||||
#ifdef PRODUCT_TASKWARRIOR
|
||||
n.save ();
|
||||
std::string token;
|
||||
if (n.getUntilWS (token))
|
||||
|
@ -627,6 +630,8 @@ bool ISO8601d::parse_named (Nibbler& n)
|
|||
}
|
||||
|
||||
n.restore ();
|
||||
#endif
|
||||
|
||||
return false;
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue