Moving away from Transaction History

  • Mar 22, 2013
  • 0 Kommentars

This week I switched the way I determine if a type is assignable to an Inferred Type. Previously I had inserted code around where method invocations and AssignmentExpressions were getting created. I then moved to listening to the Transaction History. However, with this method, I encountered issues with loading the world after saving it. Adding the transaction history listener at the correct time was not possible in a clean way. Now I've moved to a crawler after talking to Dennis about the transaction history problem. Essentially, instead of keeping track of assignments and invocations as they're created, I am now just crawling the whole AST every time the question is asked. This is much less efficient, however the AST is typically very small, so crawling it takes barely any time. If this becomes a performance issue in the future, I will implement some caching to speed things up.

I have also begun work on the explanation of why certain models aren't available for assignment. This is proving to be trickier than I hoped. The approach I'm taking is to create a custom CascadeItem which will have a different look than the regular item and will list the methods it's missing that the other methods have.

Kommentars

  • No comments yet

Anmelden oder Registrieren to leave a comment.