How to create XML comments for MonoTouch projects in MonoDevelop?

It seems I can’t get the XML file containing the comments in my C # code, which will be created when the project is created using MonoDevelop.

I checked the Generate xml documentation checkbox on the Compiler tab of the project settings, but I don’t see the XML file anywhere in the project’s output files or in the source folders.

I am using Mono 10.2.1, MonoDevelop 2.4.2 and MonoTouch 4

+4
source share
2 answers

Short answer: MonoTouch C # compiler does not support the creation of doc comment files.

Long answer: MonoTouch uses the smcs (Silverlight profile) compiler because it is based on the Silverlight structure profile. Before Mono 2.10, the Mono C # compiler used System.Reflection.Emit to generate IL, which meant that it had to run in the version of the framework that it was targeting. Unfortunately, Silverlight did not have an XmlDocument and other classes that the compiler used to process XML doc comments, so these functions were disabled in the smcs compilation. In Mono 2.10, the C # compiler was ported to IKVM.Reflection, which allows one compiler (working on a "full" basis) to target any profile or version of the frame. However, the migration is not completed, and the old version of smcs still exists. This will be fixed in a future version of Mono.

+6
source

I just tried this myself, and for a project called "MonoSandbox" I ended up in "MonoSandbox.xml" in the bin \ Debug folder along with the exe file.

Is it definitely being built successfully?

+1
source

Source: https://habr.com/ru/post/1347840/


All Articles