deep into debugging

Suddenly got trapped into a rather nasty gap in the compiler design… don’t even know what to do – fixing the method to have the correct return type results in more than 500 compilation errors, and I can’t just write one smart regex to fix them all.

Oh, by the way, how to write (in C#) the function Func<M<T>,M<TResult>> Generalize<M>(Func<T,TResult>), which takes function from T and M, and returns a function which does something M-related on T?

М may be IEnumerable, IObservable, Nullable, Traced, ICancellable, maybe something else.

Or do it anyway… shit. I know how to do this in Python, in C# 4 (but i don’t want to use dynamic anyway), and in F#. And i don’t want to rewrite the whole compiler in F# either, because my knowledge of F# is not so good, and unsure whether it’s worth the effort.

Advertisements

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s