Skip to content

Conversation

@jakebailey
Copy link
Member

This function was useful when we were using interfaces and didn't want to care about boxing nil, but now we're all concrete so I don't think we need this function anymore.

This saves a good 5% in bind.

goos: linux
goarch: amd64
pkg: github.com/microsoft/typescript-go/internal/compiler
cpu: Intel(R) Core(TM) i9-10900K CPU @ 3.70GHz
         │   old.txt   │              new.txt               │
         │   sec/op    │   sec/op     vs base               │
Bind-20    24.58m ± 1%   23.45m ± 2%  -4.58% (p=0.000 n=10)
Parse-20   45.97m ± 1%   46.25m ± 3%       ~ (p=0.063 n=10)
geomean    33.61m        32.93m       -2.01%

         │   old.txt    │               new.txt               │
         │     B/op     │     B/op      vs base               │
Bind-20    9.776Mi ± 0%   9.776Mi ± 0%       ~ (p=0.912 n=10)
Parse-20   23.59Mi ± 0%   23.59Mi ± 0%       ~ (p=0.684 n=10)
geomean    15.19Mi        15.19Mi       +0.00%

         │   old.txt   │              new.txt               │
         │  allocs/op  │  allocs/op   vs base               │
Bind-20    102.6k ± 0%   102.6k ± 0%       ~ (p=0.670 n=10)
Parse-20   239.1k ± 0%   239.1k ± 0%       ~ (p=0.896 n=10)
geomean    156.6k        156.6k       -0.00%

@jakebailey jakebailey requested a review from ahejlsberg October 21, 2024 23:53
@jakebailey jakebailey merged commit 7efffd7 into main Oct 22, 2024
10 checks passed
@jakebailey jakebailey deleted the jabaile/remove-exists branch October 22, 2024 15:43
nathanwhit added a commit to nathanwhit/typescript-go-rs that referenced this pull request Oct 24, 2025
feat: pass import attribute type to resolver
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants