Changeset 28028 in webkit


Ignore:
Timestamp:
Nov 25, 2007 6:12:37 PM (16 years ago)
Author:
mrowe@apple.com
Message:

2007-11-24 Laszlo Gombos <laszlo.gombos@gmail.com>

Reviewed by Sam Weinig.

Add printf format attribute to several functions. Use the the new WTF_ATTRIBUTE_PRINTF define.

  • dom/XMLTokenizer.cpp:
  • dom/XMLTokenizer.h:
  • platform/DeprecatedString.h:
  • platform/PlatformString.h:
Location:
trunk/WebCore
Files:
5 edited

Legend:

Unmodified
Added
Removed
  • trunk/WebCore/ChangeLog

    r28025 r28028  
     12007-11-24  Laszlo Gombos  <laszlo.gombos@gmail.com>
     2
     3        Reviewed by Sam Weinig.
     4
     5        Add printf format attribute to several functions. Use the the new WTF_ATTRIBUTE_PRINTF define.
     6
     7        * dom/XMLTokenizer.cpp:
     8        * dom/XMLTokenizer.h:
     9        * platform/DeprecatedString.h:
     10        * platform/PlatformString.h:
     11
    1122007-11-25  Dan Bernstein  <mitz@apple.com>
    213
  • trunk/WebCore/dom/XMLTokenizer.cpp

    r27936 r28028  
    10661066}
    10671067
     1068WTF_ATTRIBUTE_PRINTF(2, 3)
    10681069static void warningHandler(void* closure, const char* message, ...)
    10691070{
     
    10741075}
    10751076
     1077WTF_ATTRIBUTE_PRINTF(2, 3)
    10761078static void fatalErrorHandler(void* closure, const char* message, ...)
    10771079{
     
    10821084}
    10831085
     1086WTF_ATTRIBUTE_PRINTF(2, 3)
    10841087static void normalErrorHandler(void* closure, const char* message, ...)
    10851088{
     
    15511554}
    15521555
     1556WTF_ATTRIBUTE_PRINTF(2, 3)
    15531557static void balancedWarningHandler(void* closure, const char* message, ...)
    15541558{
  • trunk/WebCore/dom/XMLTokenizer.h

    r27936 r28028  
    8585#ifndef USE_QXMLSTREAM
    8686        // callbacks from parser SAX
    87         void error(ErrorType, const char* message, va_list args);
     87        void error(ErrorType, const char* message, va_list args) WTF_ATTRIBUTE_PRINTF(3, 0);
    8888        void startElementNs(const xmlChar* xmlLocalName, const xmlChar* xmlPrefix, const xmlChar* xmlURI, int nb_namespaces,
    8989                            const xmlChar** namespaces, int nb_attributes, int nb_defaulted, const xmlChar** libxmlAttributes);
  • trunk/WebCore/platform/DeprecatedString.h

    r27187 r28028  
    386386    DeprecatedString &setNum(double);
    387387
    388     DeprecatedString& format(const char *, ...)
    389 #if __GNUC__
    390     __attribute__ ((format (printf, 2, 3)))
    391 #endif
    392     ;
     388    DeprecatedString& format(const char *, ...) WTF_ATTRIBUTE_PRINTF(2, 3);
    393389
    394390    DeprecatedString &append(const DeprecatedString &);
  • trunk/WebCore/platform/PlatformString.h

    r27363 r28028  
    134134    static String number(double);
    135135   
    136     static String format(const char *, ...)
    137 #if __GNUC__
    138         __attribute__ ((format (printf, 1, 2)))
    139 #endif
    140         ;
     136    static String format(const char *, ...) WTF_ATTRIBUTE_PRINTF(1, 2);
    141137
    142138    Vector<String> split(const String& separator, bool allowEmptyEntries = false) const;
Note: See TracChangeset for help on using the changeset viewer.