mirror of
https://github.com/autc04/Retro68.git
synced 2024-11-26 22:51:01 +00:00
have asfilter deal with tail calls to toolbox functions (preventing undefined __magic_inline errors, see issue #2)
This commit is contained in:
parent
6a08b8ed6c
commit
d78125c6b6
@ -66,7 +66,7 @@ int main(int argc, char *argv[])
|
|||||||
std::ofstream out(tempFileName);
|
std::ofstream out(tempFileName);
|
||||||
|
|
||||||
std::string wordS = "[0-9a-f][0-9a-f][0-9a-f][0-9a-f]";
|
std::string wordS = "[0-9a-f][0-9a-f][0-9a-f][0-9a-f]";
|
||||||
rx::regex jsr("\tjsr __magic_inline_(" + wordS + "(_" + wordS + ")*)");
|
rx::regex jsr("\t(jsr|jra) __magic_inline_(" + wordS + "(_" + wordS + ")*)");
|
||||||
rx::regex word(wordS);
|
rx::regex word(wordS);
|
||||||
rx::regex rts("\trts");
|
rx::regex rts("\trts");
|
||||||
rx::regex instruction("\t[a-z]+.*");
|
rx::regex instruction("\t[a-z]+.*");
|
||||||
@ -98,6 +98,11 @@ int main(int argc, char *argv[])
|
|||||||
{
|
{
|
||||||
out << "\tdc.w 0x" << p->str() << std::endl;
|
out << "\tdc.w 0x" << p->str() << std::endl;
|
||||||
}
|
}
|
||||||
|
if(match[1] == "jra")
|
||||||
|
{
|
||||||
|
out << "rts\n";
|
||||||
|
hadRts = true;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
// ******* 2. strip unneeded extra rts from "# macsbug symbol" paragraphs
|
// ******* 2. strip unneeded extra rts from "# macsbug symbol" paragraphs
|
||||||
|
Loading…
Reference in New Issue
Block a user