Commit Graph

127 Commits

Author SHA1 Message Date
Michaël Van Canneyt
d86e726e87 * Invoke helper also needs generic ids 2025-02-27 17:36:43 +01:00
Michaël Van Canneyt
e15f731a9b * Allow to parse internal symbol names generated for generics. 2024-11-25 21:58:17 +01:00
Michaël Van Canneyt
e1e301dea8 * Add missing methods to thunk class for parent interfaces without RTTI 2024-11-25 11:32:36 +01:00
Michaël Van Canneyt
46e5903792 * Generate correct type name for procedural type arguments in thunk class 2024-10-15 15:59:09 +02:00
Michaël Van Canneyt
02704f85a9 * Wasm: generator for invoke helper now handles overloaded methods in interfaces 2024-05-06 15:49:28 +02:00
Michaël Van Canneyt
312cf246ad * Fix creating thunk class when inherited interfaces are used 2024-05-04 16:44:32 +02:00
Michaël Van Canneyt
6f7481fd24 * Remove freeold from set_current_scanner 2024-03-05 07:56:14 +00:00
Michaël Van Canneyt
4443e83b75 * replace/restore_scanner use var in state to make sure the correct scanner is freed 2024-03-05 07:56:14 +00:00
Michaël Van Canneyt
125bd9d5e9 Create invoke helper if requested and reference it in RTTI 2023-07-13 07:32:21 +00:00
Michaël Van Canneyt
92f148e667 * Generate hidden class to be used for TVirtualInterface (wasm only) 2023-07-11 08:36:57 +00:00
Nikolay Nikolov
553cee72eb * tsk_wasm_suspending renamed tsk_wasm_suspending_first 2023-06-17 12:28:12 +03:00
Nikolay Nikolov
2f1ccd6f2a + support 'promising last' exports 2023-06-16 11:00:19 +03:00
Nikolay Nikolov
9d893b5d0d * tcpuprocdef.promising_export_name renamed promising_first_export_name 2023-06-16 10:50:35 +03:00
Nikolay Nikolov
9ea1f6de19 + added 'last' or 'first' to the internal promising wrapper name 2023-06-13 12:15:46 +03:00
Nikolay Nikolov
ed748a65b4 + added last:boolean parameter to implement_wasm_promising_wrapper 2023-06-13 12:14:09 +03:00
Nikolay Nikolov
2eb3f5f0b8 + introduced implement_wasm_promising_wrapper 2023-06-13 12:10:54 +03:00
Nikolay Nikolov
0f89852908 + support 'suspending last' externals as well 2023-06-13 09:34:54 +03:00
Nikolay Nikolov
c22b6c10b7 * fixed generating wrappers for suspending functions that return something, other than double 2023-06-11 16:50:49 +03:00
Nikolay Nikolov
15c95e0ac7 + initial implementation of WebAssembly promising exports 2023-06-11 16:43:45 +03:00
Nikolay Nikolov
80c8575636 * fixed creating suspended wrappers for functions without parameters 2023-06-11 15:24:55 +03:00
Nikolay Nikolov
1a4b97a62a * fixed compilation with -Sew 2023-06-11 15:09:49 +03:00
Nikolay Nikolov
b247302871 + initial attempt (not fully working, yet) at implementing WebAssembly suspending externals 2023-06-11 14:07:35 +03:00
Jonas Maebe
32f8dc7ef5 symcreat: add hidden high parameters in create_procdef_alias
No longer happens automatically for pc_bareproc procdef copies
2022-12-31 11:59:05 +01:00
Jonas Maebe
b0e1867b4c symcreat: support for scanner/parser escape sequences
Support escape sequences when parsing internally generated code. Used for now
to force interpreting certain identifiers as unit/namespace identifiers.
2022-09-16 11:21:05 +02:00
Jonas Maebe
76e3cfc38f parentfpstruct: don't add vo_is_firstfield to first field of record
That flag is only for the first field of variant parts of records
2022-06-06 23:12:53 +02:00
Sven/Sarah Barth
7f3a5eb9ab * extend tabstractprocdef.getcopyas by a parameter to control whether the copy should be registered or not 2022-05-26 21:42:59 +02:00
Sven/Sarah Barth
f6a444c6fc * combine the Boolean parameters of read_proc and read_proc_dec into a set 2022-05-26 21:42:53 +02:00
Pierre Muller
5acd7a7b83 Rename tsymtable.insert and delete methods to insertsym ands deletesym 2022-05-03 23:00:28 +02:00
Jonas Maebe
5e3e4437c4 * use new TSym.EscapedRealName property when creating new symbols with the
same name as existing symbols

git-svn-id: trunk@47856 -
2020-12-27 13:18:53 +00:00
florian
637976e83f * patch by Marģers to unify internal error numbers, resolves #37888
git-svn-id: trunk@47103 -
2020-10-13 19:59:01 +00:00
Jonas Maebe
a2174753c1 - removed tabstractrecorddef.get_unit_symtable, which did not always return the unit
symtable (when you had a local recorddef in a procdef)
  * modified tdef.get_top_level_symtable() so you can specify whether you want to
    skip procdefs or not
  * changed tobjectdef.vmt_def() to no longer require a typesym for the tobjectdef
    (based on patch by Blaise)

