Bug 93402

Summary: Use char* instead of LChar* for the public interface of String construction from literals
Product: WebKit Reporter: Benjamin Poulain <benjamin>
Component: Web Template FrameworkAssignee: Benjamin Poulain <benjamin>
Status: RESOLVED FIXED    
Severity: Normal CC: darin, eric, msaboff
Priority: P2    
Version: 528+ (Nightly build)   
Hardware: Unspecified   
OS: Unspecified   
Bug Depends on:    
Bug Blocks: 93426    
Attachments:
Description Flags
Patch msaboff: review+

Benjamin Poulain
Reported 2012-08-07 15:39:22 PDT
Some part of the API was based on LChar because it is easier. After using it for a bit, I think it is dangerously confusing.
Attachments
Patch (11.70 KB, patch)
2012-08-07 15:51 PDT, Benjamin Poulain
msaboff: review+
Benjamin Poulain
Comment 1 2012-08-07 15:51:30 PDT
Michael Saboff
Comment 2 2012-08-08 15:40:44 PDT
Comment on attachment 157028 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=157028&action=review > Source/WTF/wtf/text/StringImpl.cpp:87 > + ASSERT(charactersAreAllASCII<LChar>(reinterpret_cast<const LChar*>(characters), length)); Do we care about the ASSERT after this change?
Benjamin Poulain
Comment 3 2012-08-08 16:14:27 PDT
Thanks for the review. > > + ASSERT(charactersAreAllASCII<LChar>(reinterpret_cast<const LChar*>(characters), length)); > > Do we care about the ASSERT after this change? Yep, it is still possible to pass non ASCII characters. Unfortunately there is no easy way to enforce that at compile time.
Benjamin Poulain
Comment 4 2012-08-08 18:29:56 PDT
Note You need to log in before you can comment on or make changes to this bug.