temporal icon indicating copy to clipboard operation
temporal copied to clipboard

Utilize EpochNanoseconds

Open JohannesHelleve opened this issue 9 months ago • 2 comments

Solves #119 Started fresh up the code, one test failing in the instant class still.

Im a commits behind, but wanted to merge when the code was working locally first.

Some things i'm unsure about:

  • When to use borrowed or owned. Used both in different places, but not sure what is optimal.
  • When to use EpochNanoseconds(...) or EpochNanoseconds::try_from(...)?/.unwrap

Thanks!

Let me know if you have any quick comments

JohannesHelleve avatar Apr 16 '25 12:04 JohannesHelleve

Hm. All the previous commits from my previous branch also got added. Will need to check into that as well.

JohannesHelleve avatar Apr 16 '25 12:04 JohannesHelleve

Not so well with git so not sure to do with that mistake.

Updated from your feedback. Thanks!

Added the helper method.

Altered a test, but should have the same functionality?

JohannesHelleve avatar Apr 21 '25 21:04 JohannesHelleve

Note: https://github.com/boa-dev/temporal/pull/452 changes how we look at this type

Manishearth avatar Jul 24 '25 22:07 Manishearth

Closing this PR. We've moved to a bit of a different way of approaching this type. And as addressed by #452, intermediate nanoseconds can be outside of a valid range, which undercuts the initial purpose of expanding EpochNanosecond's use.

nekevss avatar Jul 31 '25 23:07 nekevss