Nim/tests/modules
quantimnot d30c6419a0
Refactor and doc package handling, module name mangling (#19821)
* Refactor and doc package handling, module name mangling

* Consolidate, de-duplicate and extend package handling
* Alter how duplicate module names of a package are handled
* Alter how module names are mangled
* Fix crash when another package is named 'stdlib' (test case added)
* Doc what defines a package in the manual

Modules with duplicate names within a package used to be given 'fake'
packages to resolve conflicts. That prevented the ability to discern if
a module belonged to the current project package or a foreign package.
They now have the proper package owner and the names are mangled in a
consistent manner to prevent codegen clashes.

All module names are now mangled the same. Stdlib was treated special
before, but now it is same as any other package. This fixes a crash
when a foreign package is named 'stdlib'.

Module mangling is altered for both file paths and symbols used by the
backends.

Removed an unused module name to package mapping that may have been
intended for IC. The mapping was removed because it wasn't being used
and was complicating the issue of package modules with duplicate names
not having the proper package owner assigned.

* Fix some tests

* Refactor `packagehandling`

* Remove `packagehandling.withPackageName` and its uses
* Move module path mangling from `packagehandling` to `modulepaths`
* Move `options.toRodFile` to `ic` to break import cycle

* Changed import style to match preferred style

Co-authored-by: quantimnot <quantimnot@users.noreply.github.com>
2022-05-30 18:52:19 +02:00
..
a Refactor and doc package handling, module name mangling (#19821) 2022-05-30 18:52:19 +02:00
b Refactor and doc package handling, module name mangling (#19821) 2022-05-30 18:52:19 +02:00
m9627 Fix compilation of test on linux and mac 2018-12-09 15:44:18 +05:30
tnotuniquename_dir remove the restriction that module names need to be unique per Nimble… (#11064) 2019-04-20 15:19:02 +02:00
definitions.nim implement the export/except statement 2018-05-07 09:37:49 +02:00
mexport2a.nim
mexport2b.nim
mexporta.nim
mexportb.nim
mforwarded_pure_enum.nim refactorings to prepare the compiler for IC (#15935) 2020-12-17 08:01:36 +01:00
mforwarded_pure_enum2.nim refactorings to prepare the compiler for IC (#15935) 2020-12-17 08:01:36 +01:00
mimport_in_config.nim fixes #9994 2018-12-15 14:30:21 +01:00
mmodule_same_proc.nim fixes #11188 (#11319) 2019-05-24 22:50:43 +02:00
mmodule_same_proc_client.nim fixes #11188 (#11319) 2019-05-24 22:50:43 +02:00
mnamspc1.nim
mnamspc2.nim
mnotuniquename.nim remove the restriction that module names need to be unique per Nimble… (#11064) 2019-04-20 15:19:02 +02:00
mopaque.nim
morder_depa.nim fixes #11187 (#11315) 2019-05-24 08:19:05 +02:00
morder_depb.nim fixes #11187 (#11315) 2019-05-24 08:19:05 +02:00
mrange.nim fixes #6965 2017-12-28 00:50:45 +01:00
mrecmod.nim
mrecmod2.nim
proxy_module.nim implement the export/except statement 2018-05-07 09:37:49 +02:00
seq.nim Add testcase for #4796 (#14784) 2020-06-25 15:12:30 +02:00
t8665.nim make run the default action of a test in tester 2018-11-23 11:58:28 +01:00
t9627.nim Fix compilation of test on linux and mac 2018-12-09 15:44:18 +05:30
tambig_range.nim add whitespace on the right-hand side of -- 2019-05-03 11:33:29 +02:00
tcanimport.nim make the 'canimport' template work 2018-03-06 15:57:46 +01:00
texplicit_system_import.nim fix #17952: fix both false positives and false negatives for reInvalidSpec (#17956) 2021-05-08 00:22:21 +02:00
texport.nim
texport2.nim make run the default action of a test in tester 2018-11-23 11:58:28 +01:00
tfowarded_pure_enum.nim refactorings to prepare the compiler for IC (#15935) 2020-12-17 08:01:36 +01:00
timport_in_config.nim fixes #9994 2018-12-15 14:30:21 +01:00
timport_in_config.nim.cfg fixes #9994 2018-12-15 14:30:21 +01:00
timportas.nim adopt tests 2018-11-08 22:28:29 +01:00
timportexcept.nim require errormsg to be specified before file. 2018-12-11 21:23:21 +01:00
tincludeas.nim fixes #11872; include now gives a proper error message for all invalid infix operators (#11965) 2019-08-17 19:45:47 +02:00
tmismatchedvisibility.nim Remove duplicate line number from 'invalid forward declaration' error (#11966) 2019-08-17 10:35:25 +02:00
tmodule_name_clashes.nim Refactor and doc package handling, module name mangling (#19821) 2022-05-30 18:52:19 +02:00
tmodule_same_proc.nim fixes #11188 (#11319) 2019-05-24 22:50:43 +02:00
tnamspc.nim require errormsg to be specified before file. 2018-12-11 21:23:21 +01:00
tnotuniquename.nim remove the restriction that module names need to be unique per Nimble… (#11064) 2019-04-20 15:19:02 +02:00
tnotuniquename2.nim remove the restriction that module names need to be unique per Nimble… (#11064) 2019-04-20 15:19:02 +02:00
topaque.nim require errormsg to be specified before file. 2018-12-11 21:23:21 +01:00
torder_dep.nim fixes #11187 (#11315) 2019-05-24 08:19:05 +02:00
trecinca.nim require errormsg to be specified before file. 2018-12-11 21:23:21 +01:00
trecincb.nim require errormsg to be specified before file. 2018-12-11 21:23:21 +01:00
trecmod.nim require errormsg to be specified before file. 2018-12-11 21:23:21 +01:00
trecmod2.nim
treorder.nim fix test 2018-09-04 18:25:54 -05:00
tselfimport.nim even lighter version of #17938: fix most issues with UnusedImport, XDeclaredButNotUsed, etc; fix #17511, #17510, #14246 (without realModule) (#18362) 2021-06-26 15:21:46 +02:00
tseq.nim Add testcase for #4796 (#14784) 2020-06-25 15:12:30 +02:00
tstrutils_insert_sep.nim Fix #11352 strutil.insertSep() fails on negative numbers (#15087) 2020-07-28 11:47:22 +02:00
tuppercased.nim
tutils_ab.nim fixes #12420 [backport] (#12456) 2019-10-18 22:13:24 +02:00
UpperCased.nim