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

Side by Side Diff: src/ast.h

Issue 9368026: Make constructors explicit. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Created 8 years, 10 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 | « no previous file | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2012 the V8 project authors. All rights reserved. 1 // Copyright 2012 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 524 matching lines...) Expand 10 before | Expand all | Expand 10 after
535 535
536 class ModuleLiteral: public Module { 536 class ModuleLiteral: public Module {
537 public: 537 public:
538 DECLARE_NODE_TYPE(ModuleLiteral) 538 DECLARE_NODE_TYPE(ModuleLiteral)
539 539
540 Block* body() const { return body_; } 540 Block* body() const { return body_; }
541 541
542 protected: 542 protected:
543 template<class> friend class AstNodeFactory; 543 template<class> friend class AstNodeFactory;
544 544
545 ModuleLiteral(Block* body) 545 explicit ModuleLiteral(Block* body)
546 : body_(body) { 546 : body_(body) {
547 } 547 }
548 548
549 private: 549 private:
550 Block* body_; 550 Block* body_;
551 }; 551 };
552 552
553 553
554 class ModuleVariable: public Module { 554 class ModuleVariable: public Module {
555 public: 555 public:
556 DECLARE_NODE_TYPE(ModuleVariable) 556 DECLARE_NODE_TYPE(ModuleVariable)
557 557
558 Variable* var() const { return var_; } 558 Variable* var() const { return var_; }
559 559
560 protected: 560 protected:
561 template<class> friend class AstNodeFactory; 561 template<class> friend class AstNodeFactory;
562 562
563 ModuleVariable(Variable* var) 563 explicit ModuleVariable(Variable* var)
564 : var_(var) { 564 : var_(var) {
565 } 565 }
566 566
567 private: 567 private:
568 Variable* var_; 568 Variable* var_;
569 }; 569 };
570 570
571 571
572 class ModulePath: public Module { 572 class ModulePath: public Module {
573 public: 573 public:
(...skipping 18 matching lines...) Expand all
592 592
593 class ModuleUrl: public Module { 593 class ModuleUrl: public Module {
594 public: 594 public:
595 DECLARE_NODE_TYPE(ModuleUrl) 595 DECLARE_NODE_TYPE(ModuleUrl)
596 596
597 Handle<String> url() const { return url_; } 597 Handle<String> url() const { return url_; }
598 598
599 protected: 599 protected:
600 template<class> friend class AstNodeFactory; 600 template<class> friend class AstNodeFactory;
601 601
602 ModuleUrl(Handle<String> url) : url_(url) { 602 explicit ModuleUrl(Handle<String> url) : url_(url) {
603 } 603 }
604 604
605 private: 605 private:
606 Handle<String> url_; 606 Handle<String> url_;
607 }; 607 };
608 608
609 609
610 class IterationStatement: public BreakableStatement { 610 class IterationStatement: public BreakableStatement {
611 public: 611 public:
612 // Type testing & conversion. 612 // Type testing & conversion.
(...skipping 2199 matching lines...) Expand 10 before | Expand all | Expand 10 after
2812 private: 2812 private:
2813 Isolate* isolate_; 2813 Isolate* isolate_;
2814 Zone* zone_; 2814 Zone* zone_;
2815 Visitor visitor_; 2815 Visitor visitor_;
2816 }; 2816 };
2817 2817
2818 2818
2819 } } // namespace v8::internal 2819 } } // namespace v8::internal
2820 2820
2821 #endif // V8_AST_H_ 2821 #endif // V8_AST_H_
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698