float_reference 185 B

123456789101112131415
  1. void test(float& t) {
  2. t = 8.0;
  3. t += 1.0;
  4. }
  5. void main() {
  6. float a = 5.0;
  7. float& b = &a;
  8. a = 6.0;
  9. print a;
  10. print b;
  11. test(&a);
  12. print a;
  13. print b;
  14. }