-
Notifications
You must be signed in to change notification settings - Fork 11
Open
Labels
zspitz.utilsDepends on changes to the ZSpitz.Utils libraryDepends on changes to the ZSpitz.Utils library
Description
Whenever the underlying RenderLiteral
function encounters something it cannot render, it returns #<typename>
, e.g. #CSharpInvokeMemberBinder
.
Since these are very much a part of constructing dynamic expressions, it would provide value if instead of this:
// using System.Linq.Expressions.Expression
Dynamic(
#CSharpInvokeMemberBinder,
typeof(object), new[] { obj }
)
we could return something like this:
// using System.Linq.Expressions.Expression;
// using static Microsoft.CSharp.RuntimeBinder.Binder;
Dynamic(
InvokeMember(flags, "Method", new Type[] { }, context, argInfos),
typeof(object), new[] { obj }
)
Some thoughts:
- I would want
RenderLiteral
to allow for extensible behavior. In other words, not every place we useRenderLiteral
do we want to return a literal for binders. - Particularly since this is only the C# binders; each additional language may have other binders.
Metadata
Metadata
Assignees
Labels
zspitz.utilsDepends on changes to the ZSpitz.Utils libraryDepends on changes to the ZSpitz.Utils library