Skip to content
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

Fixes #22

Merged
merged 11 commits into from
Oct 1, 2023
Merged

Fixes #22

merged 11 commits into from
Oct 1, 2023

Conversation

nikitalita
Copy link
Collaborator

No description provided.

@nikitalita nikitalita marked this pull request as ready for review September 29, 2023 07:48
Copy link
Owner

@Orvid Orvid left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

A couple of minor nits, but otherwise this looks good.

Caprica/common/FakeScripts.h Outdated Show resolved Hide resolved
Caprica/main_options.cpp Outdated Show resolved Hide resolved
@@ -52,16 +52,16 @@ bool CapricaReportingContext::isWarningEnabled(CapricaFileLocation /* location *
size_t CapricaReportingContext::getLocationLine(CapricaFileLocation location, size_t lastLineHint) {
if (!lineOffsets.size())
CapricaReportingContext::logicalFatal("Unable to locate line at offset {}.", location.startOffset);
if (lastLineHint != 0) {
Copy link
Collaborator Author

@nikitalita nikitalita Sep 29, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@Orvid I had to remove this because it was resulting in incorrect line numbers in the debug info; this was just for speed, correct?

Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yep, it was there purely for speed. If it's causing problems, removing it is fine.

@@ -40,6 +40,10 @@ void PexFunctionBuilder::populateFunction(PexFunction* func, PexDebugFunctionInf
line = reportingContext.getLocationLine(l, line);
if (line > std::numeric_limits<uint16_t>::max())
reportingContext.fatal(l, "The file has too many lines for the debug info to be able to map correctly!");
// check that the line is larger than the previous one; if not, then set it to the previous one.
// Compiler does not like
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Would it be reasonable to hide this behind an engine limit?

Also, this comment is incomplete.

@Orvid Orvid merged commit 87c575b into Orvid:master Oct 1, 2023
1 check passed
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.

2 participants