如何从boost :: spirit :: lex令牌确定行/列号? [英] How to determine line/column numbers from boost::spirit::lex tokens?

查看:99
本文介绍了如何从boost :: spirit :: lex令牌确定行/列号?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

在对

In its answer to this question, hkaiser said he would write an example of a token type which carries code position information. I really cannot find anything about this.

有人能指出我一个这样的例子吗?

Can anyone point me to such an example ?

推荐答案

他可能是指position_token,尽管文档很少,但实际上确实已发布. 此SO问题具有很好地覆盖了它的用法.

He was probably referring to position_token, which did in fact get released, although there's little documentation. This SO question has good coverage of its usage.

这篇关于如何从boost :: spirit :: lex令牌确定行/列号?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