Question

I would love to use Run-Time Text Generation with T4 Text Templates in my Xamarin.iOS project (also known as MonoToch). Unfortunately the generated .cs file depends on System.CodeDom.Compiler.CompilerErrorCollection which seems to be part of the System.dll for iOS (the whole System.CodeDom namespace is missing).

How can I work around the issue?

Was it helpful?

Solution

The Xamarin.iOS platform does not support runtime code generation and therefore excluded the whole System.CodeDom namespace. But the T4 stuff is done by Xamarin Studio, so what worked for me was to copy the files CompilerError.cs and CompilerErrorCollection.cs from the Mono repository into my Xamarin.iOS project.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top