annotationparser: correct "maximium" in error messages
authorWill Thompson <will.thompson@collabora.co.uk>
Mon, 27 Feb 2012 17:52:30 +0000 (17:52 +0000)
committerJohan Dahlin <jdahlin@litl.com>
Mon, 9 Apr 2012 15:05:33 +0000 (12:05 -0300)
"Maximium" is not an English word. Even if corrected to "maximum" (which
is), "at maximum" is not conventional usage: "at most" is more
idiomatic.

https://bugzilla.gnome.org/show_bug.cgi?id=670985

giscanner/annotationparser.py
tests/warn/invalid-closure.h
tests/warn/invalid-element-type.h

index 76f3124..e35eb28 100644 (file)
@@ -321,7 +321,7 @@ class DocTag(object):
             elif option == OPT_CLOSURE:
                 if value is not None and value.length() > 1:
                     message.warn(
-                        'closure takes at maximium 1 value, %d given' % (
+                        'closure takes at most 1 value, %d given' % (
                         value.length()), self.position)
                     continue
             elif option == OPT_DESTROY:
@@ -335,7 +335,7 @@ class DocTag(object):
                     continue
                 if value.length() > 2:
                     message.warn(
-                        'element-type takes at maximium 2 values, %d given' % (
+                        'element-type takes at most 2 values, %d given' % (
                         value.length()), self.position)
                     continue
             elif option == OPT_FOREIGN:
@@ -349,7 +349,7 @@ class DocTag(object):
                     continue
                 if value.length() > 1:
                     message.warn(
-                        'out annotation takes at maximium 1 value, %d given' % (
+                        'out annotation takes at most 1 value, %d given' % (
                         value.length()), self.position)
                     continue
                 value_str = value.one()
index fcaf093..50ba086 100644 (file)
@@ -5,4 +5,4 @@
  */
 void test_invalid_closure(int param);
 
-// EXPECT:4: Warning: Test: closure takes at maximium 1 value, 2 given
+// EXPECT:4: Warning: Test: closure takes at most 1 value, 2 given
index 71749d1..52e3116 100644 (file)
@@ -33,7 +33,7 @@ void test_invalid_hash_element_type(GHashTable *h1, GHashTable *h2, GHashTable *
 
 // EXPECT:27: Warning: Test: element-type annotation needs a value
 // EXPECT:27: Warning: Test: element-type takes at least one value, none given
-// EXPECT:29: Warning: Test: element-type takes at maximium 2 values, 3 given
+// EXPECT:29: Warning: Test: element-type takes at most 2 values, 3 given
 
 /**
  * test_invalid_bytearray_element_type: