Rietveld Code Review Tool
Help | Bug tracker | Discussion group | Source code

Side by Side Diff: lib/filterClasses.js

Issue 29333474: Issue 4125 - [emscripten] Convert filter classes to C++ (Closed)
Patch Set: Addressed Sergei`s comments again and added some asserts Created Feb. 23, 2016, 12:30 p.m.
Left:
Right:
Use n/p to move between diff chunks; N/P to move between comments.
Jump to:
View unified diff | Download patch
OLDNEW
1 /* 1 /*
2 * This file is part of Adblock Plus <https://adblockplus.org/>, 2 * This file is part of Adblock Plus <https://adblockplus.org/>,
3 * Copyright (C) 2006-2016 Eyeo GmbH 3 * Copyright (C) 2006-2016 Eyeo GmbH
4 * 4 *
5 * Adblock Plus is free software: you can redistribute it and/or modify 5 * Adblock Plus is free software: you can redistribute it and/or modify
6 * it under the terms of the GNU General Public License version 3 as 6 * it under the terms of the GNU General Public License version 3 as
7 * published by the Free Software Foundation. 7 * published by the Free Software Foundation.
8 * 8 *
9 * Adblock Plus is distributed in the hope that it will be useful, 9 * Adblock Plus is distributed in the hope that it will be useful,
10 * but WITHOUT ANY WARRANTY; without even the implied warranty of 10 * but WITHOUT ANY WARRANTY; without even the implied warranty of
11 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 11 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12 * GNU General Public License for more details. 12 * GNU General Public License for more details.
13 * 13 *
14 * You should have received a copy of the GNU General Public License 14 * You should have received a copy of the GNU General Public License
15 * along with Adblock Plus. If not, see <http://www.gnu.org/licenses/>. 15 * along with Adblock Plus. If not, see <http://www.gnu.org/licenses/>.
16 */ 16 */
17 17
18 /** 18 /**
19 * @fileOverview Definition of Filter class and its subclasses. 19 * @fileOverview Definition of Filter class and its subclasses.
20 */ 20 */
21 21
22 "use strict";
23
22 let {FilterNotifier} = require("filterNotifier"); 24 let {FilterNotifier} = require("filterNotifier");
23 25
24 /** 26 /**
25 * Abstract base class for filters 27 * Abstract base class for filters
26 * 28 *
27 * @param {String} text string representation of the filter 29 * @param {String} text string representation of the filter
28 * @constructor 30 * @constructor
29 */ 31 */
30 function Filter(text) 32 function Filter(text)
31 { 33 {
(...skipping 1028 matching lines...) Expand 10 before | Expand all | Expand 10 after
1060 // several times on Safari, due to WebKit bug 132872 1062 // several times on Safari, due to WebKit bug 132872
1061 let prop = Object.getOwnPropertyDescriptor(this, "regexpString"); 1063 let prop = Object.getOwnPropertyDescriptor(this, "regexpString");
1062 if (prop) 1064 if (prop)
1063 return prop.value; 1065 return prop.value;
1064 1066
1065 let regexp = Filter.toRegExp(this.regexpSource); 1067 let regexp = Filter.toRegExp(this.regexpSource);
1066 Object.defineProperty(this, "regexpString", {value: regexp}); 1068 Object.defineProperty(this, "regexpString", {value: regexp});
1067 return regexp; 1069 return regexp;
1068 } 1070 }
1069 }; 1071 };
OLDNEW
« compiled/debug.h ('K') | « compiled/traceInit.cpp ('k') | lib/filterClassesNew.js » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld