From 07e0d37aba5cd72ff2d53eda654a4d5466e38627 Mon Sep 17 00:00:00 2001 From: Karen Arutyunov Date: Fri, 8 Nov 2019 00:17:47 +0300 Subject: Use path_name for `-` to stdin/stdout translation --- libbuild2/token.hxx | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) (limited to 'libbuild2/token.hxx') diff --git a/libbuild2/token.hxx b/libbuild2/token.hxx index 0ee5248..2370f8d 100644 --- a/libbuild2/token.hxx +++ b/libbuild2/token.hxx @@ -161,32 +161,32 @@ namespace build2 struct replay_token { build2::token token; - const path* file; + const path_name* file; lexer_mode_base mode; using location_type = build2::location; location_type - location () const {return location_type (file, token.line, token.column);} + location () const {return location_type (*file, token.line, token.column);} }; using replay_tokens = vector; // Diagnostics plumbing. We assume that any diag stream for which we can use - // token as location has its aux data pointing to pointer to path. + // token as location has its aux data pointing to pointer to path name. // inline location - get_location (const token& t, const path& p) + get_location (const token& t, const path_name& pn) { - return location (&p, t.line, t.column); + return location (pn, t.line, t.column); } inline location get_location (const token& t, const void* data) { assert (data != nullptr); // E.g., must be &parser::path_. - const path* p (*static_cast (data)); - return get_location (t, *p); + const path_name* pn (*static_cast (data)); + return get_location (t, *pn); } } -- cgit v1.1