Advertisement
C0BRA

Victormeriqui is dumb

May 17th, 2013
95
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 2.16 KB | None | 0 0
  1. Victormeriqui: if someone was reading your code
  2. Victormeriqui: how would they knoe
  3. Victormeriqui: Value returned a reference
  4. Kobra: it's implied?
  5. Kobra: how else would you set it?
  6. Kobra: BUT WAIT
  7. Kobra: WAIT
  8. Kobra: WAIT
  9. Kobra: Victormeriqui: if someone was reading your code
  10. Victormeriqui: how would they knoe
  11. Victormeriqui: Value returned a reference
  12. Victormeriqui: no, it's not, when you look at that you dont know what Size() returns
  13. Kobra: Victormeriqui: if someone was reading your code
  14. Victormeriqui: how would they knoe
  15. Victormeriqui: Value is a member variable?
  16. Kobra: you just got zinged by your own logic
  17. Victormeriqui: no i didnt
  18. Victormeriqui: if it was setvalue
  19. Victormeriqui: it'd be self explained
  20. Kobra: what the fuck?
  21. Victormeriqui: if it was a var with public access
  22. Kobra: we're talking
  23. Victormeriqui: it'd be self explained
  24. Kobra: items not exposed
  25. Kobra: you dumb shit
  26. Kobra: ytou can't set a controls size
  27. Kobra: and inside of the control code
  28. Kobra: _Size is used
  29. Kobra: you can instantly see it's a member variable
  30. Victormeriqui: brb dinner, and either name stuff right or only you will be able to read it, with in a few weeks becaus eafter that you'll come back and think wtf is this
  31. Kobra: a PRIVATE member variable
  32. Victormeriqui is now Away.
  33. Kobra: no
  34. Kobra: you're dumb
  35. Kobra: you can't set a control size
  36. Kobra: for a Vector
  37. Kobra: i have
  38. Kobra: public:
  39. double X, Y;
  40. Kobra: it makes sense, it's a public variable, but there is no bloody SetSize, you can ForceResize a control, but it may not obey to that instruction, thus it's not SETTING it, it's ASKING it to resize ITSELF, the control uses _Size as a local INTEERNAL to the class variable, thus they shouldn't be able to access it, hence it being protected/private, and for readability or IDEs without super godlike intelisense, they can see the variable is bloody protected/private. it's really that fucking simple, _X = youcan't touch _X, you may be able to mess or prod with it, but direct access is disallowed!
  41. Kobra: i mean, take this code for example: Ddrl46: Console.SetCursorPosition(_PositionX + _SizeX - 1, _PositionY + _SizeY - 1);
  42.  
  43. you can instantly see what's private
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement