querybuilder icon indicating copy to clipboard operation
querybuilder copied to clipboard

Weird Return type of empty dynamic from a function

Open tfraney opened this issue 5 months ago • 0 comments

I am returning a Query back from a function that logs some compiled raw SQL. then I return the original query back out. My function return type is Query and there are no hard type errors. Yet when it returns back to the calling method , under Query. IntelliSense sees it as Dynamic and compiler says it as no UpdateAsync or any other Query method. I have to hard cast it as "await ((Query) q).UpdateAsync , and IntelliSense picks it up and it compiles. What bug is in there that breaks actual compiler issues on a hard type object that is correct.

This is the most dangerous thing i've seen. My job uses the library.

tfraney avatar Aug 01 '25 10:08 tfraney