diff options
author | John Hodge <tpg@ucc.asn.au> | 2019-06-29 15:54:41 +0800 |
---|---|---|
committer | John Hodge <tpg@ucc.asn.au> | 2019-06-29 15:54:41 +0800 |
commit | 64af65a27097e17811c943dbac551ae741413954 (patch) | |
tree | 1ae96ce8b87ab54f03e06b47cca6b7981c43f7f6 /src/expand | |
parent | 97763cebbdbe016a694840cc296c76b65576aa57 (diff) | |
download | mrust-64af65a27097e17811c943dbac551ae741413954.tar.gz |
Trans - Rework to potentially support dynamic libraries
Diffstat (limited to 'src/expand')
-rw-r--r-- | src/expand/proc_macro.cpp | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/src/expand/proc_macro.cpp b/src/expand/proc_macro.cpp index 82944857..a88102f7 100644 --- a/src/expand/proc_macro.cpp +++ b/src/expand/proc_macro.cpp @@ -259,7 +259,8 @@ ProcMacroInv ProcMacro_Invoke_int(const Span& sp, const ::AST::Crate& crate, con } // 2. Get executable and macro name - ::std::string proc_macro_exe_name = (ext_crate.m_filename + "-plugin"); + // TODO: Windows will have .exe? + ::std::string proc_macro_exe_name = ext_crate.m_filename; // 3. Create ProcMacroInv return ProcMacroInv(sp, proc_macro_exe_name.c_str(), *pmp); @@ -820,7 +821,7 @@ ProcMacroInv::ProcMacroInv(const Span& sp, const char* executable, const ::HIR:: int rv = posix_spawn(&this->child_pid, executable, &file_actions, nullptr, argv, environ); if( rv != 0 ) { - BUG(sp, "Error in posix_spawn - " << rv); + BUG(sp, "Error in posix_spawn - " << rv << " - can't start `" << executable << "`"); } posix_spawn_file_actions_destroy(&file_actions); |