Tinkerforge/generators — pull request #9 by NobodysNightmare (2012-05-08 15:00:39+00:00)
Title: C#: get_csharp_type should return array-extension

Hello,
while working on the c#-code-generator I noticed, that there is the method get_csharp_type, that returns me the csharp-type for a given config-type. However this method does not determine if the element this type belongs to is an array-element.

In make_parameter_list this behavior is added AFTER calling get_csharp_type, but in make_callbacks this behavior is not added. I believe that this is an error, as there should also be an array defined, if an array ist expected. The error was just not recognized because there are no Callbacks that accept an array.

What does the Pull Request contain?
------------------------------------------------------
- the method get_csharp_type now expects an element instead of a type-string
- it returns the corresponding type including the array-extension ("[]")
- make_parameter_list got a bit simpler (logic moved to get_csharp_type)
- make_callbacks should now work as intended if there were array-parameters