Guest User

Untitled

a guest
Nov 20th, 2018
90
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.39 KB | None | 0 0
  1. Function CalcSomething(ByVal input as Single)
  2. CalcSomething = ... <some math using 'input'>
  3. End Function
  4.  
  5. 'other functions exist also...
  6.  
  7. static class A
  8. {
  9. private static Calc calc1 = new Calc();
  10.  
  11. public GetCalc() => calc1;
  12. }
  13.  
  14. ...
  15.  
  16. A.GetCalc.CalcSomething(1234); // CRASH!
  17.  
  18. static class A
  19. {
  20. public GetCalc() => new Calc();
  21. }
  22.  
  23. ...
  24.  
  25. A.GetCalc.CalcSomething(1234); // NO CRASH.
Add Comment
Please, Sign In to add comment