Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(53)

Side by Side Diff: src/scanner-base.cc

Issue 7491052: Static state cleanup: add more consts. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Created 9 years, 4 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « src/scanner-base.h ('k') | src/x64/deoptimizer-x64.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2011 the V8 project authors. All rights reserved. 1 // Copyright 2011 the V8 project authors. All rights reserved.
2 // Redistribution and use in source and binary forms, with or without 2 // Redistribution and use in source and binary forms, with or without
3 // modification, are permitted provided that the following conditions are 3 // modification, are permitted provided that the following conditions are
4 // met: 4 // met:
5 // 5 //
6 // * Redistributions of source code must retain the above copyright 6 // * Redistributions of source code must retain the above copyright
7 // notice, this list of conditions and the following disclaimer. 7 // notice, this list of conditions and the following disclaimer.
8 // * Redistributions in binary form must reproduce the above 8 // * Redistributions in binary form must reproduce the above
9 // copyright notice, this list of conditions and the following 9 // copyright notice, this list of conditions and the following
10 // disclaimer in the documentation and/or other materials provided 10 // disclaimer in the documentation and/or other materials provided
(...skipping 770 matching lines...) Expand 10 before | Expand all | Expand 10 after
781 } 781 }
782 literal.Complete(); 782 literal.Complete();
783 783
784 next_.location.end_pos = source_pos() - 1; 784 next_.location.end_pos = source_pos() - 1;
785 return true; 785 return true;
786 } 786 }
787 787
788 // ---------------------------------------------------------------------------- 788 // ----------------------------------------------------------------------------
789 // Keyword Matcher 789 // Keyword Matcher
790 790
791 KeywordMatcher::FirstState KeywordMatcher::first_states_[] = { 791 const KeywordMatcher::FirstState KeywordMatcher::first_states_[] = {
792 { "break", KEYWORD_PREFIX, Token::BREAK }, 792 { "break", KEYWORD_PREFIX, Token::BREAK },
793 { NULL, C, Token::ILLEGAL }, 793 { NULL, C, Token::ILLEGAL },
794 { NULL, D, Token::ILLEGAL }, 794 { NULL, D, Token::ILLEGAL },
795 { NULL, E, Token::ILLEGAL }, 795 { NULL, E, Token::ILLEGAL },
796 { NULL, F, Token::ILLEGAL }, 796 { NULL, F, Token::ILLEGAL },
797 { NULL, UNMATCHABLE, Token::ILLEGAL }, 797 { NULL, UNMATCHABLE, Token::ILLEGAL },
798 { NULL, UNMATCHABLE, Token::ILLEGAL }, 798 { NULL, UNMATCHABLE, Token::ILLEGAL },
799 { NULL, I, Token::ILLEGAL }, 799 { NULL, I, Token::ILLEGAL },
800 { NULL, UNMATCHABLE, Token::ILLEGAL }, 800 { NULL, UNMATCHABLE, Token::ILLEGAL },
801 { NULL, UNMATCHABLE, Token::ILLEGAL }, 801 { NULL, UNMATCHABLE, Token::ILLEGAL },
(...skipping 155 matching lines...) Expand 10 before | Expand all | Expand 10 after
957 if (MatchKeywordStart(input, "with", 1, Token::WITH)) return; 957 if (MatchKeywordStart(input, "with", 1, Token::WITH)) return;
958 break; 958 break;
959 case UNMATCHABLE: 959 case UNMATCHABLE:
960 break; 960 break;
961 } 961 }
962 // On fallthrough, it's a failure. 962 // On fallthrough, it's a failure.
963 state_ = UNMATCHABLE; 963 state_ = UNMATCHABLE;
964 } 964 }
965 965
966 } } // namespace v8::internal 966 } } // namespace v8::internal
OLDNEW
« no previous file with comments | « src/scanner-base.h ('k') | src/x64/deoptimizer-x64.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698