Class: Rouge::Lexers::Cpp
- Inherits:
-
RegexLexer
- Object
- Rouge::Lexer
- RegexLexer
- Rouge::Lexers::Cpp
- Defined in:
- lib/rouge/lexers/cpp.rb
Constant Summary
Constants inherited from RegexLexer
Constants included from Token::Tokens
Token::Tokens::Num, Token::Tokens::Str
Class Method Summary collapse
Methods inherited from RegexLexer
#delegate, get_state, #get_state, #goto, #group, #groups, #in_state?, #pop!, #push, #reset!, #reset_stack, #run_callback, #run_rule, #stack, start, start_procs, #state, state, #state?, states, #step, #stream_tokens, #token
Methods inherited from Rouge::Lexer
aliases, all, analyze_text, assert_utf8!, #debug, default_options, demo, demo_file, desc, filenames, find, find_fancy, guess, guess_by_filename, guess_by_mimetype, guess_by_source, guesses, #initialize, lex, #lex, mimetypes, #option, #options, #reset!, #stream_tokens, tag, #tag
Methods included from Token::Tokens
Constructor Details
This class inherits a constructor from Rouge::Lexer
Class Method Details
.keywords ⇒ Object
15 16 17 18 19 20 21 22 23 24 25 |
# File 'lib/rouge/lexers/cpp.rb', line 15 def self.keywords @keywords ||= Set.new %w( asm auto break case catch const const_cast continue default delete do dynamic_cast else enum explicit export extern for friend goto if mutable namespace new operator private protected public register reinterpret_cast return restrict sizeof static static_cast struct switch template this throw throws try typedef typeid typename union using volatile virtual while ) end |
.keywords_type ⇒ Object
27 28 29 30 31 |
# File 'lib/rouge/lexers/cpp.rb', line 27 def self.keywords_type @keywords_type ||= Set.new %w( bool int long float short double char unsigned signed void wchar_t ) end |
.reserved ⇒ Object
33 34 35 36 37 38 39 40 41 42 43 44 45 |
# File 'lib/rouge/lexers/cpp.rb', line 33 def self.reserved @reserved ||= Set.new %w( __asm __int8 __based __except __int16 __stdcall __cdecl __fastcall __int32 __declspec __finally __int64 __try __leave __wchar_t __w64 __virtual_inheritance __uuidof __unaligned __super __single_inheritance __raise __noop __multiple_inheritance __m128i __m128d __m128 __m64 __interface __identifier __forceinline __event __assume inline _inline __inline naked _naked __naked thread _thread __thread ) end |