File tree Expand file tree Collapse file tree 2 files changed +12
-1
lines changed Expand file tree Collapse file tree 2 files changed +12
-1
lines changed Original file line number Diff line number Diff line change @@ -317,11 +317,20 @@ void ServiceFactory<
317317 auto & @ (field[" ros2" ][" name" ])2 = req2.@ (field[" ros2" ][" name" ]);
318318@ [ end if ]@
319319@ [ if field[" basic" ]]@
320+ @ [ if frm == " 1" ]@
320321 @ (field[" ros2" ][" name" ])@ (to) = @ (field[" ros1" ][" name" ])@ (frm);
322+ @ [ else ]@
323+ @ (field[" ros1" ][" name" ])@ (to) = @ (field[" ros2" ][" name" ])@ (frm);
324+ @ [ end if ]@
325+ @ [ else ]@
326+ @ [ if frm == " 1" ]@
327+ Factory< @ (field[" ros1" ][" cpptype" ]),@ (field[" ros2" ][" cpptype" ])> :: convert_ @ (frm)_to_@ (to)(@
328+ @ (field[" ros1" ][" name" ])@ (frm), @ (field[" ros2" ][" name" ])@ (to));
321329@ [ else ]@
322330 Factory< @ (field[" ros1" ][" cpptype" ]),@ (field[" ros2" ][" cpptype" ])> :: convert_ @ (frm)_to_@ (to)(@
323331@ (field[" ros2" ][" name" ])@ (frm), @ (field[" ros1" ][" name" ])@ (to));
324332@ [ end if ]@
333+ @ [ end if ]@
325334@ [ if field[" array" ]]@
326335 }
327336@ [ end if ]@
Original file line number Diff line number Diff line change @@ -607,7 +607,9 @@ def determine_common_services(
607607 ros2_type = str (ros2_fields [direction ][i ].type )
608608 ros1_name = ros1_field [1 ]
609609 ros2_name = ros2_fields [direction ][i ].name
610- if ros1_type != ros2_type or ros1_name != ros2_name :
610+ # This must be wrong, different name with same type will now be allowed, changing it
611+ #if ros1_type != ros2_type or ros1_name != ros2_name:
612+ if ros1_type != ros2_type :
611613 # if the message types have a custom mapping their names
612614 # might not be equal, therefore check the message pairs
613615 if (ros1_type , ros2_type ) not in message_string_pairs :
You can’t perform that action at this time.
0 commit comments