Forum > Windows
export entry point aliases
(1/1)
440bx:
Hello,
It is somewhat common to see Windows DLLs that have multiple exported functions lead to the same piece of code, IOW, they all share the same entry point.
I was wondering if it is possible to do that with FPC. IOW, is it possible to assign multiple exported function names to an FPC written function or procedure ? if the answer is yes, then I'd like to know how it is done.
Thank you for your help.
avk:
Maybe something like this?
--- Code: Pascal [+][-]window.onload = function(){var x1 = document.getElementById("main_content_section"); if (x1) { var x = document.getElementsByClassName("geshi");for (var i = 0; i < x.length; i++) { x[i].style.maxHeight='none'; x[i].style.height = Math.min(x[i].clientHeight+15,306)+'px'; x[i].style.resize = "vertical";}};} ---library test; {$mode objfpc} function MyFun(c: Integer): Integer;begin Result := c * 10;end; exports MyFun, MyFun name 'MySameFun', MyFun name 'MyOtherSameFun';beginend.
440bx:
--- Quote from: avk on September 30, 2022, 05:32:55 am ---Maybe something like this?
--- End quote ---
Yes! That's exactly what I was wondering how to do. Great example too!
Thank you very much @avk, much appreciated.
avk:
You are welcome.
Navigation
[0] Message Index