-
-
Notifications
You must be signed in to change notification settings - Fork 1.5k
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
parsecsv fix style #17933
parsecsv fix style #17933
Conversation
lib/pure/parsecsv.nim
Outdated
@@ -97,10 +96,10 @@ proc raiseEInvalidCsv(filename: string, line, col: int, | |||
e.msg = filename & "(" & $line & ", " & $col & ") Error: " & msg | |||
raise e | |||
|
|||
proc error(my: CsvParser, pos: int, msg: string) = | |||
raiseEInvalidCsv(my.filename, my.lineNumber, getColNumber(my, pos), msg) | |||
proc error(self: CsvParser, pos: int, msg: string) {.inline.} = |
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.
You said that there was no logic change, yet you introduced {.inline.}
here?
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.
Ye 🤷
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.
Don't inline code that is off the critical path... Don't make error handling super fast, most of the time there is no error.
* ReSync with Devel * Fix style in parsecsv * Update lib/pure/parsecsv.nim Co-authored-by: Andreas Rumpf <rumpf_a@web.de>
parsecsv
fix style, was using "my" instead ofself
, no logic change.