1.1 --- a/lib/__builtins__/exception/base.py Mon Jan 08 01:15:11 2018 +0100
1.2 +++ b/lib/__builtins__/exception/base.py Mon Jan 15 01:12:29 2018 +0100
1.3 @@ -3,7 +3,7 @@
1.4 """
1.5 Base exception objects. See __builtins__.core for the core exceptions.
1.6
1.7 -Copyright (C) 2015, 2016 Paul Boddie <paul@boddie.org.uk>
1.8 +Copyright (C) 2015, 2016, 2018 Paul Boddie <paul@boddie.org.uk>
1.9
1.10 This program is free software; you can redistribute it and/or modify it under
1.11 the terms of the GNU General Public License as published by the Free Software
1.12 @@ -29,15 +29,21 @@
1.13
1.14 "An error condition involving an index."
1.15
1.16 - def __init__(self, index):
1.17 - self.index = index
1.18 + def __init__(self, .index):
1.19 +
1.20 + "Initialise the exception with the given 'index'."
1.21 +
1.22 + pass
1.23
1.24 class KeyError(LookupError):
1.25
1.26 "An error concerned with a dictionary key."
1.27
1.28 - def __init__(self, key):
1.29 - self.key = key
1.30 + def __init__(self, .key):
1.31 +
1.32 + "Initialise the exception with the given 'key'."
1.33 +
1.34 + pass
1.35
1.36 class RuntimeError(Exception):
1.37
1.38 @@ -49,8 +55,11 @@
1.39
1.40 "An error indicating an unimplemented function or method."
1.41
1.42 - def __init__(self, name):
1.43 - self.name = name
1.44 + def __init__(self, .name):
1.45 +
1.46 + "Initialise the exception with the given 'name'."
1.47 +
1.48 + pass
1.49
1.50 class StopIteration(Exception):
1.51
1.52 @@ -62,7 +71,10 @@
1.53
1.54 "An error concerned with a particular value."
1.55
1.56 - def __init__(self, value):
1.57 - self.value = value
1.58 + def __init__(self, .value):
1.59 +
1.60 + "Initialise the exception with the given 'value'."
1.61 +
1.62 + pass
1.63
1.64 # vim: tabstop=4 expandtab shiftwidth=4
2.1 --- a/lib/__builtins__/exception/io.py Mon Jan 08 01:15:11 2018 +0100
2.2 +++ b/lib/__builtins__/exception/io.py Mon Jan 15 01:12:29 2018 +0100
2.3 @@ -3,7 +3,7 @@
2.4 """
2.5 Input/output exception objects.
2.6
2.7 -Copyright (C) 2015, 2016, 2017 Paul Boddie <paul@boddie.org.uk>
2.8 +Copyright (C) 2015, 2016, 2017, 2018 Paul Boddie <paul@boddie.org.uk>
2.9
2.10 This program is free software; you can redistribute it and/or modify it under
2.11 the terms of the GNU General Public License as published by the Free Software
2.12 @@ -29,11 +29,11 @@
2.13
2.14 "An input/output error."
2.15
2.16 - def __init__(self, value):
2.17 + def __init__(self, .value):
2.18
2.19 "Initialise the exception with the given 'value'."
2.20
2.21 - self.value = value
2.22 + pass
2.23
2.24 class KeyboardInterrupt(Exception):
2.25
3.1 --- a/lib/__builtins__/exception/naming.py Mon Jan 08 01:15:11 2018 +0100
3.2 +++ b/lib/__builtins__/exception/naming.py Mon Jan 15 01:12:29 2018 +0100
3.3 @@ -6,7 +6,7 @@
3.4 Errors regarding unrecognised names or import failures are not provided since
3.5 these errors should occur during program compilation.
3.6
3.7 -Copyright (C) 2015, 2016 Paul Boddie <paul@boddie.org.uk>
3.8 +Copyright (C) 2015, 2016, 2018 Paul Boddie <paul@boddie.org.uk>
3.9
3.10 This program is free software; you can redistribute it and/or modify it under
3.11 the terms of the GNU General Public License as published by the Free Software
3.12 @@ -26,10 +26,10 @@
3.13
3.14 "An error indicating an invalid attribute for an object."
3.15
3.16 - def __init__(self, name):
3.17 + def __init__(self, .name):
3.18
3.19 "Initialise the exception with the given 'name'."
3.20
3.21 - self.name = name
3.22 + pass
3.23
3.24 # vim: tabstop=4 expandtab shiftwidth=4
4.1 --- a/lib/__builtins__/exception/system.py Mon Jan 08 01:15:11 2018 +0100
4.2 +++ b/lib/__builtins__/exception/system.py Mon Jan 15 01:12:29 2018 +0100
4.3 @@ -3,7 +3,7 @@
4.4 """
4.5 System exception objects.
4.6
4.7 -Copyright (C) 2015, 2016, 2017 Paul Boddie <paul@boddie.org.uk>
4.8 +Copyright (C) 2015, 2016, 2017, 2018 Paul Boddie <paul@boddie.org.uk>
4.9
4.10 This program is free software; you can redistribute it and/or modify it under
4.11 the terms of the GNU General Public License as published by the Free Software
4.12 @@ -29,12 +29,11 @@
4.13
4.14 "A general operating system error."
4.15
4.16 - def __init__(self, value, arg):
4.17 + def __init__(self, .value, .arg):
4.18
4.19 "Initialise the exception with the given error 'value' and 'arg'."
4.20
4.21 - self.value = value
4.22 - self.arg = arg
4.23 + pass
4.24
4.25 def __str__(self):
4.26 return str(buffer(["OSError(", repr(self.value), ", ", repr(self.arg), ")"]))
4.27 @@ -51,7 +50,10 @@
4.28
4.29 "An exception exiting the program."
4.30
4.31 - def __init__(self, value):
4.32 - self.value = value
4.33 + def __init__(self, .value):
4.34 +
4.35 + "Initialise the exception with the given 'value'."
4.36 +
4.37 + pass
4.38
4.39 # vim: tabstop=4 expandtab shiftwidth=4
5.1 --- a/lib/__builtins__/exception/unicode.py Mon Jan 08 01:15:11 2018 +0100
5.2 +++ b/lib/__builtins__/exception/unicode.py Mon Jan 15 01:12:29 2018 +0100
5.3 @@ -3,7 +3,7 @@
5.4 """
5.5 Unicode exception objects.
5.6
5.7 -Copyright (C) 2015, 2016, 2017 Paul Boddie <paul@boddie.org.uk>
5.8 +Copyright (C) 2015, 2016, 2017, 2018 Paul Boddie <paul@boddie.org.uk>
5.9
5.10 This program is free software; you can redistribute it and/or modify it under
5.11 the terms of the GNU General Public License as published by the Free Software
5.12 @@ -32,14 +32,14 @@
5.13 a character encoding.
5.14 """
5.15
5.16 - def __init__(self, value):
5.17 + def __init__(self, .value):
5.18
5.19 """
5.20 Initialise an exception with a 'value' providing the illegal byte
5.21 sequence responsible for the error.
5.22 """
5.23
5.24 - self.value = value
5.25 + pass
5.26
5.27 class UnicodeEncodeError(UnicodeError): pass
5.28 class UnicodeTranslateError(UnicodeError): pass
6.1 --- a/lib/__builtins__/span.py Mon Jan 08 01:15:11 2018 +0100
6.2 +++ b/lib/__builtins__/span.py Mon Jan 15 01:12:29 2018 +0100
6.3 @@ -3,7 +3,7 @@
6.4 """
6.5 Span-related objects.
6.6
6.7 -Copyright (C) 2015, 2016, 2017 Paul Boddie <paul@boddie.org.uk>
6.8 +Copyright (C) 2015, 2016, 2017, 2018 Paul Boddie <paul@boddie.org.uk>
6.9
6.10 This program is free software; you can redistribute it and/or modify it under
6.11 the terms of the GNU General Public License as published by the Free Software
6.12 @@ -90,13 +90,11 @@
6.13
6.14 "An iterator over an xrange."
6.15
6.16 - def __init__(self, start, step, count):
6.17 + def __init__(self, start, .step, .count):
6.18
6.19 - "Initialise the iterator with the given 'obj'."
6.20 + "Initialise the iterator with the given 'start', 'step' and 'count'."
6.21
6.22 self.current = start
6.23 - self.step = step
6.24 - self.count = count
6.25
6.26 def next(self):
6.27