-
-
Notifications
You must be signed in to change notification settings - Fork 1.6k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
First pass ts conversion for lib/mapfiles #4386
Conversation
endAddress?: string; | ||
segmentLength: number; | ||
unitName?: string | false; | ||
}; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm not in love with the types yet, but they work
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@partouf do these types look ok to you?
segments: Segment[] = []; | ||
isegments: Segment[] = []; | ||
namedAddresses: Segment[] = []; | ||
entryPoint: '' | EntryPoint = ''; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
entryPoint
appears unused but I'm trying to keep changes minimal
* @returns {(object | boolean)} | ||
*/ | ||
getLineInfoByAddress(segment, address) { | ||
getLineInfoByAddress(segment: string | boolean, address: number) { | ||
for (let idx = 0; idx < this.lineNumbers.length; idx++) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Lots of index-based loops in this code but again trying to keep changes minimal
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It was written a long time ago in 2017, I just did what I knew would work :D
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Perfect for 2017! :P
this is live 🚀 |
No description provided.