irbuild-math.test 855 B

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364
  1. [case testMathLiteralsAreInlined]
  2. import math
  3. from math import pi, e, tau, inf, nan
  4. def f1() -> float:
  5. return pi
  6. def f2() -> float:
  7. return math.pi
  8. def f3() -> float:
  9. return math.e
  10. def f4() -> float:
  11. return math.e
  12. def f5() -> float:
  13. return math.tau
  14. def f6() -> float:
  15. return math.tau
  16. def f7() -> float:
  17. return math.inf
  18. def f8() -> float:
  19. return math.inf
  20. def f9() -> float:
  21. return math.nan
  22. def f10() -> float:
  23. return math.nan
  24. [out]
  25. def f1():
  26. L0:
  27. return 3.141592653589793
  28. def f2():
  29. L0:
  30. return 3.141592653589793
  31. def f3():
  32. L0:
  33. return 2.718281828459045
  34. def f4():
  35. L0:
  36. return 2.718281828459045
  37. def f5():
  38. L0:
  39. return 6.283185307179586
  40. def f6():
  41. L0:
  42. return 6.283185307179586
  43. def f7():
  44. L0:
  45. return inf
  46. def f8():
  47. L0:
  48. return inf
  49. def f9():
  50. L0:
  51. return nan
  52. def f10():
  53. L0:
  54. return nan