@@ -1134,35 +1134,26 @@ public void EmitAsynchronousHandlers(ArrayList asynchronousHandlers) {
1134
1134
string implClass = MangleMethodClass ( amqpClass , amqpMethod ) ;
1135
1135
1136
1136
EmitLine ( " case " + ( ( amqpClass . Index << 16 ) | amqpMethod . Index ) + ": {" ) ;
1137
- ParameterInfo [ ] parameters = method . GetParameters ( ) ;
1137
+ ParameterInfo [ ] parameters = method . GetParameters ( ) ;
1138
1138
if ( parameters . Length > 0 ) {
1139
- EmitLine ( " " + implClass + " __impl = (" + implClass + ") __method;" ) ;
1139
+ EmitLine ( " " + implClass + " __impl = (" + implClass + ") __method;" ) ;
1140
1140
EmitLine ( " " + method . Name + "(" ) ;
1141
1141
int remaining = parameters . Length ;
1142
1142
foreach ( ParameterInfo pi in parameters ) {
1143
+ if ( Attribute ( pi , typeof ( AmqpContentHeaderMappingAttribute ) ) != null ) {
1144
+ Emit ( " (" + pi . ParameterType + ") cmd.Header" ) ;
1145
+ } else if ( Attribute ( pi , typeof ( AmqpContentBodyMappingAttribute ) ) != null ) {
1146
+ Emit ( " cmd.Body" ) ;
1147
+ } else {
1148
+ AmqpFieldMappingAttribute fieldMapping =
1149
+ Attribute ( pi , typeof ( AmqpFieldMappingAttribute ) ) as AmqpFieldMappingAttribute ;
1150
+ Emit ( " __impl.m_" + ( fieldMapping == null
1151
+ ? pi . Name
1152
+ : fieldMapping . m_fieldName ) ) ;
1153
+ }
1143
1154
remaining -- ;
1144
- if ( Attribute ( pi , typeof ( AmqpUnsupportedAttribute ) ) == null )
1145
- {
1146
- if ( Attribute ( pi , typeof ( AmqpContentHeaderMappingAttribute ) ) != null )
1147
- {
1148
- Emit ( " (" + pi . ParameterType + ") cmd.Header" ) ;
1149
- }
1150
- else if ( Attribute ( pi , typeof ( AmqpContentBodyMappingAttribute ) ) != null )
1151
- {
1152
- Emit ( " cmd.Body" ) ;
1153
- }
1154
- else
1155
- {
1156
- AmqpFieldMappingAttribute fieldMapping =
1157
- Attribute ( pi , typeof ( AmqpFieldMappingAttribute ) ) as AmqpFieldMappingAttribute ;
1158
- Emit ( " __impl.m_" + ( fieldMapping == null
1159
- ? pi . Name
1160
- : fieldMapping . m_fieldName ) ) ;
1161
- }
1162
- if ( remaining > 0 )
1163
- {
1164
- EmitLine ( "," ) ;
1165
- }
1155
+ if ( remaining > 0 ) {
1156
+ EmitLine ( "," ) ;
1166
1157
}
1167
1158
}
1168
1159
EmitLine ( ");" ) ;
0 commit comments