aboutsummaryrefslogtreecommitdiff
path: root/build/token
diff options
context:
space:
mode:
Diffstat (limited to 'build/token')
-rw-r--r--build/token6
1 files changed, 6 insertions, 0 deletions
diff --git a/build/token b/build/token
index bade45c..6f4951c 100644
--- a/build/token
+++ b/build/token
@@ -28,6 +28,12 @@ namespace build
token_punctuation
punctuation () const {assert (t_ == token_type::punctuation); return p_;}
+ bool
+ is (token_punctuation p) const
+ {
+ return t_ == token_type::punctuation && p_ == p;
+ }
+
std::uint64_t line () const {return l_;}
std::uint64_t column () const {return c_;}