DOKK / manpages / debian 12 / libcompiler-lexer-perl / Compiler::Lexer::Token.3pm.en
Compiler::Lexer::Token(3pm) User Contributed Perl Documentation Compiler::Lexer::Token(3pm)

Compiler::Lexer::Token - Token object for Compiler::Lexer

Compiler::Lexer::Token includes the following members.

constant of Compiler::Lexer::SyntaxType
constant of Compiler::Lexer::TokenType
constant of Compiler::Lexer::Kind
name of Compiler::Lexer::TokenType
raw data
flag of whether unknown keyword or not

support simple get/set accessors like Class::Accessor::Fast

example:

  my $type = $token->type;                            # get accessor
  $token->type(Compiler::Lexer::TokenType::T_RegExp); # set accessor

Masaaki Goshima (goccy) <goccy(at)cpan.org>

Copyright (c) 2013, Masaaki Goshima (goccy). All rights reserved.

This library is free software; you can redistribute it and/or modify it under the same terms as Perl itself.

2022-10-19 perl v5.36.0