https://bugzilla.wikimedia.org/show_bug.cgi?id=52482
Web browser: ---
Bug ID: 52482
Summary: VisualEditor: Use null instead of flame throwers as
abstract method value
Product: VisualEditor
Version: unspecified
Hardware: All
OS: All
Status: NEW
Severity: normal
Priority: Unprioritized
Component: Technical Debt
Assignee: [email protected]
Reporter: [email protected]
CC: [email protected], [email protected],
[email protected], [email protected]
Classification: Unclassified
Mobile Platform: ---
/**
* @abstract
* @method
*/
ve.foo.Bar.prototype.abstractMethod = function () {
throw new Error( 've.foo.Bar subclass must implement abstractMethod');
};
x.abstractMethod();
> Error: ve.foo.Bar subclass must implement abstractMethod
/**
* @abstract
* @method
*/
ve.foo.Bar.prototype.abstractMethod = null;
x.abstractMethod();
> TypeError: Property 'abstractMethod' of object #<VeFooQuuxBar> is not a
> function
Seems easier to maintain and good enough.
--
You are receiving this mail because:
You are on the CC list for the bug.
_______________________________________________
Wikibugs-l mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/wikibugs-l