git-svn-id: trunk@45361 -
2020-05-13 21:46:29 +00:00
svenbarth
a041f899d3 * when creating the static field of a generic, insert it into the generic instead of the global symtable as it isn't really used anyway
git-svn-id: trunk@43542 -
2019-11-21 21:44:43 +00:00
Jonas Maebe
a051b8d225 - remmoved doregister parameter from t*sym constructors, as the registration
is handled automatically nowadays

git-svn-id: trunk@42998 -
2019-09-14 17:30:45 +00:00
svenbarth
6952ab5baf * fix for Mantis #35918: don't set the mangledname for the attribute's constructor function; let the compiler do its job instead
git-svn-id: trunk@42560 -
2019-08-02 14:07:17 +00:00
svenbarth
a64a8f8deb - remove code to create an attribute using a synthetic function
git-svn-id: trunk@42396 -
2019-07-12 22:07:28 +00:00
svenbarth
ced3885dbb * generate construction function for the attributes used in a unit using a more straight forward approach
ToDo: "collect" attributes of same type and same argument list and generate constructor only once for them

git-svn-id: trunk@42394 -
2019-07-12 22:07:20 +00:00
svenbarth
f9cda608fa * take a copy of the constructor assignment node (and free it together with the attribute)
git-svn-id: trunk@42388 -
2019-07-12 22:06:57 +00:00
svenbarth
b2932393df Reintegration of Custom Attributes branch by Joost van der Sluis with patches reworked by Svetozar Belic [patch 1/3]
Implemented attributes for class types and properties (based on work by Joost van der Sluis). Added TCustomAttribute - a base class for attributes. Added TUnitInfo record to RTTI. It contains the unit name and unit options (for now only a flag which specifies if the unit contains attributes). Added several tests for attributes.

git-svn-id: trunk@42356 -
2019-07-12 22:04:48 +00:00
Jonas Maebe
281b3ad276 * fix case completeness and unreachable code warnings in compiler that would
be introduced by the next commit

git-svn-id: trunk@42046 -
2019-05-12 14:29:03 +00:00
Jonas Maebe
ed2ae508d0 * only add hidden parameters for objectdef methods after generating the vmt,
so that they take into account inherited calling conventions (mantis #35233)
   o don't needlessly calculate the paraloc info when generating a JVM mangled
     name

git-svn-id: trunk@41716 -
2019-03-16 19:14:14 +00:00
Jonas Maebe
91d5457b38 * moved around/replaced the following procedures to stop nflw from depending
on pdecsub (node units should not depend on parser units):
   o maybe_add_public_default_java_constructor()
   o handle_calling_convention()
   o create_finalizer_procdef() (replaced with create_outline_procdef())
   o insert_record_hidden_paras()
   o handle_calling_convention()
   o proc_add_definition()
   o build_parentfpstruct()
   o maybe_guarantee_record_typesym()
   o get_first_proc_str()
  * factored out the creation of a procinfo for a nested procdef based on a
    subnodetree of the current procdef into tprocinfo.create_for_outlining()

git-svn-id: trunk@40773 -
2019-01-05 16:26:33 +00:00
Jonas Maebe
4d03f3a65e * fixed LLVM memory leaks
git-svn-id: trunk@40732 -
2019-01-01 16:22:31 +00:00
Jonas Maebe
d75ba7cb11 * suppress notes about unused $nestedvars local variable
git-svn-id: trunk@40648 -
2018-12-25 18:22:41 +00:00
Jonas Maebe
acf02ab64b * when creating wrappers, add a prefix to parameter names to prevent them
hiding the method name of the wrapped routine
   o also add a few more '&' prefixes to the generated wrapper code to
     prevent issues when keywords are used as identifiers

git-svn-id: trunk@40634 -
2018-12-24 22:10:06 +00:00
nickysn
3318703ece * moved nf_typedaddr to addrnodeflags (anf_typedaddr)
git-svn-id: trunk@38671 -
2018-04-03 16:41:01 +00:00
Jonas Maebe
d35377fdee * workaround for debug info for interface method wrappers: give them the
line number information of the method declaration if it's in the current
    unit, and otherwise the first line of the current unit (mantis #14399)

git-svn-id: trunk@37961 -
2018-01-13 16:54:22 +00:00
florian
b1dff29cbf * removed unused units
git-svn-id: trunk@36165 -
2017-05-09 19:53:14 +00:00
svenbarth
1a6a8b7c9f + introduce a new potype for the main stub of a package library (which on Windows is simply a DLLMain returning True)
git-svn-id: trunk@35371 -
2017-01-29 22:37:40 +00:00
Jonas Maebe
d36fe53d85 * factored out the code to create an complete alias for a procdef to
symcreat.create_procdef_alias()

git-svn-id: trunk@35087 -
2016-12-09 13:39:35 +00:00
Jonas Maebe
8af85a16b3 * document finish_copied_procdef()
git-svn-id: trunk@35086 -
2016-12-09 13:39:31 +00:00