Changeset 85928 in webkit


Ignore:
Timestamp:
May 6, 2011 12:35:46 AM (13 years ago)
Author:
alexis.menard@openbossa.org
Message:

2011-05-06 Alexis Menard <alexis.menard@openbossa.org>

Reviewed by Alexey Proskuryakov.

Build fix with gcc 4.6 and c++0x support.
https://bugs.webkit.org/show_bug.cgi?id=60284

When enabling support of c++0x the compilation fails because of an
ambiguous overload error. In this code when constructing the pair
we use the new c++0x rvalue reference feature (&&). It means we are
calling String(const WTF::AtomicString&) which becomes ambiguous because
it has an overload WTF::String::String(const WTF::String&) and usually one
with the native port string type (e.g. QString). In this code we want the
String version because the pair store Strings.

No new tests, build fix.

  • loader/FormSubmission.cpp: (WebCore::FormSubmission::create):
Location:
trunk/Source/WebCore
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/Source/WebCore/ChangeLog

    r85926 r85928  
     12011-05-06  Alexis Menard  <alexis.menard@openbossa.org>
     2
     3        Reviewed by Alexey Proskuryakov.
     4
     5        Build fix with gcc 4.6 and c++0x support.
     6        https://bugs.webkit.org/show_bug.cgi?id=60284
     7
     8        When enabling support of c++0x the compilation fails because of an
     9        ambiguous overload error. In this code when constructing the pair
     10        we use the new c++0x rvalue reference feature (&&). It means we are
     11        calling String(const WTF::AtomicString&) which becomes ambiguous because
     12        it has an overload WTF::String::String(const WTF::String&) and usually one
     13        with the native port string type (e.g. QString). In this code we want the
     14        String version because the pair store Strings.
     15
     16        No new tests, build fix.
     17
     18        * loader/FormSubmission.cpp:
     19        (WebCore::FormSubmission::create):
     20
    1212011-05-06  Cris Neckar  <cdn@chromium.org>
    222
  • trunk/Source/WebCore/loader/FormSubmission.cpp

    r73430 r85928  
    183183            HTMLInputElement* input = static_cast<HTMLInputElement*>(control);
    184184            if (input->isTextField()) {
    185                 formValues.append(pair<String, String>(input->name(), input->value()));
     185                formValues.append(pair<String, String>(input->name().string(), input->value()));
    186186                if (input->isSearchField())
    187187                    input->addSearchResult();
Note: See TracChangeset for help on using the changeset viewer.