HWA
Bare metal programming with style
hwa_errors.h
Go to the documentation of this file.
1 
2 /* This file is part of the HWA project.
3  * Copyright (c) 2020 Christophe Duparquet.
4  * All rights reserved. Read LICENSE.TXT for details.
5  */
6 
27 #define HW_E(...) _HW_E2(HWA: __VA_ARGS__.)
28 #define _HW_E2(...) _HW_E3(GCC error #__VA_ARGS__)
29 #define _HW_E3(s) _Pragma(#s)
30 
31 #define HW_E_OCM(o,c,m) HW_B(HW_E_OCM_,c)(o,c,m)
32 #define HW_E_OCM_0(o,c,m) HW_E(HW_EM_OCM(o,c,m))
33 #define HW_E_OCM_1(...)
34 
35 /* Error messages
36  */
37 #define HW_EM_AI(a) invalid argument HW_Q(a)
38 #define HW_EM_AL(a,l) argument HW_Q(a) is not in l
39 #define HW_EM_ACCESS invalid access
40 #define HW_EM_ADOO(a,o1,o2) value of parameter `a` mismatch beween `o1` and `o2`
41 #define HW_EM_AOCL(a,o,c,l) action HW_Q(a) for object HW_Q(o) of class HW_Q(c) is not in l
42 #define HW_EM_AVL(a,l) value of parameter `a` is not in l
43 #define HW_EM_AVOL(a,o,l) value of parameter `a` for `o` is not in l
44 #define HW_EM_AVM(a,v) value of parameter `a` must be `v`
45 #define HW_EM_AOVM(a,o,v) value of parameter `a` for `o` must be `v`
46 #define HW_EM_AM(a) missing argument HW_Q(a)
47 #define HW_EM_AML(l) expected at least one argument of l
48 #define HW_EM_AN(a,n) expected argument HW_Q(n) instead of HW_Q(a)
49 #define HW_EM_CAN(c,a,n) constructor c expects an argument HW_Q(n) instead of HW_Q(a)
50 #define HW_EM_CANTREMAP remapping is impossible
51 #define HW_EM_COR(o) configuration of `o` is required
52 #define HW_EM_COMMITRQ committing is required before setting a new value
53 #define HW_EM_CMOO(o1,o2) configuration mismatch beween `o1` and `o2`
54 #define HW_EM_FO(f,o) no function `f` for `o`
55 #define HW_EM_G(x) garbage starting at HW_Q(x)
56 #define HW_EM_KX(k,x) expected HW_Q(k) instead of HW_Q(x)
57 #define HW_EM_NKX(n,k,x) expected HW_Q(k) instead of HW_Q(x) in HW_Q(n)
58 #define HW_EM_NOP no operation
59 #define HW_EM_O(x) HW_Q(x) is not an object
60 #define HW_EM_OAVI(o,a,v) `o` does not support value `v` for `a`
61 #define HW_EM_OCM(o,c,m) object HW_Q(o) of class HW_Q(c) has no method HW_Q(m)
62 #define HW_EM_OM() missing object name
63 #define HW_EM_OMAP(o) remapping error for `o`
64 #define HW_EM_MAP signal is already mapped to another pin
65 #define HW_EM_IONC IO contains disconnected pins
66 #define HW_EM_ISR(o) no ISR known for `o`
67 #define HW_EM_ONC(o) HW_Q(o) is not connected
68 #define HW_EM_OO(o,x) HW_Q(o) has no relative HW_Q(x)
69 #define HW_EM_OPTIM you may have forgotten to turn optimizations on
70 #define HW_EM_OT(o,t) HW_Q(o) is not a t
71 #define HW_EM_OVL(v,l) optionnal value HW_Q(v) is not in l
72 #define HW_EM_SD(s) symbol #s not defined
73 #define HW_EM_SL(l) suggest you try one of l
74 #define HW_EM_ST(x) HW_Q(x) is not in (0,1,on,off,yes,no)
75 #define HW_EM_SY(s) syntax is s
76 #define HW_EM_TBD(...) to be done (this feature is not implemented yet) [__VA_ARGS__]
77 #define HW_EM_V missing value
78 #define HW_EM_VAL(v,a,l) value HW_Q(v) for argument HW_Q(a) is not in l
79 #define HW_EM_VAM(a) missing value for argument HW_Q(a)
80 #define HW_EM_VL(v,l) value HW_Q(v) is not in l
81 #define HW_EM_VOAL(v,a,l) value HW_Q(v) for optionnal argument HW_Q(a) is not in l
82 #define HW_EM_VOAST(v,a) value HW_Q(v) for optionnal argument HW_Q(a) is not in (0,1,on,off,yes,no)
83 #define HW_EM_VSL(s,l) value `s` of symbol #s is not in l
84 #define HW_EM_XWW(x,w1,w2) expected HW_Q(w2) instead of HW_Q(x) after HW_Q(w1)
85 
86 #define HW_EM_XNIL(x,l) HW_Q(x) is not in l
87 #define HW_EM_XSO(x,o) can not solve value of `x` for `o`
88 
89 #define HW_EM_X(x) internal error x