Closed
Bug 1198738
Opened 10 years ago
Closed 8 years ago
Remove useless arguments of nsIUnicodeEncoder::SetOutputErrorBehavior()
Categories
(Core :: Internationalization, enhancement)
Core
Internationalization
Tracking
()
RESOLVED
FIXED
mozilla56
Tracking | Status | |
---|---|---|
firefox43 | --- | affected |
People
(Reporter: hsivonen, Assigned: hsivonen, Mentored)
References
Details
(Whiteboard: [fixed by encoding_rs])
nsIUnicodeEncoder::SetOutputErrorBehavior() takes three arguments:
1) Behavior enum
2) An nsIUnicharEncoder to be used with the kOnError_CallBack behavior
3) A replacement character to be used with the kOnError_Replace behavior
We should remove the second argument as well as the kOnError_CallBack enum item, since they are never used--not even in in c-c:
https://mxr.mozilla.org/comm-central/ident?i=SetOutputErrorBehavior . This would allow us to remove nsIUnicharEncoder and all its implementations.
We should remove the third argument, because it is always set to '?' in non-test code where it is not ignored (i.e. when behavior is kOnError_Replace). We should simply hard-code the ASCII question mark as the replacement character when kOnError_Replace is in use.
Assignee | ||
Comment 1•10 years ago
|
||
See https://mxr.mozilla.org/comm-central/ident?i=kOnError_CallBack for non-use.
Assignee | ||
Updated•9 years ago
|
Depends on: encoding_rs
Assignee | ||
Comment 2•8 years ago
|
||
Fixed by bug 1261841.
Assignee: nobody → hsivonen
Status: NEW → RESOLVED
Closed: 8 years ago
Resolution: --- → FIXED
Whiteboard: [fixed by encoding_rs]
Target Milestone: --- → mozilla56
You need to log in
before you can comment on or make changes to this bug.
Description
•